Home
last modified time | relevance | path

Searched refs:hwq (Results 1 – 23 of 23) sorted by relevance

/Linux-v5.4/drivers/scsi/cxlflash/
Dmain.c164 struct hwq *hwq = get_hwq(afu, cmd->hwq_index); in cmd_complete() local
166 spin_lock_irqsave(&hwq->hsq_slock, lock_flags); in cmd_complete()
168 spin_unlock_irqrestore(&hwq->hsq_slock, lock_flags); in cmd_complete()
196 static void flush_pending_cmds(struct hwq *hwq) in flush_pending_cmds() argument
198 struct cxlflash_cfg *cfg = hwq->afu->parent; in flush_pending_cmds()
203 list_for_each_entry_safe(cmd, tmp, &hwq->pending_cmds, list) { in flush_pending_cmds()
240 static int context_reset(struct hwq *hwq, __be64 __iomem *reset_reg) in context_reset() argument
242 struct cxlflash_cfg *cfg = hwq->afu->parent; in context_reset()
249 dev_dbg(dev, "%s: hwq=%p\n", __func__, hwq); in context_reset()
251 spin_lock_irqsave(&hwq->hsq_slock, lock_flags); in context_reset()
[all …]
Dcommon.h196 struct hwq { struct
231 struct hwq hwqs[CXLFLASH_MAX_HWQS]; argument
233 int (*context_reset)(struct hwq *hwq);
255 static inline struct hwq *get_hwq(struct afu *afu, u32 index) in get_hwq()
Dsuperpipe.c267 struct hwq *hwq = get_hwq(afu, PRIMARY_HWQ); in afu_attach() local
291 val = hwq->ctx_hndl; in afu_attach()
298 val = SISL_RHT_CNT_ID((u64)MAX_RHT_PER_CONTEXT, (u64)(hwq->ctx_hndl)); in afu_attach()
1660 struct hwq *hwq = get_hwq(afu, PRIMARY_HWQ); in cxlflash_afu_recover() local
1737 reg = readq_be(&hwq->ctrl_map->mbox_r); in cxlflash_afu_recover()
/Linux-v5.4/drivers/infiniband/hw/bnxt_re/
Dqplib_fp.c76 dev_dbg(&scq->hwq.pdev->dev, in __bnxt_qplib_add_flush_qp()
84 dev_dbg(&rcq->hwq.pdev->dev, in __bnxt_qplib_add_flush_qp()
143 qp->sq.hwq.prod = 0; in bnxt_qplib_clean_qp()
144 qp->sq.hwq.cons = 0; in bnxt_qplib_clean_qp()
146 qp->rq.hwq.prod = 0; in bnxt_qplib_clean_qp()
147 qp->rq.hwq.cons = 0; in bnxt_qplib_clean_qp()
182 rq->hwq.max_elements * qp->rq_hdr_buf_size, in bnxt_qplib_free_qp_hdr_buf()
186 sq->hwq.max_elements * qp->sq_hdr_buf_size, in bnxt_qplib_free_qp_hdr_buf()
203 if (qp->sq_hdr_buf_size && sq->hwq.max_elements) { in bnxt_qplib_alloc_qp_hdr_buf()
205 sq->hwq.max_elements * in bnxt_qplib_alloc_qp_hdr_buf()
[all …]
Dqplib_res.c136 void bnxt_qplib_free_hwq(struct pci_dev *pdev, struct bnxt_qplib_hwq *hwq) in bnxt_qplib_free_hwq() argument
140 if (!hwq->max_elements) in bnxt_qplib_free_hwq()
142 if (hwq->level >= PBL_LVL_MAX) in bnxt_qplib_free_hwq()
145 for (i = 0; i < hwq->level + 1; i++) { in bnxt_qplib_free_hwq()
146 if (i == hwq->level) in bnxt_qplib_free_hwq()
147 __free_pbl(pdev, &hwq->pbl[i], hwq->is_user); in bnxt_qplib_free_hwq()
149 __free_pbl(pdev, &hwq->pbl[i], false); in bnxt_qplib_free_hwq()
152 hwq->level = PBL_LVL_MAX; in bnxt_qplib_free_hwq()
153 hwq->max_elements = 0; in bnxt_qplib_free_hwq()
154 hwq->element_size = 0; in bnxt_qplib_free_hwq()
[all …]
Dqplib_res.h49 #define HWQ_CMP(idx, hwq) ((idx) & ((hwq)->max_elements - 1)) argument
51 #define HWQ_FREE_SLOTS(hwq) (hwq->max_elements - \ argument
52 ((HWQ_CMP(hwq->prod, hwq)\
53 - HWQ_CMP(hwq->cons, hwq))\
54 & (hwq->max_elements - 1)))
234 void bnxt_qplib_free_hwq(struct pci_dev *pdev, struct bnxt_qplib_hwq *hwq);
235 int bnxt_qplib_alloc_init_hwq(struct pci_dev *pdev, struct bnxt_qplib_hwq *hwq,
Dqplib_sp.c587 if (mrw->hwq.max_elements) in bnxt_qplib_free_mrw()
588 bnxt_qplib_free_hwq(res->pdev, &mrw->hwq); in bnxt_qplib_free_mrw()
646 if (mrw->hwq.max_elements) { in bnxt_qplib_dereg_mrw()
649 bnxt_qplib_free_hwq(res->pdev, &mrw->hwq); in bnxt_qplib_dereg_mrw()
682 if (mr->hwq.max_elements) in bnxt_qplib_reg_mr()
683 bnxt_qplib_free_hwq(res->pdev, &mr->hwq); in bnxt_qplib_reg_mr()
685 mr->hwq.max_elements = pages; in bnxt_qplib_reg_mr()
687 rc = bnxt_qplib_alloc_init_hwq(res->pdev, &mr->hwq, NULL, in bnxt_qplib_reg_mr()
688 &mr->hwq.max_elements, in bnxt_qplib_reg_mr()
697 pbl_ptr = (dma_addr_t **)mr->hwq.pbl_ptr; in bnxt_qplib_reg_mr()
[all …]
Dqplib_fp.h53 struct bnxt_qplib_hwq hwq; member
237 struct bnxt_qplib_hwq hwq; member
340 return HWQ_CMP((qplib_q->hwq.prod + qplib_q->q_full_delta), in bnxt_qplib_queue_full()
341 &qplib_q->hwq) == HWQ_CMP(qplib_q->hwq.cons, in bnxt_qplib_queue_full()
342 &qplib_q->hwq); in bnxt_qplib_queue_full()
378 struct bnxt_qplib_hwq hwq; member
482 struct bnxt_qplib_hwq hwq; member
Dqplib_sp.h120 struct bnxt_qplib_hwq hwq; member
125 struct bnxt_qplib_hwq hwq; member
Dmain.c999 rdev->nq[i].hwq.max_elements = BNXT_RE_MAX_CQ_COUNT + in bnxt_re_alloc_res()
1008 pg_map = rdev->nq[i].hwq.pbl[PBL_LVL_0].pg_map_arr; in bnxt_re_alloc_res()
1009 pages = rdev->nq[i].hwq.pbl[rdev->nq[i].hwq.level].pg_count; in bnxt_re_alloc_res()
Dib_verbs.c2179 wqe->frmr.pbl_ptr = (__le64 *)qplib_frpl->hwq.pbl_ptr[0]; in bnxt_re_build_reg_wqe()
2180 wqe->frmr.pbl_dma_ptr = qplib_frpl->hwq.pbl_dma_ptr[0]; in bnxt_re_build_reg_wqe()
2183 wqe->frmr.levels = qplib_frpl->hwq.level + 1; in bnxt_re_build_reg_wqe()
2615 resp.tail = cq->qplib_cq.hwq.cons; in bnxt_re_create_cq()
3103 dev_dbg(&lib_qp->sq.hwq.pdev->dev, in send_phantom_wqe()
3105 lib_qp->id, lib_qp->sq.hwq.prod, in send_phantom_wqe()
3106 HWQ_CMP(lib_qp->sq.hwq.prod, &lib_qp->sq.hwq), in send_phantom_wqe()
3297 mr->qplib_mr.hwq.level = PBL_LVL_MAX; in bnxt_re_get_dma_mr()
/Linux-v5.4/drivers/net/wireless/mediatek/mt76/mt7615/
Ddma.c18 struct mt76_queue *hwq; in mt7615_init_tx_queues() local
21 hwq = devm_kzalloc(dev->mt76.dev, sizeof(*hwq), GFP_KERNEL); in mt7615_init_tx_queues()
22 if (!hwq) in mt7615_init_tx_queues()
25 err = mt76_queue_alloc(dev, hwq, 0, n_desc, 0, MT_TX_RING_BASE); in mt7615_init_tx_queues()
32 q->q = hwq; in mt7615_init_tx_queues()
42 struct mt76_queue *hwq; in mt7615_init_mcu_queue() local
45 hwq = devm_kzalloc(dev->mt76.dev, sizeof(*hwq), GFP_KERNEL); in mt7615_init_mcu_queue()
46 if (!hwq) in mt7615_init_mcu_queue()
49 err = mt76_queue_alloc(dev, hwq, idx, n_desc, 0, MT_TX_RING_BASE); in mt7615_init_mcu_queue()
54 q->q = hwq; in mt7615_init_mcu_queue()
/Linux-v5.4/include/scsi/
Dscsi_tcq.h26 u16 hwq; in scsi_host_find_tag() local
31 hwq = blk_mq_unique_tag_to_hwq(tag); in scsi_host_find_tag()
32 if (hwq < shost->tag_set.nr_hw_queues) { in scsi_host_find_tag()
33 req = blk_mq_tag_to_rq(shost->tag_set.tags[hwq], in scsi_host_find_tag()
/Linux-v5.4/drivers/net/wireless/mediatek/mt76/
Dtx.c340 struct mt76_queue *hwq = dev->q_tx[MT_TXQ_PSD].q; in mt76_release_buffered_frames() local
343 spin_lock_bh(&hwq->lock); in mt76_release_buffered_frames()
370 dev->queue_ops->kick(dev, hwq); in mt76_release_buffered_frames()
375 spin_unlock_bh(&hwq->lock); in mt76_release_buffered_frames()
386 struct mt76_queue *hwq = sq->q; in mt76_txq_send_burst() local
462 hwq->entry[idx].qid = sq - dev->q_tx; in mt76_txq_send_burst()
463 hwq->entry[idx].schedule = true; in mt76_txq_send_burst()
467 dev->queue_ops->kick(dev, hwq); in mt76_txq_send_burst()
476 struct mt76_queue *hwq = sq->q; in mt76_txq_schedule_list() local
482 spin_lock_bh(&hwq->lock); in mt76_txq_schedule_list()
[all …]
Dmt76x02_mmio.c103 struct mt76_queue *hwq; in mt76x02_init_tx_queue() local
106 hwq = devm_kzalloc(dev->mt76.dev, sizeof(*hwq), GFP_KERNEL); in mt76x02_init_tx_queue()
107 if (!hwq) in mt76x02_init_tx_queue()
110 err = mt76_queue_alloc(dev, hwq, idx, n_desc, 0, MT_TX_RING_BASE); in mt76x02_init_tx_queue()
115 q->q = hwq; in mt76x02_init_tx_queue()
/Linux-v5.4/drivers/net/wireless/mediatek/mt76/mt7603/
Ddma.c11 struct mt76_queue *hwq; in mt7603_init_tx_queue() local
14 hwq = devm_kzalloc(dev->mt76.dev, sizeof(*hwq), GFP_KERNEL); in mt7603_init_tx_queue()
15 if (!hwq) in mt7603_init_tx_queue()
18 err = mt76_queue_alloc(dev, hwq, idx, n_desc, 0, MT_TX_RING_BASE); in mt7603_init_tx_queue()
23 q->q = hwq; in mt7603_init_tx_queue()
/Linux-v5.4/drivers/net/wireless/ti/wlcore/
Dtx.c1200 int hwq = wlcore_tx_get_mac80211_queue(wlvif, queue); in wlcore_stop_queue_locked() local
1201 bool stopped = !!wl->queue_stop_reasons[hwq]; in wlcore_stop_queue_locked()
1204 WARN_ON_ONCE(test_and_set_bit(reason, &wl->queue_stop_reasons[hwq])); in wlcore_stop_queue_locked()
1209 ieee80211_stop_queue(wl->hw, hwq); in wlcore_stop_queue_locked()
1226 int hwq = wlcore_tx_get_mac80211_queue(wlvif, queue); in wlcore_wake_queue() local
1231 WARN_ON_ONCE(!test_and_clear_bit(reason, &wl->queue_stop_reasons[hwq])); in wlcore_wake_queue()
1233 if (wl->queue_stop_reasons[hwq]) in wlcore_wake_queue()
1236 ieee80211_wake_queue(wl->hw, hwq); in wlcore_wake_queue()
1303 int hwq = wlcore_tx_get_mac80211_queue(wlvif, queue); in wlcore_is_queue_stopped_by_reason_locked() local
1306 return test_bit(reason, &wl->queue_stop_reasons[hwq]); in wlcore_is_queue_stopped_by_reason_locked()
[all …]
/Linux-v5.4/drivers/scsi/
Dvirtio_scsi.c536 u16 hwq = blk_mq_unique_tag_to_hwq(tag); in virtscsi_pick_vq_mq() local
538 return &vscsi->req_vqs[hwq]; in virtscsi_pick_vq_mq()
711 static void virtscsi_commit_rqs(struct Scsi_Host *shost, u16 hwq) in virtscsi_commit_rqs() argument
715 virtscsi_kick_vq(&vscsi->req_vqs[hwq]); in virtscsi_commit_rqs()
Dscsi_debug.c3699 u16 hwq = blk_mq_unique_tag_to_hwq(tag); in get_queue() local
3701 pr_debug("tag=%#x, hwq=%d\n", tag, hwq); in get_queue()
3702 if (WARN_ON_ONCE(hwq >= submit_queues)) in get_queue()
3703 hwq = 0; in get_queue()
3704 return sdebug_q_arr + hwq; in get_queue()
/Linux-v5.4/drivers/net/wireless/intel/iwlegacy/
Dcommon.h2248 il_set_swq_id(struct il_tx_queue *txq, u8 ac, u8 hwq) in il_set_swq_id() argument
2251 BUG_ON(hwq > 31); /* only use 5 bits */ in il_set_swq_id()
2253 txq->swq_id = (hwq << 2) | ac; in il_set_swq_id()
2274 u8 hwq = (queue >> 2) & 0x1f; in il_wake_queue() local
2276 if (test_and_clear_bit(hwq, il->queue_stopped)) in il_wake_queue()
2285 u8 hwq = (queue >> 2) & 0x1f; in il_stop_queue() local
2287 if (!test_and_set_bit(hwq, il->queue_stopped)) in il_stop_queue()
/Linux-v5.4/drivers/block/
Dnbd.c670 u16 hwq; in nbd_read_stat() local
694 hwq = blk_mq_unique_tag_to_hwq(tag); in nbd_read_stat()
695 if (hwq < nbd->tag_set.nr_hw_queues) in nbd_read_stat()
696 req = blk_mq_tag_to_rq(nbd->tag_set.tags[hwq], in nbd_read_stat()
Dskd_main.c1464 u16 hwq = 0; in skd_isr_completion_posted() local
1520 WARN_ON_ONCE(blk_mq_tag_to_rq(skdev->tag_set.tags[hwq], in skd_isr_completion_posted()
1526 rq = blk_mq_tag_to_rq(skdev->tag_set.tags[hwq], tag); in skd_isr_completion_posted()
/Linux-v5.4/drivers/scsi/qla2xxx/
Dqla_os.c829 uint16_t hwq; in qla2xxx_queuecommand() local
833 hwq = blk_mq_unique_tag_to_hwq(tag); in qla2xxx_queuecommand()
834 qpair = ha->queue_pair_map[hwq]; in qla2xxx_queuecommand()