Lines Matching refs:hwq
92 struct bnxt_qplib_hwq *hwq = &cmdq->hwq; in __send_message() local
126 spin_lock_irqsave(&hwq->lock, flags); in __send_message()
127 if (req->cmd_size >= HWQ_FREE_SLOTS(hwq)) { in __send_message()
129 spin_unlock_irqrestore(&hwq->lock, flags); in __send_message()
143 spin_unlock_irqrestore(&hwq->lock, flags); in __send_message()
168 sw_prod = HWQ_CMP(hwq->prod, hwq); in __send_message()
169 cmdqe = bnxt_qplib_get_qe(hwq, sw_prod, NULL); in __send_message()
180 hwq->prod++; in __send_message()
184 cmdq_prod = hwq->prod; in __send_message()
200 spin_unlock_irqrestore(&hwq->lock, flags); in __send_message()
301 struct bnxt_qplib_hwq *hwq = &rcfw->cmdq.hwq; in bnxt_qplib_process_qp_event() local
339 spin_lock_irqsave_nested(&hwq->lock, flags, in bnxt_qplib_process_qp_event()
362 hwq->cons += crsqe->req_size; in bnxt_qplib_process_qp_event()
367 spin_unlock_irqrestore(&hwq->lock, flags); in bnxt_qplib_process_qp_event()
378 struct bnxt_qplib_hwq *hwq = &creq->hwq; in bnxt_qplib_service_creq() local
384 spin_lock_irqsave(&hwq->lock, flags); in bnxt_qplib_service_creq()
385 raw_cons = hwq->cons; in bnxt_qplib_service_creq()
387 sw_cons = HWQ_CMP(raw_cons, hwq); in bnxt_qplib_service_creq()
388 creqe = bnxt_qplib_get_qe(hwq, sw_cons, NULL); in bnxt_qplib_service_creq()
389 if (!CREQ_CMP_VALID(creqe, raw_cons, hwq->max_elements)) in bnxt_qplib_service_creq()
422 if (hwq->cons != raw_cons) { in bnxt_qplib_service_creq()
423 hwq->cons = raw_cons; in bnxt_qplib_service_creq()
427 spin_unlock_irqrestore(&hwq->lock, flags); in bnxt_qplib_service_creq()
434 struct bnxt_qplib_hwq *hwq; in bnxt_qplib_creq_irq() local
438 hwq = &creq->hwq; in bnxt_qplib_creq_irq()
440 sw_cons = HWQ_CMP(hwq->cons, hwq); in bnxt_qplib_creq_irq()
441 prefetch(bnxt_qplib_get_qe(hwq, sw_cons, NULL)); in bnxt_qplib_creq_irq()
557 bnxt_qplib_free_hwq(rcfw->res, &rcfw->cmdq.hwq); in bnxt_qplib_free_rcfw_channel()
558 bnxt_qplib_free_hwq(rcfw->res, &rcfw->creq.hwq); in bnxt_qplib_free_rcfw_channel()
587 if (bnxt_qplib_alloc_init_hwq(&creq->hwq, &hwq_attr)) { in bnxt_qplib_alloc_rcfw_channel()
601 if (bnxt_qplib_alloc_init_hwq(&cmdq->hwq, &hwq_attr)) { in bnxt_qplib_alloc_rcfw_channel()
607 rcfw->crsqe_tbl = kcalloc(cmdq->hwq.max_elements, in bnxt_qplib_alloc_rcfw_channel()
769 creq_db->dbinfo.hwq = &rcfw->creq.hwq; in bnxt_qplib_map_creq_db()
785 init.cmdq_pbl = cpu_to_le64(cmdq->hwq.pbl[PBL_LVL_0].pg_map_arr[0]); in bnxt_qplib_start_rcfw()
790 ((cmdq->hwq.level << in bnxt_qplib_start_rcfw()