• Home
  • Raw
  • Download

Lines Matching refs:mbox

50 	mutex_lock(&pfvf->mbox.lock);  in otx2_update_lmac_stats()
51 req = otx2_mbox_alloc_msg_cgx_stats(&pfvf->mbox); in otx2_update_lmac_stats()
53 mutex_unlock(&pfvf->mbox.lock); in otx2_update_lmac_stats()
57 otx2_sync_mbox_msg(&pfvf->mbox); in otx2_update_lmac_stats()
58 mutex_unlock(&pfvf->mbox.lock); in otx2_update_lmac_stats()
67 mutex_lock(&pfvf->mbox.lock); in otx2_update_lmac_fec_stats()
68 req = otx2_mbox_alloc_msg_cgx_fec_stats(&pfvf->mbox); in otx2_update_lmac_fec_stats()
70 otx2_sync_mbox_msg(&pfvf->mbox); in otx2_update_lmac_fec_stats()
71 mutex_unlock(&pfvf->mbox.lock); in otx2_update_lmac_fec_stats()
150 mutex_lock(&pfvf->mbox.lock); in otx2_hw_set_mac_addr()
151 req = otx2_mbox_alloc_msg_nix_set_mac_addr(&pfvf->mbox); in otx2_hw_set_mac_addr()
153 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_set_mac_addr()
159 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_hw_set_mac_addr()
160 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_set_mac_addr()
172 mutex_lock(&pfvf->mbox.lock); in otx2_hw_get_mac_addr()
173 req = otx2_mbox_alloc_msg_nix_get_mac_addr(&pfvf->mbox); in otx2_hw_get_mac_addr()
175 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_get_mac_addr()
179 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_hw_get_mac_addr()
181 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_get_mac_addr()
185 msghdr = otx2_mbox_get_rsp(&pfvf->mbox.mbox, 0, &req->hdr); in otx2_hw_get_mac_addr()
187 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_get_mac_addr()
192 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_get_mac_addr()
227 mutex_lock(&pfvf->mbox.lock); in otx2_hw_set_mtu()
228 req = otx2_mbox_alloc_msg_nix_set_hw_frs(&pfvf->mbox); in otx2_hw_set_mtu()
230 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_set_mtu()
236 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_hw_set_mtu()
237 mutex_unlock(&pfvf->mbox.lock); in otx2_hw_set_mtu()
249 mutex_lock(&pfvf->mbox.lock); in otx2_config_pause_frm()
250 req = otx2_mbox_alloc_msg_cgx_cfg_pause_frm(&pfvf->mbox); in otx2_config_pause_frm()
260 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_config_pause_frm()
262 mutex_unlock(&pfvf->mbox.lock); in otx2_config_pause_frm()
274 mutex_lock(&pfvf->mbox.lock); in otx2_set_flowkey_cfg()
275 req = otx2_mbox_alloc_msg_nix_rss_flowkey_cfg(&pfvf->mbox); in otx2_set_flowkey_cfg()
277 mutex_unlock(&pfvf->mbox.lock); in otx2_set_flowkey_cfg()
284 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_set_flowkey_cfg()
289 otx2_mbox_get_rsp(&pfvf->mbox.mbox, 0, &req->hdr); in otx2_set_flowkey_cfg()
297 mutex_unlock(&pfvf->mbox.lock); in otx2_set_flowkey_cfg()
305 struct mbox *mbox = &pfvf->mbox; in otx2_set_rss_table() local
310 mutex_lock(&mbox->lock); in otx2_set_rss_table()
314 aq = otx2_mbox_alloc_msg_nix_aq_enq(mbox); in otx2_set_rss_table()
319 err = otx2_sync_mbox_msg(mbox); in otx2_set_rss_table()
321 mutex_unlock(&mbox->lock); in otx2_set_rss_table()
324 aq = otx2_mbox_alloc_msg_nix_aq_enq(mbox); in otx2_set_rss_table()
326 mutex_unlock(&mbox->lock); in otx2_set_rss_table()
338 err = otx2_sync_mbox_msg(mbox); in otx2_set_rss_table()
339 mutex_unlock(&mbox->lock); in otx2_set_rss_table()
452 mutex_lock(&pfvf->mbox.lock); in otx2_setup_segmentation()
455 lso = otx2_mbox_alloc_msg_nix_lso_format_cfg(&pfvf->mbox); in otx2_setup_segmentation()
462 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_setup_segmentation()
467 otx2_mbox_get_rsp(&pfvf->mbox.mbox, 0, &lso->hdr); in otx2_setup_segmentation()
474 lso = otx2_mbox_alloc_msg_nix_lso_format_cfg(&pfvf->mbox); in otx2_setup_segmentation()
481 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_setup_segmentation()
486 otx2_mbox_get_rsp(&pfvf->mbox.mbox, 0, &lso->hdr); in otx2_setup_segmentation()
491 mutex_unlock(&pfvf->mbox.lock); in otx2_setup_segmentation()
494 mutex_unlock(&pfvf->mbox.lock); in otx2_setup_segmentation()
596 req = otx2_mbox_alloc_msg_nix_txschq_cfg(&pfvf->mbox); in otx2_txschq_config()
677 return otx2_sync_mbox_msg(&pfvf->mbox); in otx2_txschq_config()
686 req = otx2_mbox_alloc_msg_nix_txsch_alloc(&pfvf->mbox); in otx2_txsch_alloc()
694 return otx2_sync_mbox_msg(&pfvf->mbox); in otx2_txsch_alloc()
702 mutex_lock(&pfvf->mbox.lock); in otx2_txschq_stop()
704 free_req = otx2_mbox_alloc_msg_nix_txsch_free(&pfvf->mbox); in otx2_txschq_stop()
706 mutex_unlock(&pfvf->mbox.lock); in otx2_txschq_stop()
711 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_txschq_stop()
712 mutex_unlock(&pfvf->mbox.lock); in otx2_txschq_stop()
765 aq = otx2_mbox_alloc_msg_nix_aq_enq(&pfvf->mbox); in otx2_rq_init()
789 return otx2_sync_mbox_msg(&pfvf->mbox); in otx2_rq_init()
801 aq = otx2_mbox_alloc_msg_nix_aq_enq(&pfvf->mbox); in otx2_sq_aq_init()
827 return otx2_sync_mbox_msg(&pfvf->mbox); in otx2_sq_aq_init()
925 aq = otx2_mbox_alloc_msg_nix_aq_enq(&pfvf->mbox); in otx2_cq_init()
957 return otx2_sync_mbox_msg(&pfvf->mbox); in otx2_cq_init()
1053 nixlf = otx2_mbox_alloc_msg_nix_lf_alloc(&pfvf->mbox); in otx2_config_nix()
1074 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_config_nix()
1078 rsp = (struct nix_lf_alloc_rsp *)otx2_mbox_get_rsp(&pfvf->mbox.mbox, 0, in otx2_config_nix()
1184 aq = otx2_mbox_alloc_msg_npa_aq_enq(&pfvf->mbox); in otx2_aura_init()
1187 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_aura_init()
1190 aq = otx2_mbox_alloc_msg_npa_aq_enq(&pfvf->mbox); in otx2_aura_init()
1255 aq = otx2_mbox_alloc_msg_npa_aq_enq(&pfvf->mbox); in otx2_pool_init()
1258 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_pool_init()
1263 aq = otx2_mbox_alloc_msg_npa_aq_enq(&pfvf->mbox); in otx2_pool_init()
1324 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_sq_aura_pool_init()
1354 otx2_mbox_reset(&pfvf->mbox.mbox, 0); in otx2_sq_aura_pool_init()
1387 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_rq_aura_pool_init()
1404 otx2_mbox_reset(&pfvf->mbox.mbox, 0); in otx2_rq_aura_pool_init()
1429 npalf = otx2_mbox_alloc_msg_npa_lf_alloc(&pfvf->mbox); in otx2_config_npa()
1438 return otx2_sync_mbox_msg(&pfvf->mbox); in otx2_config_npa()
1441 int otx2_detach_resources(struct mbox *mbox) in otx2_detach_resources() argument
1445 mutex_lock(&mbox->lock); in otx2_detach_resources()
1446 detach = otx2_mbox_alloc_msg_detach_resources(mbox); in otx2_detach_resources()
1448 mutex_unlock(&mbox->lock); in otx2_detach_resources()
1456 otx2_mbox_msg_send(&mbox->mbox, 0); in otx2_detach_resources()
1457 mutex_unlock(&mbox->lock); in otx2_detach_resources()
1468 mutex_lock(&pfvf->mbox.lock); in otx2_attach_npa_nix()
1470 attach = otx2_mbox_alloc_msg_attach_resources(&pfvf->mbox); in otx2_attach_npa_nix()
1472 mutex_unlock(&pfvf->mbox.lock); in otx2_attach_npa_nix()
1480 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_attach_npa_nix()
1482 mutex_unlock(&pfvf->mbox.lock); in otx2_attach_npa_nix()
1495 msix = otx2_mbox_alloc_msg_msix_offset(&pfvf->mbox); in otx2_attach_npa_nix()
1497 mutex_unlock(&pfvf->mbox.lock); in otx2_attach_npa_nix()
1501 err = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_attach_npa_nix()
1503 mutex_unlock(&pfvf->mbox.lock); in otx2_attach_npa_nix()
1506 mutex_unlock(&pfvf->mbox.lock); in otx2_attach_npa_nix()
1519 void otx2_ctx_disable(struct mbox *mbox, int type, bool npa) in otx2_ctx_disable() argument
1523 mutex_lock(&mbox->lock); in otx2_ctx_disable()
1526 req = otx2_mbox_alloc_msg_npa_hwctx_disable(mbox); in otx2_ctx_disable()
1528 req = otx2_mbox_alloc_msg_nix_hwctx_disable(mbox); in otx2_ctx_disable()
1531 mutex_unlock(&mbox->lock); in otx2_ctx_disable()
1537 if (otx2_sync_mbox_msg(mbox)) in otx2_ctx_disable()
1538 dev_err(mbox->pfvf->dev, "%s failed to disable context\n", in otx2_ctx_disable()
1541 mutex_unlock(&mbox->lock); in otx2_ctx_disable()
1549 req = otx2_mbox_alloc_msg_nix_bp_enable(&pfvf->mbox); in otx2_nix_config_bp()
1551 req = otx2_mbox_alloc_msg_nix_bp_disable(&pfvf->mbox); in otx2_nix_config_bp()
1560 return otx2_sync_mbox_msg(&pfvf->mbox); in otx2_nix_config_bp()
1687 mutex_lock(&pfvf->mbox.lock); in otx2_get_max_mtu()
1689 req = otx2_mbox_alloc_msg_nix_get_hw_info(&pfvf->mbox); in otx2_get_max_mtu()
1695 rc = otx2_sync_mbox_msg(&pfvf->mbox); in otx2_get_max_mtu()
1698 otx2_mbox_get_rsp(&pfvf->mbox.mbox, 0, &req->hdr); in otx2_get_max_mtu()
1715 mutex_unlock(&pfvf->mbox.lock); in otx2_get_max_mtu()