Lines Matching refs:bd_table
61 struct bd_table *bd_table; in ep_bd_list_free() local
77 bd_table = bd_list->bd_table_array[index]; in ep_bd_list_free()
78 dev_dbg(bdc->dev, "bd_table:%p index:%d\n", bd_table, index); in ep_bd_list_free()
79 if (!bd_table) { in ep_bd_list_free()
83 if (!bd_table->start_bd) { in ep_bd_list_free()
90 bd_table->start_bd, in ep_bd_list_free()
91 (unsigned long long)bd_table->dma); in ep_bd_list_free()
94 bd_table->start_bd, in ep_bd_list_free()
95 bd_table->dma); in ep_bd_list_free()
97 kfree(bd_table); in ep_bd_list_free()
107 static inline void chain_table(struct bd_table *prev_table, in chain_table()
108 struct bd_table *next_table, in chain_table()
128 struct bd_table *prev_table = NULL; in ep_bd_list_alloc()
131 struct bd_table *bd_table; in ep_bd_list_alloc() local
147 num_tabs * sizeof(struct bd_table *), in ep_bd_list_alloc()
155 bd_table = kzalloc(sizeof(struct bd_table), GFP_ATOMIC); in ep_bd_list_alloc()
156 if (!bd_table) in ep_bd_list_alloc()
159 bd_table->start_bd = dma_pool_alloc(bdc->bd_table_pool, in ep_bd_list_alloc()
162 if (!bd_table->start_bd) in ep_bd_list_alloc()
165 bd_table->dma = dma; in ep_bd_list_alloc()
169 index, bd_table->start_bd, in ep_bd_list_alloc()
170 (unsigned long long)bd_table->dma, prev_table); in ep_bd_list_alloc()
172 ep->bd_list.bd_table_array[index] = bd_table; in ep_bd_list_alloc()
173 memset(bd_table->start_bd, 0, bd_p_tab * sizeof(struct bdc_bd)); in ep_bd_list_alloc()
175 chain_table(prev_table, bd_table, bd_p_tab); in ep_bd_list_alloc()
177 prev_table = bd_table; in ep_bd_list_alloc()
224 struct bd_table *bd_table; in bd_add_to_bdi() local
237 bd_table = bd_list->bd_table_array[tbi]; in bd_add_to_bdi()
238 dma_first_bd = bd_table->dma; in bd_add_to_bdi()
239 dma_last_bd = bd_table->dma + in bd_add_to_bdi()
747 struct bd_table *table; in ep_dequeue()