Lines Matching refs:hw_resc

5972 	struct bnxt_hw_resc *hw_resc = &bp->hw_resc;  in bnxt_hwrm_get_rings()  local
5992 hw_resc->resv_tx_rings = le16_to_cpu(resp->alloc_tx_rings); in bnxt_hwrm_get_rings()
5996 hw_resc->resv_rx_rings = le16_to_cpu(resp->alloc_rx_rings); in bnxt_hwrm_get_rings()
5997 hw_resc->resv_hw_ring_grps = in bnxt_hwrm_get_rings()
5999 hw_resc->resv_vnics = le16_to_cpu(resp->alloc_vnics); in bnxt_hwrm_get_rings()
6002 hw_resc->resv_irqs = cp; in bnxt_hwrm_get_rings()
6004 int rx = hw_resc->resv_rx_rings; in bnxt_hwrm_get_rings()
6005 int tx = hw_resc->resv_tx_rings; in bnxt_hwrm_get_rings()
6013 hw_resc->resv_rx_rings = rx; in bnxt_hwrm_get_rings()
6014 hw_resc->resv_tx_rings = tx; in bnxt_hwrm_get_rings()
6016 hw_resc->resv_irqs = le16_to_cpu(resp->alloc_msix); in bnxt_hwrm_get_rings()
6017 hw_resc->resv_hw_ring_grps = rx; in bnxt_hwrm_get_rings()
6019 hw_resc->resv_cp_rings = cp; in bnxt_hwrm_get_rings()
6020 hw_resc->resv_stat_ctxs = stats; in bnxt_hwrm_get_rings()
6170 bp->hw_resc.resv_tx_rings = tx_rings; in bnxt_hwrm_reserve_pf_rings()
6183 bp->hw_resc.resv_tx_rings = tx_rings; in bnxt_hwrm_reserve_vf_rings()
6255 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in bnxt_check_rss_tbl_no_rmgr() local
6258 if (hw_resc->resv_rx_rings != bp->rx_nr_rings) { in bnxt_check_rss_tbl_no_rmgr()
6259 hw_resc->resv_rx_rings = bp->rx_nr_rings; in bnxt_check_rss_tbl_no_rmgr()
6267 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in bnxt_need_reserve_rings() local
6273 if (hw_resc->resv_tx_rings != bp->tx_nr_rings && in bnxt_need_reserve_rings()
6291 if (hw_resc->resv_rx_rings != rx || hw_resc->resv_cp_rings != cp || in bnxt_need_reserve_rings()
6292 hw_resc->resv_vnics != vnic || hw_resc->resv_stat_ctxs != stat || in bnxt_need_reserve_rings()
6293 (hw_resc->resv_hw_ring_grps != grp && in bnxt_need_reserve_rings()
6297 hw_resc->resv_irqs != nq) in bnxt_need_reserve_rings()
6304 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in __bnxt_reserve_rings() local
6328 tx = hw_resc->resv_tx_rings; in __bnxt_reserve_rings()
6330 rx = hw_resc->resv_rx_rings; in __bnxt_reserve_rings()
6331 cp = hw_resc->resv_irqs; in __bnxt_reserve_rings()
6332 grp = hw_resc->resv_hw_ring_grps; in __bnxt_reserve_rings()
6333 vnic = hw_resc->resv_vnics; in __bnxt_reserve_rings()
6334 stat = hw_resc->resv_stat_ctxs; in __bnxt_reserve_rings()
7370 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in bnxt_hwrm_func_resc_qcaps() local
7383 hw_resc->max_tx_sch_inputs = le16_to_cpu(resp->max_tx_scheduler_inputs); in bnxt_hwrm_func_resc_qcaps()
7387 hw_resc->min_rsscos_ctxs = le16_to_cpu(resp->min_rsscos_ctx); in bnxt_hwrm_func_resc_qcaps()
7388 hw_resc->max_rsscos_ctxs = le16_to_cpu(resp->max_rsscos_ctx); in bnxt_hwrm_func_resc_qcaps()
7389 hw_resc->min_cp_rings = le16_to_cpu(resp->min_cmpl_rings); in bnxt_hwrm_func_resc_qcaps()
7390 hw_resc->max_cp_rings = le16_to_cpu(resp->max_cmpl_rings); in bnxt_hwrm_func_resc_qcaps()
7391 hw_resc->min_tx_rings = le16_to_cpu(resp->min_tx_rings); in bnxt_hwrm_func_resc_qcaps()
7392 hw_resc->max_tx_rings = le16_to_cpu(resp->max_tx_rings); in bnxt_hwrm_func_resc_qcaps()
7393 hw_resc->min_rx_rings = le16_to_cpu(resp->min_rx_rings); in bnxt_hwrm_func_resc_qcaps()
7394 hw_resc->max_rx_rings = le16_to_cpu(resp->max_rx_rings); in bnxt_hwrm_func_resc_qcaps()
7395 hw_resc->min_hw_ring_grps = le16_to_cpu(resp->min_hw_ring_grps); in bnxt_hwrm_func_resc_qcaps()
7396 hw_resc->max_hw_ring_grps = le16_to_cpu(resp->max_hw_ring_grps); in bnxt_hwrm_func_resc_qcaps()
7397 hw_resc->min_l2_ctxs = le16_to_cpu(resp->min_l2_ctxs); in bnxt_hwrm_func_resc_qcaps()
7398 hw_resc->max_l2_ctxs = le16_to_cpu(resp->max_l2_ctxs); in bnxt_hwrm_func_resc_qcaps()
7399 hw_resc->min_vnics = le16_to_cpu(resp->min_vnics); in bnxt_hwrm_func_resc_qcaps()
7400 hw_resc->max_vnics = le16_to_cpu(resp->max_vnics); in bnxt_hwrm_func_resc_qcaps()
7401 hw_resc->min_stat_ctxs = le16_to_cpu(resp->min_stat_ctx); in bnxt_hwrm_func_resc_qcaps()
7402 hw_resc->max_stat_ctxs = le16_to_cpu(resp->max_stat_ctx); in bnxt_hwrm_func_resc_qcaps()
7407 hw_resc->max_nqs = max_msix; in bnxt_hwrm_func_resc_qcaps()
7408 hw_resc->max_hw_ring_grps = hw_resc->max_rx_rings; in bnxt_hwrm_func_resc_qcaps()
7490 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in __bnxt_hwrm_func_qcaps() local
7533 hw_resc->max_rsscos_ctxs = le16_to_cpu(resp->max_rsscos_ctx); in __bnxt_hwrm_func_qcaps()
7534 hw_resc->max_cp_rings = le16_to_cpu(resp->max_cmpl_rings); in __bnxt_hwrm_func_qcaps()
7535 hw_resc->max_tx_rings = le16_to_cpu(resp->max_tx_rings); in __bnxt_hwrm_func_qcaps()
7536 hw_resc->max_rx_rings = le16_to_cpu(resp->max_rx_rings); in __bnxt_hwrm_func_qcaps()
7537 hw_resc->max_hw_ring_grps = le32_to_cpu(resp->max_hw_ring_grps); in __bnxt_hwrm_func_qcaps()
7538 if (!hw_resc->max_hw_ring_grps) in __bnxt_hwrm_func_qcaps()
7539 hw_resc->max_hw_ring_grps = hw_resc->max_tx_rings; in __bnxt_hwrm_func_qcaps()
7540 hw_resc->max_l2_ctxs = le16_to_cpu(resp->max_l2_ctxs); in __bnxt_hwrm_func_qcaps()
7541 hw_resc->max_vnics = le16_to_cpu(resp->max_vnics); in __bnxt_hwrm_func_qcaps()
7542 hw_resc->max_stat_ctxs = le16_to_cpu(resp->max_stat_ctx); in __bnxt_hwrm_func_qcaps()
8790 return bp->hw_resc.max_rsscos_ctxs; in bnxt_get_max_func_rss_ctxs()
8795 return bp->hw_resc.max_vnics; in bnxt_get_max_func_vnics()
8801 return bp->hw_resc.max_stat_ctxs; in bnxt_get_max_func_stat_ctxs()
8806 return bp->hw_resc.max_cp_rings; in bnxt_get_max_func_cp_rings()
8811 unsigned int cp = bp->hw_resc.max_cp_rings; in bnxt_get_max_func_cp_rings_for_en()
8821 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in bnxt_get_max_func_irqs() local
8824 return min_t(unsigned int, hw_resc->max_irqs, hw_resc->max_nqs); in bnxt_get_max_func_irqs()
8826 return min_t(unsigned int, hw_resc->max_irqs, hw_resc->max_cp_rings); in bnxt_get_max_func_irqs()
8831 bp->hw_resc.max_irqs = max_irqs; in bnxt_set_max_func_irqs()
9826 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in bnxt_hwrm_if_change() local
9832 hw_resc->resv_cp_rings = 0; in bnxt_hwrm_if_change()
9833 hw_resc->resv_stat_ctxs = 0; in bnxt_hwrm_if_change()
9834 hw_resc->resv_irqs = 0; in bnxt_hwrm_if_change()
9835 hw_resc->resv_tx_rings = 0; in bnxt_hwrm_if_change()
9836 hw_resc->resv_rx_rings = 0; in bnxt_hwrm_if_change()
9837 hw_resc->resv_hw_ring_grps = 0; in bnxt_hwrm_if_change()
9838 hw_resc->resv_vnics = 0; in bnxt_hwrm_if_change()
10820 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in bnxt_can_reserve_rings() local
10825 if (hw_resc->min_tx_rings || hw_resc->resv_tx_rings) in bnxt_can_reserve_rings()
10882 if (vnics == bp->hw_resc.resv_vnics) in bnxt_rfs_capable()
10886 if (vnics <= bp->hw_resc.resv_vnics) in bnxt_rfs_capable()
12898 struct bnxt_hw_resc *hw_resc = &bp->hw_resc; in _bnxt_get_max_rings() local
12901 *max_tx = hw_resc->max_tx_rings; in _bnxt_get_max_rings()
12902 *max_rx = hw_resc->max_rx_rings; in _bnxt_get_max_rings()
12906 hw_resc->max_stat_ctxs - bnxt_get_ulp_stat_ctxs(bp)); in _bnxt_get_max_rings()
12909 max_ring_grps = hw_resc->max_hw_ring_grps; in _bnxt_get_max_rings()