Lines Matching refs:hctx

240 	struct bnxt_qplib_ctx *hctx;  in bnxt_re_limit_pf_res()  local
244 hctx = rdev->qplib_res.hctx; in bnxt_re_limit_pf_res()
249 hctx->qp_ctx.max = min_t(u32, dev_res.max_qp, attr->max_qp); in bnxt_re_limit_pf_res()
250 hctx->mrw_ctx.max = min_t(u32, dev_res.max_mr, attr->max_mr); in bnxt_re_limit_pf_res()
254 hctx->mrw_ctx.max *= 2; in bnxt_re_limit_pf_res()
255 hctx->srq_ctx.max = min_t(u32, dev_res.max_srq, attr->max_srq); in bnxt_re_limit_pf_res()
256 hctx->cq_ctx.max = min_t(u32, dev_res.max_cq, attr->max_cq); in bnxt_re_limit_pf_res()
258 hctx->tqm_ctx.qcount[i] = attr->tqm_alloc_reqs[i]; in bnxt_re_limit_pf_res()
260 hctx->qp_ctx.max = attr->max_qp ? attr->max_qp : dev_res.max_qp; in bnxt_re_limit_pf_res()
261 hctx->mrw_ctx.max = attr->max_mr ? attr->max_mr : dev_res.max_mr; in bnxt_re_limit_pf_res()
262 hctx->srq_ctx.max = attr->max_srq ? attr->max_srq : dev_res.max_srq; in bnxt_re_limit_pf_res()
263 hctx->cq_ctx.max = attr->max_cq ? attr->max_cq : dev_res.max_cq; in bnxt_re_limit_pf_res()
288 struct bnxt_qplib_ctx *hctx; in bnxt_re_set_resource_limits() local
290 hctx = rdev->qplib_res.hctx; in bnxt_re_set_resource_limits()
291 memset(&hctx->vf_res, 0, sizeof(struct bnxt_qplib_vf_res)); in bnxt_re_set_resource_limits()
295 bnxt_re_limit_vf_res(rdev, &hctx->vf_res, rdev->num_vfs); in bnxt_re_set_resource_limits()
1479 kfree(res->hctx); in bnxt_re_destroy_chip_ctx()
1487 res->hctx = NULL; in bnxt_re_destroy_chip_ctx()
1522 rdev->qplib_res.hctx = kzalloc(sizeof(*rdev->qplib_res.hctx), in bnxt_re_setup_chip_ctx()
1524 if (!rdev->qplib_res.hctx) { in bnxt_re_setup_chip_ctx()
1548 kfree(rdev->qplib_res.hctx); in bnxt_re_setup_chip_ctx()
1549 rdev->qplib_res.hctx = NULL; in bnxt_re_setup_chip_ctx()
1686 struct bnxt_qplib_ctx *hctx; in bnxt_re_net_stats_ctx_alloc() local
1690 hctx = rdev->qplib_res.hctx; in bnxt_re_net_stats_ctx_alloc()
1691 stat = (tid == 0xffff) ? &hctx->stats : &hctx->stats2; in bnxt_re_net_stats_ctx_alloc()
3020 struct bnxt_qplib_ctx *hctx; in bnxt_re_put_stats_ctx() local
3025 hctx = res->hctx; in bnxt_re_put_stats_ctx()
3028 bnxt_re_net_stats_ctx_free(rdev, hctx->stats.fw_id, tid); in bnxt_re_put_stats_ctx()
3029 bnxt_qplib_free_stat_mem(res, &hctx->stats); in bnxt_re_put_stats_ctx()
3040 struct bnxt_qplib_ctx *hctx; in bnxt_re_get_stats_ctx() local
3046 hctx = res->hctx; in bnxt_re_get_stats_ctx()
3048 rc = bnxt_qplib_alloc_stat_mem(res->pdev, rdev->chip_ctx, &hctx->stats); in bnxt_re_get_stats_ctx()
3059 bnxt_qplib_free_stat_mem(res, &hctx->stats); in bnxt_re_get_stats_ctx()