Lines Matching refs:idx_que
873 static void *get_idx_buf(struct hns_roce_idx_que *idx_que, u32 n) in get_idx_buf() argument
875 return hns_roce_buf_offset(idx_que->mtr.kmem, in get_idx_buf()
876 n << idx_que->entry_shift); in get_idx_buf()
884 bitmap_clear(srq->idx_que.bitmap, wqe_index, 1); in hns_roce_free_srq_wqe()
885 srq->idx_que.tail++; in hns_roce_free_srq_wqe()
892 struct hns_roce_idx_que *idx_que = &srq->idx_que; in hns_roce_srqwq_overflow() local
894 return idx_que->head - idx_que->tail >= srq->wqe_cnt; in hns_roce_srqwq_overflow()
920 struct hns_roce_idx_que *idx_que = &srq->idx_que; in get_srq_wqe_idx() local
923 pos = find_first_zero_bit(idx_que->bitmap, srq->wqe_cnt); in get_srq_wqe_idx()
927 bitmap_set(idx_que->bitmap, pos, 1); in get_srq_wqe_idx()
934 struct hns_roce_idx_que *idx_que = &srq->idx_que; in fill_wqe_idx() local
938 head = idx_que->head & (srq->wqe_cnt - 1); in fill_wqe_idx()
940 buf = get_idx_buf(idx_que, head); in fill_wqe_idx()
943 idx_que->head++; in fill_wqe_idx()
953 hr_reg_write(&db, DB_PI, srq->idx_que.head); in update_srq_db()
994 *srq->rdb.db_record = srq->idx_que.head & in hns_roce_v2_post_srq_recv()
5678 struct hns_roce_idx_que *idx_que = &srq->idx_que; in hns_roce_v2_write_srqc_index_queue() local
5686 ret = hns_roce_mtr_find(hr_dev, &idx_que->mtr, 0, mtts_idx, in hns_roce_v2_write_srqc_index_queue()
5694 dma_handle_idx = hns_roce_get_mtr_ba(&idx_que->mtr); in hns_roce_v2_write_srqc_index_queue()
5704 to_hr_hw_page_shift(idx_que->mtr.hem_cfg.ba_pg_shift)); in hns_roce_v2_write_srqc_index_queue()
5706 to_hr_hw_page_shift(idx_que->mtr.hem_cfg.buf_pg_shift)); in hns_roce_v2_write_srqc_index_queue()