Home
last modified time | relevance | path

Searched refs:hwbm_pool (Results 1 – 5 of 5) sorted by relevance

/Linux-v4.19/include/net/
Dhwbm.h5 struct hwbm_pool { struct
13 int (*construct)(struct hwbm_pool *bm_pool, void *buf); argument
20 void hwbm_buf_free(struct hwbm_pool *bm_pool, void *buf); argument
21 int hwbm_pool_refill(struct hwbm_pool *bm_pool, gfp_t gfp);
22 int hwbm_pool_add(struct hwbm_pool *bm_pool, unsigned int buf_num, gfp_t gfp);
24 void hwbm_buf_free(struct hwbm_pool *bm_pool, void *buf) {} in hwbm_buf_free()
25 int hwbm_pool_refill(struct hwbm_pool *bm_pool, gfp_t gfp) { return 0; } in hwbm_pool_refill()
26 int hwbm_pool_add(struct hwbm_pool *bm_pool, unsigned int buf_num, gfp_t gfp) in hwbm_pool_add()
/Linux-v4.19/drivers/net/ethernet/marvell/
Dmvneta_bm.c93 int mvneta_bm_construct(struct hwbm_pool *hwbm_pool, void *buf) in mvneta_bm_construct() argument
96 (struct mvneta_bm_pool *)hwbm_pool->priv; in mvneta_bm_construct()
122 size_bytes = sizeof(u32) * bm_pool->hwbm_pool.size; in mvneta_bm_pool_create()
183 struct hwbm_pool *hwbm_pool = &new_pool->hwbm_pool; in mvneta_bm_pool_use() local
188 hwbm_pool->frag_size = in mvneta_bm_pool_use()
191 hwbm_pool->construct = mvneta_bm_construct; in mvneta_bm_pool_use()
192 hwbm_pool->priv = new_pool; in mvneta_bm_pool_use()
193 spin_lock_init(&hwbm_pool->lock); in mvneta_bm_pool_use()
204 num = hwbm_pool_add(hwbm_pool, hwbm_pool->size, GFP_ATOMIC); in mvneta_bm_pool_use()
205 if (num != hwbm_pool->size) { in mvneta_bm_pool_use()
[all …]
Dmvneta_bm.h111 struct hwbm_pool hwbm_pool; member
141 int mvneta_bm_construct(struct hwbm_pool *hwbm_pool, void *buf);
167 int mvneta_bm_construct(struct hwbm_pool *hwbm_pool, void *buf) { return 0; } in mvneta_bm_construct() argument
Dmvneta.c1101 struct hwbm_pool *hwbm_pool = &bm_pool->hwbm_pool; in mvneta_bm_update_mtu() local
1106 if (hwbm_pool->buf_num) { in mvneta_bm_update_mtu()
1114 hwbm_pool->frag_size = SKB_DATA_ALIGN(sizeof(struct skb_shared_info)) + in mvneta_bm_update_mtu()
1118 num = hwbm_pool_add(hwbm_pool, hwbm_pool->size, GFP_ATOMIC); in mvneta_bm_update_mtu()
1119 if (num != hwbm_pool->size) { in mvneta_bm_update_mtu()
1121 bm_pool->id, num, hwbm_pool->size); in mvneta_bm_update_mtu()
2175 err = hwbm_pool_refill(&bm_pool->hwbm_pool, GFP_ATOMIC); in mvneta_rx_hwbm()
2182 frag_size = bm_pool->hwbm_pool.frag_size; in mvneta_rx_hwbm()
/Linux-v4.19/net/core/
Dhwbm.c17 void hwbm_buf_free(struct hwbm_pool *bm_pool, void *buf) in hwbm_buf_free()
27 int hwbm_pool_refill(struct hwbm_pool *bm_pool, gfp_t gfp) in hwbm_pool_refill()
50 int hwbm_pool_add(struct hwbm_pool *bm_pool, unsigned int buf_num, gfp_t gfp) in hwbm_pool_add()