Lines Matching full:pool
23 void xsk_tx_completed(struct xsk_buff_pool *pool, u32 nb_entries);
24 bool xsk_tx_peek_desc(struct xsk_buff_pool *pool, struct xdp_desc *desc);
25 u32 xsk_tx_peek_release_desc_batch(struct xsk_buff_pool *pool, u32 max);
26 void xsk_tx_release(struct xsk_buff_pool *pool);
29 void xsk_set_rx_need_wakeup(struct xsk_buff_pool *pool);
30 void xsk_set_tx_need_wakeup(struct xsk_buff_pool *pool);
31 void xsk_clear_rx_need_wakeup(struct xsk_buff_pool *pool);
32 void xsk_clear_tx_need_wakeup(struct xsk_buff_pool *pool);
33 bool xsk_uses_need_wakeup(struct xsk_buff_pool *pool);
35 static inline u32 xsk_pool_get_headroom(struct xsk_buff_pool *pool) in xsk_pool_get_headroom() argument
37 return XDP_PACKET_HEADROOM + pool->headroom; in xsk_pool_get_headroom()
40 static inline u32 xsk_pool_get_chunk_size(struct xsk_buff_pool *pool) in xsk_pool_get_chunk_size() argument
42 return pool->chunk_size; in xsk_pool_get_chunk_size()
45 static inline u32 xsk_pool_get_rx_frame_size(struct xsk_buff_pool *pool) in xsk_pool_get_rx_frame_size() argument
47 return xsk_pool_get_chunk_size(pool) - xsk_pool_get_headroom(pool); in xsk_pool_get_rx_frame_size()
50 static inline void xsk_pool_set_rxq_info(struct xsk_buff_pool *pool, in xsk_pool_set_rxq_info() argument
53 xp_set_rxq_info(pool, rxq); in xsk_pool_set_rxq_info()
56 static inline void xsk_pool_fill_cb(struct xsk_buff_pool *pool, in xsk_pool_fill_cb() argument
59 xp_fill_cb(pool, desc); in xsk_pool_fill_cb()
62 static inline void xsk_pool_dma_unmap(struct xsk_buff_pool *pool, in xsk_pool_dma_unmap() argument
65 xp_dma_unmap(pool, attrs); in xsk_pool_dma_unmap()
68 static inline int xsk_pool_dma_map(struct xsk_buff_pool *pool, in xsk_pool_dma_map() argument
71 struct xdp_umem *umem = pool->umem; in xsk_pool_dma_map()
73 return xp_dma_map(pool, dev, attrs, umem->pgs, umem->npgs); in xsk_pool_dma_map()
90 static inline struct xdp_buff *xsk_buff_alloc(struct xsk_buff_pool *pool) in xsk_buff_alloc() argument
92 return xp_alloc(pool); in xsk_buff_alloc()
101 static inline u32 xsk_buff_alloc_batch(struct xsk_buff_pool *pool, struct xdp_buff **xdp, u32 max) in xsk_buff_alloc_batch() argument
103 return xp_alloc_batch(pool, xdp, max); in xsk_buff_alloc_batch()
106 static inline bool xsk_buff_can_alloc(struct xsk_buff_pool *pool, u32 count) in xsk_buff_can_alloc() argument
108 return xp_can_alloc(pool, count); in xsk_buff_can_alloc()
114 struct list_head *xskb_list = &xskb->pool->xskb_list; in xsk_buff_free()
142 list_add_tail(&frag->list_node, &frag->pool->xskb_list); in xsk_buff_add_frag()
153 frag = list_first_entry_or_null(&xskb->pool->xskb_list, in xsk_buff_get_frag()
175 frag = list_last_entry(&xskb->pool->xskb_list, struct xdp_buff_xsk, in xsk_buff_get_tail()
188 static inline dma_addr_t xsk_buff_raw_get_dma(struct xsk_buff_pool *pool, in xsk_buff_raw_get_dma() argument
191 return xp_raw_get_dma(pool, addr); in xsk_buff_raw_get_dma()
194 static inline void *xsk_buff_raw_get_data(struct xsk_buff_pool *pool, u64 addr) in xsk_buff_raw_get_data() argument
196 return xp_raw_get_data(pool, addr); in xsk_buff_raw_get_data()
211 static inline struct xsk_tx_metadata *xsk_buff_get_metadata(struct xsk_buff_pool *pool, u64 addr) in xsk_buff_get_metadata() argument
215 if (!pool->tx_metadata_len) in xsk_buff_get_metadata()
218 meta = xp_raw_get_data(pool, addr) - pool->tx_metadata_len; in xsk_buff_get_metadata()
232 static inline void xsk_buff_raw_dma_sync_for_device(struct xsk_buff_pool *pool, in xsk_buff_raw_dma_sync_for_device() argument
236 xp_dma_sync_for_device(pool, dma, size); in xsk_buff_raw_dma_sync_for_device()
241 static inline void xsk_tx_completed(struct xsk_buff_pool *pool, u32 nb_entries) in xsk_tx_completed() argument
245 static inline bool xsk_tx_peek_desc(struct xsk_buff_pool *pool, in xsk_tx_peek_desc() argument
251 static inline u32 xsk_tx_peek_release_desc_batch(struct xsk_buff_pool *pool, u32 max) in xsk_tx_peek_release_desc_batch() argument
256 static inline void xsk_tx_release(struct xsk_buff_pool *pool) in xsk_tx_release() argument
266 static inline void xsk_set_rx_need_wakeup(struct xsk_buff_pool *pool) in xsk_set_rx_need_wakeup() argument
270 static inline void xsk_set_tx_need_wakeup(struct xsk_buff_pool *pool) in xsk_set_tx_need_wakeup() argument
274 static inline void xsk_clear_rx_need_wakeup(struct xsk_buff_pool *pool) in xsk_clear_rx_need_wakeup() argument
278 static inline void xsk_clear_tx_need_wakeup(struct xsk_buff_pool *pool) in xsk_clear_tx_need_wakeup() argument
282 static inline bool xsk_uses_need_wakeup(struct xsk_buff_pool *pool) in xsk_uses_need_wakeup() argument
287 static inline u32 xsk_pool_get_headroom(struct xsk_buff_pool *pool) in xsk_pool_get_headroom() argument
292 static inline u32 xsk_pool_get_chunk_size(struct xsk_buff_pool *pool) in xsk_pool_get_chunk_size() argument
297 static inline u32 xsk_pool_get_rx_frame_size(struct xsk_buff_pool *pool) in xsk_pool_get_rx_frame_size() argument
302 static inline void xsk_pool_set_rxq_info(struct xsk_buff_pool *pool, in xsk_pool_set_rxq_info() argument
307 static inline void xsk_pool_fill_cb(struct xsk_buff_pool *pool, in xsk_pool_fill_cb() argument
312 static inline void xsk_pool_dma_unmap(struct xsk_buff_pool *pool, in xsk_pool_dma_unmap() argument
317 static inline int xsk_pool_dma_map(struct xsk_buff_pool *pool, in xsk_pool_dma_map() argument
333 static inline struct xdp_buff *xsk_buff_alloc(struct xsk_buff_pool *pool) in xsk_buff_alloc() argument
343 static inline u32 xsk_buff_alloc_batch(struct xsk_buff_pool *pool, struct xdp_buff **xdp, u32 max) in xsk_buff_alloc_batch() argument
348 static inline bool xsk_buff_can_alloc(struct xsk_buff_pool *pool, u32 count) in xsk_buff_can_alloc() argument
381 static inline dma_addr_t xsk_buff_raw_get_dma(struct xsk_buff_pool *pool, in xsk_buff_raw_get_dma() argument
387 static inline void *xsk_buff_raw_get_data(struct xsk_buff_pool *pool, u64 addr) in xsk_buff_raw_get_data() argument
397 static inline struct xsk_tx_metadata *xsk_buff_get_metadata(struct xsk_buff_pool *pool, u64 addr) in xsk_buff_get_metadata() argument
406 static inline void xsk_buff_raw_dma_sync_for_device(struct xsk_buff_pool *pool, in xsk_buff_raw_dma_sync_for_device() argument