Lines Matching full:ab
43 struct ath11k_base *ab = ar->ab; in ath11k_dbring_bufs_replenish() local
51 srng = &ab->hal.srng_list[ring->refill_srng.ring_id]; in ath11k_dbring_bufs_replenish()
55 ath11k_hal_srng_access_begin(ab, srng); in ath11k_dbring_bufs_replenish()
60 paddr = dma_map_single(ab->dev, ptr_aligned, ring->buf_sz, in ath11k_dbring_bufs_replenish()
63 ret = dma_mapping_error(ab->dev, paddr); in ath11k_dbring_bufs_replenish()
75 desc = ath11k_hal_srng_src_get_next_entry(ab, srng); in ath11k_dbring_bufs_replenish()
89 ath11k_hal_srng_access_end(ab, srng); in ath11k_dbring_bufs_replenish()
98 dma_unmap_single(ab->dev, paddr, ring->buf_sz, in ath11k_dbring_bufs_replenish()
101 ath11k_hal_srng_access_end(ab, srng); in ath11k_dbring_bufs_replenish()
115 srng = &ar->ab->hal.srng_list[ring->refill_srng.ring_id]; in ath11k_dbring_fill_bufs()
119 num_free = ath11k_hal_srng_src_num_free(ar->ab, srng, true); in ath11k_dbring_fill_bufs()
137 ath11k_warn(ar->ab, "failed to replenish db ring num_remain %d req_ent %d\n", in ath11k_dbring_fill_bufs()
176 ath11k_warn(ar->ab, "failed to setup db ring cfg\n"); in ath11k_dbring_wmi_cfg_setup()
202 struct ath11k_base *ab = ar->ab; in ath11k_dbring_buf_setup() local
206 srng = &ab->hal.srng_list[ring->refill_srng.ring_id]; in ath11k_dbring_buf_setup()
208 ath11k_hal_srng_get_entrysize(ab, HAL_RXDMA_DIR_BUF); in ath11k_dbring_buf_setup()
213 ring->hp_addr = ath11k_hal_srng_get_hp_addr(ar->ab, srng); in ath11k_dbring_buf_setup()
214 ring->tp_addr = ath11k_hal_srng_get_tp_addr(ar->ab, srng); in ath11k_dbring_buf_setup()
226 ret = ath11k_dp_srng_setup(ar->ab, &ring->refill_srng, HAL_RXDMA_DIR_BUF, in ath11k_dbring_srng_setup()
229 ath11k_warn(ar->ab, "failed to setup srng: %d ring_id %d\n", in ath11k_dbring_srng_setup()
236 ath11k_dp_srng_cleanup(ar->ab, &ring->refill_srng); in ath11k_dbring_srng_setup()
240 int ath11k_dbring_get_cap(struct ath11k_base *ab, in ath11k_dbring_get_cap() argument
247 if (!ab->num_db_cap || !ab->db_caps) in ath11k_dbring_get_cap()
253 for (i = 0; i < ab->num_db_cap; i++) { in ath11k_dbring_get_cap()
254 if (pdev_idx == ab->db_caps[i].pdev_id && in ath11k_dbring_get_cap()
255 id == ab->db_caps[i].id) { in ath11k_dbring_get_cap()
256 *db_cap = ab->db_caps[i]; in ath11k_dbring_get_cap()
265 int ath11k_dbring_buffer_release_event(struct ath11k_base *ab, in ath11k_dbring_buffer_release_event() argument
286 if (pdev_idx >= ab->num_radios) { in ath11k_dbring_buffer_release_event()
287 ath11k_warn(ab, "Invalid pdev id %d\n", pdev_idx); in ath11k_dbring_buffer_release_event()
293 ath11k_warn(ab, "Buffer entry %d mismatch meta entry %d\n", in ath11k_dbring_buffer_release_event()
299 ar = ab->pdevs[pdev_idx].ar; in ath11k_dbring_buffer_release_event()
302 if (!rcu_dereference(ab->pdevs_active[pdev_idx])) { in ath11k_dbring_buffer_release_event()
313 ath11k_warn(ab, "Recv dma buffer release ev on unsupp module %d\n", in ath11k_dbring_buffer_release_event()
323 srng = &ab->hal.srng_list[ring->refill_srng.ring_id]; in ath11k_dbring_buffer_release_event()
350 dma_unmap_single(ab->dev, buff->paddr, ring->buf_sz, in ath11k_dbring_buffer_release_event()
380 ath11k_dp_srng_cleanup(ar->ab, &ring->refill_srng); in ath11k_dbring_srng_cleanup()
391 dma_unmap_single(ar->ab->dev, buff->paddr, in ath11k_dbring_buf_cleanup()