Home
last modified time | relevance | path

Searched refs:idx_que (Results 1 – 3 of 3) sorted by relevance

/linux-6.12.1/drivers/infiniband/hw/hns/
Dhns_roce_srq.c169 struct hns_roce_idx_que *idx_que = &srq->idx_que; in alloc_srq_idx() local
174 srq->idx_que.entry_shift = ilog2(HNS_ROCE_IDX_QUE_ENTRY_SZ); in alloc_srq_idx()
178 srq->idx_que.entry_shift); in alloc_srq_idx()
182 ret = hns_roce_mtr_create(hr_dev, &idx_que->mtr, &buf_attr, in alloc_srq_idx()
192 idx_que->bitmap = bitmap_zalloc(srq->wqe_cnt, GFP_KERNEL); in alloc_srq_idx()
193 if (!idx_que->bitmap) { in alloc_srq_idx()
200 idx_que->head = 0; in alloc_srq_idx()
201 idx_que->tail = 0; in alloc_srq_idx()
205 hns_roce_mtr_destroy(hr_dev, &idx_que->mtr); in alloc_srq_idx()
212 struct hns_roce_idx_que *idx_que = &srq->idx_que; in free_srq_idx() local
[all …]
Dhns_roce_hw_v2.c873 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()
[all …]
Dhns_roce_device.h472 struct hns_roce_idx_que idx_que; member