Lines Matching refs:pool_id

26 #define DP_TX_DESC_PAGE_DIVIDER(soc, num_desc_per_page, pool_id)     \  argument
29 soc->tx_desc[pool_id].offset_filter = num_desc_per_page - 1; \
36 soc->tx_desc[pool_id].page_divider = (sig_bit - 1); \
40 #define DP_TX_DESC_PAGE_DIVIDER(soc, num_desc_per_page, pool_id) {} argument
84 dp_tx_desc_release(soc, tx_desc, tx_desc->pool_id); in dp_tx_desc_clean_up()
139 static void dp_tx_desc_pool_alloc_mem(struct dp_soc *soc, int8_t pool_id, in dp_tx_desc_pool_alloc_mem() argument
147 dp_global->spcl_tx_desc[soc->arch_id][pool_id] = in dp_tx_desc_pool_alloc_mem()
150 dp_global->tx_desc[soc->arch_id][pool_id] = in dp_tx_desc_pool_alloc_mem()
155 static void dp_tx_desc_pool_free_mem(struct dp_soc *soc, int8_t pool_id, in dp_tx_desc_pool_free_mem() argument
162 if (!dp_global->spcl_tx_desc[soc->arch_id][pool_id]) in dp_tx_desc_pool_free_mem()
165 qdf_mem_free(dp_global->spcl_tx_desc[soc->arch_id][pool_id]); in dp_tx_desc_pool_free_mem()
166 dp_global->spcl_tx_desc[soc->arch_id][pool_id] = NULL; in dp_tx_desc_pool_free_mem()
168 if (!dp_global->tx_desc[soc->arch_id][pool_id]) in dp_tx_desc_pool_free_mem()
171 qdf_mem_free(dp_global->tx_desc[soc->arch_id][pool_id]); in dp_tx_desc_pool_free_mem()
172 dp_global->tx_desc[soc->arch_id][pool_id] = NULL; in dp_tx_desc_pool_free_mem()
176 static void dp_tx_desc_pool_alloc_mem(struct dp_soc *soc, int8_t pool_id, in dp_tx_desc_pool_alloc_mem() argument
181 static void dp_tx_desc_pool_free_mem(struct dp_soc *soc, int8_t pool_id, in dp_tx_desc_pool_free_mem() argument
187 QDF_STATUS dp_tx_desc_pool_alloc(struct dp_soc *soc, uint8_t pool_id, in dp_tx_desc_pool_alloc() argument
197 dp_tx_desc_pool_alloc_mem(soc, pool_id, spcl_tx_desc); in dp_tx_desc_pool_alloc()
199 tx_desc_pool = dp_get_spcl_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_alloc()
203 tx_desc_pool = dp_get_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_alloc()
205 num_elem_t = dp_get_updated_tx_desc(soc->ctrl_psoc, pool_id, num_elem); in dp_tx_desc_pool_alloc()
220 status = soc->arch_ops.dp_tx_desc_pool_alloc(soc, num_elem_t, pool_id); in dp_tx_desc_pool_alloc()
229 void dp_tx_desc_pool_free(struct dp_soc *soc, uint8_t pool_id, in dp_tx_desc_pool_free() argument
236 tx_desc_pool = dp_get_spcl_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_free()
239 tx_desc_pool = dp_get_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_free()
249 soc->arch_ops.dp_tx_desc_pool_free(soc, pool_id); in dp_tx_desc_pool_free()
250 dp_tx_desc_pool_free_mem(soc, pool_id, spcl_tx_desc); in dp_tx_desc_pool_free()
253 QDF_STATUS dp_tx_desc_pool_init(struct dp_soc *soc, uint8_t pool_id, in dp_tx_desc_pool_init() argument
262 tx_desc_pool = dp_get_spcl_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_init()
265 tx_desc_pool = dp_get_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_init()
266 num_elem_t = dp_get_updated_tx_desc(soc->ctrl_psoc, pool_id, num_elem); in dp_tx_desc_pool_init()
280 pool_id, spcl_tx_desc)) { in dp_tx_desc_pool_init()
293 void dp_tx_desc_pool_deinit(struct dp_soc *soc, uint8_t pool_id, in dp_tx_desc_pool_deinit() argument
299 tx_desc_pool = dp_get_spcl_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_deinit()
301 tx_desc_pool = dp_get_tx_desc_pool(soc, pool_id); in dp_tx_desc_pool_deinit()
303 pool_id, spcl_tx_desc); in dp_tx_desc_pool_deinit()
310 uint8_t pool_id) in dp_tx_ext_desc_pool_alloc_by_id() argument
318 dp_tx_ext_desc_pool = &((soc)->tx_ext_desc[pool_id]); in dp_tx_ext_desc_pool_alloc_by_id()
362 uint8_t pool_id, count; in dp_tx_ext_desc_pool_alloc() local
364 for (pool_id = 0; pool_id < num_pool; pool_id++) { in dp_tx_ext_desc_pool_alloc()
365 status = dp_tx_ext_desc_pool_alloc_by_id(soc, num_elem, pool_id); in dp_tx_ext_desc_pool_alloc()
367 dp_err("failed to allocate tx ext desc pool %d", pool_id); in dp_tx_ext_desc_pool_alloc()
375 for (count = 0; count < pool_id; count++) in dp_tx_ext_desc_pool_alloc()
382 uint8_t pool_id) in dp_tx_ext_desc_pool_init_by_id() argument
392 dp_tx_ext_desc_pool = &((soc)->tx_ext_desc[pool_id]); in dp_tx_ext_desc_pool_init_by_id()
393 soc->tx_ext_desc[pool_id].elem_size = in dp_tx_ext_desc_pool_init_by_id()
395 soc->tx_ext_desc[pool_id].link_elem_size = in dp_tx_ext_desc_pool_init_by_id()
397 soc->tx_ext_desc[pool_id].elem_count = num_elem; in dp_tx_ext_desc_pool_init_by_id()
459 uint8_t pool_id; in dp_tx_ext_desc_pool_init() local
462 for (pool_id = 0; pool_id < num_pool; pool_id++) { in dp_tx_ext_desc_pool_init()
463 status = dp_tx_ext_desc_pool_init_by_id(soc, num_elem, pool_id); in dp_tx_ext_desc_pool_init()
465 dp_err("failed to init ext desc pool %d", pool_id); in dp_tx_ext_desc_pool_init()
475 void dp_tx_ext_desc_pool_free_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_ext_desc_pool_free_by_id() argument
480 dp_tx_ext_desc_pool = &((soc)->tx_ext_desc[pool_id]); in dp_tx_ext_desc_pool_free_by_id()
494 uint8_t pool_id; in dp_tx_ext_desc_pool_free() local
496 for (pool_id = 0; pool_id < num_pool; pool_id++) in dp_tx_ext_desc_pool_free()
497 dp_tx_ext_desc_pool_free_by_id(soc, pool_id); in dp_tx_ext_desc_pool_free()
500 void dp_tx_ext_desc_pool_deinit_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_ext_desc_pool_deinit_by_id() argument
504 dp_tx_ext_desc_pool = &((soc)->tx_ext_desc[pool_id]); in dp_tx_ext_desc_pool_deinit_by_id()
510 uint8_t pool_id; in dp_tx_ext_desc_pool_deinit() local
512 for (pool_id = 0; pool_id < num_pool; pool_id++) in dp_tx_ext_desc_pool_deinit()
513 dp_tx_ext_desc_pool_deinit_by_id(soc, pool_id); in dp_tx_ext_desc_pool_deinit()
518 uint8_t pool_id) in dp_tx_tso_desc_pool_alloc_by_id() argument
525 tso_desc_pool = &soc->tx_tso_desc[pool_id]; in dp_tx_tso_desc_pool_alloc_by_id()
541 uint32_t pool_id, i; in dp_tx_tso_desc_pool_alloc() local
544 for (pool_id = 0; pool_id < num_pool; pool_id++) { in dp_tx_tso_desc_pool_alloc()
546 pool_id); in dp_tx_tso_desc_pool_alloc()
548 dp_err("failed to allocate TSO desc pool %d", pool_id); in dp_tx_tso_desc_pool_alloc()
556 for (i = 0; i < pool_id; i++) in dp_tx_tso_desc_pool_alloc()
562 void dp_tx_tso_desc_pool_free_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_desc_pool_free_by_id() argument
566 tso_desc_pool = &soc->tx_tso_desc[pool_id]; in dp_tx_tso_desc_pool_free_by_id()
574 uint32_t pool_id; in dp_tx_tso_desc_pool_free() local
576 for (pool_id = 0; pool_id < num_pool; pool_id++) in dp_tx_tso_desc_pool_free()
577 dp_tx_tso_desc_pool_free_by_id(soc, pool_id); in dp_tx_tso_desc_pool_free()
581 uint8_t pool_id) in dp_tx_tso_desc_pool_init_by_id() argument
588 tso_desc_pool = &soc->tx_tso_desc[pool_id]; in dp_tx_tso_desc_pool_init_by_id()
615 uint32_t pool_id; in dp_tx_tso_desc_pool_init() local
617 for (pool_id = 0; pool_id < num_pool; pool_id++) { in dp_tx_tso_desc_pool_init()
619 pool_id); in dp_tx_tso_desc_pool_init()
621 dp_err("failed to initialise TSO desc pool %d", pool_id); in dp_tx_tso_desc_pool_init()
629 void dp_tx_tso_desc_pool_deinit_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_desc_pool_deinit_by_id() argument
633 tso_desc_pool = &soc->tx_tso_desc[pool_id]; in dp_tx_tso_desc_pool_deinit_by_id()
647 uint32_t pool_id; in dp_tx_tso_desc_pool_deinit() local
649 for (pool_id = 0; pool_id < num_pool; pool_id++) in dp_tx_tso_desc_pool_deinit()
650 dp_tx_tso_desc_pool_deinit_by_id(soc, pool_id); in dp_tx_tso_desc_pool_deinit()
655 uint8_t pool_id) in dp_tx_tso_num_seg_pool_alloc_by_id() argument
662 tso_num_seg_pool = &soc->tx_tso_num_seg[pool_id]; in dp_tx_tso_num_seg_pool_alloc_by_id()
680 uint32_t pool_id, i; in dp_tx_tso_num_seg_pool_alloc() local
683 for (pool_id = 0; pool_id < num_pool; pool_id++) { in dp_tx_tso_num_seg_pool_alloc()
685 pool_id); in dp_tx_tso_num_seg_pool_alloc()
687 dp_err("failed to allocate TSO num seg pool %d", pool_id); in dp_tx_tso_num_seg_pool_alloc()
695 for (i = 0; i < pool_id; i++) in dp_tx_tso_num_seg_pool_alloc()
696 dp_tx_tso_num_seg_pool_free_by_id(soc, pool_id); in dp_tx_tso_num_seg_pool_alloc()
701 void dp_tx_tso_num_seg_pool_free_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_num_seg_pool_free_by_id() argument
705 tso_num_seg_pool = &soc->tx_tso_num_seg[pool_id]; in dp_tx_tso_num_seg_pool_free_by_id()
713 uint32_t pool_id; in dp_tx_tso_num_seg_pool_free() local
715 for (pool_id = 0; pool_id < num_pool; pool_id++) in dp_tx_tso_num_seg_pool_free()
716 dp_tx_tso_num_seg_pool_free_by_id(soc, pool_id); in dp_tx_tso_num_seg_pool_free()
721 uint8_t pool_id) in dp_tx_tso_num_seg_pool_init_by_id() argument
727 tso_num_seg_pool = &soc->tx_tso_num_seg[pool_id]; in dp_tx_tso_num_seg_pool_init_by_id()
751 uint32_t pool_id; in dp_tx_tso_num_seg_pool_init() local
754 for (pool_id = 0; pool_id < num_pool; pool_id++) { in dp_tx_tso_num_seg_pool_init()
756 pool_id); in dp_tx_tso_num_seg_pool_init()
758 dp_err("failed to initialise TSO num seg pool %d", pool_id); in dp_tx_tso_num_seg_pool_init()
766 void dp_tx_tso_num_seg_pool_deinit_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_num_seg_pool_deinit_by_id() argument
770 tso_num_seg_pool = &soc->tx_tso_num_seg[pool_id]; in dp_tx_tso_num_seg_pool_deinit_by_id()
784 uint32_t pool_id; in dp_tx_tso_num_seg_pool_deinit() local
786 for (pool_id = 0; pool_id < num_pool; pool_id++) in dp_tx_tso_num_seg_pool_deinit()
787 dp_tx_tso_num_seg_pool_deinit_by_id(soc, pool_id); in dp_tx_tso_num_seg_pool_deinit()
791 uint8_t pool_id) in dp_tx_tso_desc_pool_alloc_by_id() argument
803 uint8_t pool_id) in dp_tx_tso_desc_pool_init_by_id() argument
814 void dp_tx_tso_desc_pool_free_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_desc_pool_free_by_id() argument
822 void dp_tx_tso_desc_pool_deinit_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_desc_pool_deinit_by_id() argument
832 uint8_t pool_id) in dp_tx_tso_num_seg_pool_alloc_by_id() argument
843 void dp_tx_tso_num_seg_pool_free_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_num_seg_pool_free_by_id() argument
853 uint8_t pool_id) in dp_tx_tso_num_seg_pool_init_by_id() argument
864 void dp_tx_tso_num_seg_pool_deinit_by_id(struct dp_soc *soc, uint8_t pool_id) in dp_tx_tso_num_seg_pool_deinit_by_id() argument