Lines Matching refs:epbh

113 static int fjes_hw_alloc_epbuf(struct epbuf_handler *epbh)  in fjes_hw_alloc_epbuf()  argument
121 epbh->buffer = mem; in fjes_hw_alloc_epbuf()
122 epbh->size = EP_BUFFER_SIZE; in fjes_hw_alloc_epbuf()
124 epbh->info = (union ep_buffer_info *)mem; in fjes_hw_alloc_epbuf()
125 epbh->ring = (u8 *)(mem + sizeof(union ep_buffer_info)); in fjes_hw_alloc_epbuf()
130 static void fjes_hw_free_epbuf(struct epbuf_handler *epbh) in fjes_hw_free_epbuf() argument
132 vfree(epbh->buffer); in fjes_hw_free_epbuf()
133 epbh->buffer = NULL; in fjes_hw_free_epbuf()
134 epbh->size = 0; in fjes_hw_free_epbuf()
136 epbh->info = NULL; in fjes_hw_free_epbuf()
137 epbh->ring = NULL; in fjes_hw_free_epbuf()
140 void fjes_hw_setup_epbuf(struct epbuf_handler *epbh, const u8 *mac_addr, in fjes_hw_setup_epbuf() argument
143 union ep_buffer_info *info = epbh->info; in fjes_hw_setup_epbuf()
161 info->v1i.buffer_size = epbh->size - info->v1i.info_size; in fjes_hw_setup_epbuf()
855 bool fjes_hw_check_epbuf_version(struct epbuf_handler *epbh, u32 version) in fjes_hw_check_epbuf_version() argument
857 union ep_buffer_info *info = epbh->info; in fjes_hw_check_epbuf_version()
862 bool fjes_hw_check_mtu(struct epbuf_handler *epbh, u32 mtu) in fjes_hw_check_mtu() argument
864 union ep_buffer_info *info = epbh->info; in fjes_hw_check_mtu()
870 bool fjes_hw_check_vlan_id(struct epbuf_handler *epbh, u16 vlan_id) in fjes_hw_check_vlan_id() argument
872 union ep_buffer_info *info = epbh->info; in fjes_hw_check_vlan_id()
889 bool fjes_hw_set_vlan_id(struct epbuf_handler *epbh, u16 vlan_id) in fjes_hw_set_vlan_id() argument
891 union ep_buffer_info *info = epbh->info; in fjes_hw_set_vlan_id()
903 void fjes_hw_del_vlan_id(struct epbuf_handler *epbh, u16 vlan_id) in fjes_hw_del_vlan_id() argument
905 union ep_buffer_info *info = epbh->info; in fjes_hw_del_vlan_id()
916 bool fjes_hw_epbuf_rx_is_empty(struct epbuf_handler *epbh) in fjes_hw_epbuf_rx_is_empty() argument
918 union ep_buffer_info *info = epbh->info; in fjes_hw_epbuf_rx_is_empty()
930 void *fjes_hw_epbuf_rx_curpkt_get_addr(struct epbuf_handler *epbh, in fjes_hw_epbuf_rx_curpkt_get_addr() argument
933 union ep_buffer_info *info = epbh->info; in fjes_hw_epbuf_rx_curpkt_get_addr()
937 ring_frame = (struct esmem_frame *)&(epbh->ring[EP_RING_INDEX in fjes_hw_epbuf_rx_curpkt_get_addr()
949 void fjes_hw_epbuf_rx_curpkt_drop(struct epbuf_handler *epbh) in fjes_hw_epbuf_rx_curpkt_drop() argument
951 union ep_buffer_info *info = epbh->info; in fjes_hw_epbuf_rx_curpkt_drop()
953 if (fjes_hw_epbuf_rx_is_empty(epbh)) in fjes_hw_epbuf_rx_curpkt_drop()
956 EP_RING_INDEX_INC(epbh->info->v1i.head, info->v1i.count_max); in fjes_hw_epbuf_rx_curpkt_drop()
959 int fjes_hw_epbuf_tx_pkt_send(struct epbuf_handler *epbh, in fjes_hw_epbuf_tx_pkt_send() argument
962 union ep_buffer_info *info = epbh->info; in fjes_hw_epbuf_tx_pkt_send()
968 ring_frame = (struct esmem_frame *)&(epbh->ring[EP_RING_INDEX in fjes_hw_epbuf_tx_pkt_send()
976 EP_RING_INDEX_INC(epbh->info->v1i.tail, info->v1i.count_max); in fjes_hw_epbuf_tx_pkt_send()