Lines Matching refs:pf
85 struct i40e_pf *pf = vsi->back; in i40e_notify_client_of_vf_msg() local
86 struct i40e_client_instance *cdev = pf->cinst; in i40e_notify_client_of_vf_msg()
91 dev_dbg(&pf->pdev->dev, in i40e_notify_client_of_vf_msg()
96 dev_dbg(&pf->pdev->dev, "Client is not open, abort virtchnl_receive\n"); in i40e_notify_client_of_vf_msg()
111 struct i40e_pf *pf = vsi->back; in i40e_notify_client_of_l2_param_changes() local
112 struct i40e_client_instance *cdev = pf->cinst; in i40e_notify_client_of_l2_param_changes()
147 struct i40e_pf *pf = ldev->pf; in i40e_client_release_qvlist() local
155 wr32(&pf->hw, reg_idx, I40E_PFINT_LNKLSTN_FIRSTQ_INDX_MASK); in i40e_client_release_qvlist()
170 struct i40e_pf *pf = vsi->back; in i40e_notify_client_of_netdev_close() local
171 struct i40e_client_instance *cdev = pf->cinst; in i40e_notify_client_of_netdev_close()
181 dev_dbg(&pf->pdev->dev, "Client is not open, abort close\n"); in i40e_notify_client_of_netdev_close()
196 void i40e_notify_client_of_vf_reset(struct i40e_pf *pf, u32 vf_id) in i40e_notify_client_of_vf_reset() argument
198 struct i40e_client_instance *cdev = pf->cinst; in i40e_notify_client_of_vf_reset()
203 dev_dbg(&pf->pdev->dev, in i40e_notify_client_of_vf_reset()
208 dev_dbg(&pf->pdev->dev, "Client is not open, abort vf-reset\n"); in i40e_notify_client_of_vf_reset()
221 void i40e_notify_client_of_vf_enable(struct i40e_pf *pf, u32 num_vfs) in i40e_notify_client_of_vf_enable() argument
223 struct i40e_client_instance *cdev = pf->cinst; in i40e_notify_client_of_vf_enable()
228 dev_dbg(&pf->pdev->dev, in i40e_notify_client_of_vf_enable()
234 dev_dbg(&pf->pdev->dev, "Client is not open, abort vf-enable\n"); in i40e_notify_client_of_vf_enable()
248 int i40e_vf_client_capable(struct i40e_pf *pf, u32 vf_id) in i40e_vf_client_capable() argument
250 struct i40e_client_instance *cdev = pf->cinst; in i40e_vf_client_capable()
256 dev_dbg(&pf->pdev->dev, in i40e_vf_client_capable()
270 void i40e_client_update_msix_info(struct i40e_pf *pf) in i40e_client_update_msix_info() argument
272 struct i40e_client_instance *cdev = pf->cinst; in i40e_client_update_msix_info()
277 cdev->lan_info.msix_count = pf->num_iwarp_msix; in i40e_client_update_msix_info()
278 cdev->lan_info.msix_entries = &pf->msix_entries[pf->iwarp_base_vector]; in i40e_client_update_msix_info()
337 static void i40e_client_add_instance(struct i40e_pf *pf) in i40e_client_add_instance() argument
341 struct i40e_vsi *vsi = pf->vsi[pf->lan_vsi]; in i40e_client_add_instance()
347 cdev->lan_info.pf = (void *)pf; in i40e_client_add_instance()
349 cdev->lan_info.pcidev = pf->pdev; in i40e_client_add_instance()
350 cdev->lan_info.fid = pf->hw.pf_id; in i40e_client_add_instance()
352 cdev->lan_info.hw_addr = pf->hw.hw_addr; in i40e_client_add_instance()
357 cdev->lan_info.fw_maj_ver = pf->hw.aq.fw_maj_ver; in i40e_client_add_instance()
358 cdev->lan_info.fw_min_ver = pf->hw.aq.fw_min_ver; in i40e_client_add_instance()
359 cdev->lan_info.fw_build = pf->hw.aq.fw_build; in i40e_client_add_instance()
370 dev_err(&pf->pdev->dev, "MAC address list is empty!\n"); in i40e_client_add_instance()
372 pf->cinst = cdev; in i40e_client_add_instance()
374 cdev->lan_info.msix_count = pf->num_iwarp_msix; in i40e_client_add_instance()
375 cdev->lan_info.msix_entries = &pf->msix_entries[pf->iwarp_base_vector]; in i40e_client_add_instance()
384 pf->cinst = NULL; in i40e_client_add_instance()
393 void i40e_client_del_instance(struct i40e_pf *pf) in i40e_client_del_instance() argument
395 kfree(pf->cinst); in i40e_client_del_instance()
396 pf->cinst = NULL; in i40e_client_del_instance()
403 void i40e_client_subtask(struct i40e_pf *pf) in i40e_client_subtask() argument
407 struct i40e_vsi *vsi = pf->vsi[pf->lan_vsi]; in i40e_client_subtask()
410 if (!test_and_clear_bit(__I40E_CLIENT_SERVICE_REQUESTED, pf->state)) in i40e_client_subtask()
412 cdev = pf->cinst; in i40e_client_subtask()
415 if (test_bit(__I40E_DOWN, pf->state) || in i40e_client_subtask()
416 test_bit(__I40E_CONFIG_BUSY, pf->state)) in i40e_client_subtask()
460 int i40e_lan_add_device(struct i40e_pf *pf) in i40e_lan_add_device() argument
467 if (ldev->pf == pf) { in i40e_lan_add_device()
477 ldev->pf = pf; in i40e_lan_add_device()
480 dev_info(&pf->pdev->dev, "Added LAN device PF%d bus=0x%02x dev=0x%02x func=0x%02x\n", in i40e_lan_add_device()
481 pf->hw.pf_id, pf->hw.bus.bus_id, in i40e_lan_add_device()
482 pf->hw.bus.device, pf->hw.bus.func); in i40e_lan_add_device()
484 i40e_client_add_instance(pf); in i40e_lan_add_device()
486 set_bit(__I40E_CLIENT_SERVICE_REQUESTED, pf->state); in i40e_lan_add_device()
487 i40e_service_event_schedule(pf); in i40e_lan_add_device()
500 int i40e_lan_del_device(struct i40e_pf *pf) in i40e_lan_del_device() argument
502 struct auxiliary_device *aux_dev = pf->cinst->lan_info.aux_dev; in i40e_lan_del_device()
510 i40e_client_del_instance(pf); in i40e_lan_del_device()
514 if (ldev->pf == pf) { in i40e_lan_del_device()
515 dev_info(&pf->pdev->dev, "Deleted LAN device PF%d bus=0x%02x dev=0x%02x func=0x%02x\n", in i40e_lan_del_device()
516 pf->hw.pf_id, pf->hw.bus.bus_id, in i40e_lan_del_device()
517 pf->hw.bus.device, pf->hw.bus.func); in i40e_lan_del_device()
542 struct i40e_pf *pf = ldev->pf; in i40e_client_virtchnl_send() local
543 struct i40e_hw *hw = &pf->hw; in i40e_client_virtchnl_send()
549 dev_err(&pf->pdev->dev, "Unable to send iWarp message to VF, error %d, aq status %d\n", in i40e_client_virtchnl_send()
567 struct i40e_pf *pf = ldev->pf; in i40e_client_setup_qvlist() local
568 struct i40e_hw *hw = &pf->hw; in i40e_client_setup_qvlist()
585 if ((v_idx >= (pf->iwarp_base_vector + pf->num_iwarp_msix)) || in i40e_client_setup_qvlist()
586 (v_idx < pf->iwarp_base_vector)) in i40e_client_setup_qvlist()
638 struct i40e_pf *pf = ldev->pf; in i40e_client_request_reset() local
642 set_bit(__I40E_PF_RESET_REQUESTED, pf->state); in i40e_client_request_reset()
645 set_bit(__I40E_PF_RESET_REQUESTED, pf->state); in i40e_client_request_reset()
648 dev_warn(&pf->pdev->dev, in i40e_client_request_reset()
650 pf->hw.pf_id, reset_level); in i40e_client_request_reset()
654 i40e_service_event_schedule(pf); in i40e_client_request_reset()
673 struct i40e_pf *pf = ldev->pf; in i40e_client_update_vsi_ctxt() local
674 struct i40e_vsi *vsi = pf->vsi[pf->lan_vsi]; in i40e_client_update_vsi_ctxt()
683 ctxt.seid = pf->main_vsi_seid; in i40e_client_update_vsi_ctxt()
684 ctxt.pf_num = pf->hw.pf_id; in i40e_client_update_vsi_ctxt()
685 err = i40e_aq_get_vsi_params(&pf->hw, &ctxt, NULL); in i40e_client_update_vsi_ctxt()
688 dev_info(&pf->pdev->dev, in i40e_client_update_vsi_ctxt()
690 i40e_stat_str(&pf->hw, err), in i40e_client_update_vsi_ctxt()
691 i40e_aq_str(&pf->hw, in i40e_client_update_vsi_ctxt()
692 pf->hw.aq.asq_last_status)); in i40e_client_update_vsi_ctxt()
708 dev_warn(&pf->pdev->dev, in i40e_client_update_vsi_ctxt()
710 pf->hw.pf_id, flag); in i40e_client_update_vsi_ctxt()
716 dev_info(&pf->pdev->dev, in i40e_client_update_vsi_ctxt()
718 i40e_stat_str(&pf->hw, err), in i40e_client_update_vsi_ctxt()
719 i40e_aq_str(&pf->hw, in i40e_client_update_vsi_ctxt()
720 pf->hw.aq.asq_last_status)); in i40e_client_update_vsi_ctxt()
728 struct i40e_pf *pf = ldev->pf; in i40e_client_device_register() local
730 pf->cinst->client = client; in i40e_client_device_register()
731 set_bit(__I40E_CLIENT_SERVICE_REQUESTED, pf->state); in i40e_client_device_register()
732 i40e_service_event_schedule(pf); in i40e_client_device_register()
738 struct i40e_pf *pf = ldev->pf; in i40e_client_device_unregister() local
739 struct i40e_client_instance *cdev = pf->cinst; in i40e_client_device_unregister()
744 while (test_and_set_bit(__I40E_SERVICE_SCHED, pf->state)) in i40e_client_device_unregister()
753 pf->cinst->client = NULL; in i40e_client_device_unregister()
754 clear_bit(__I40E_SERVICE_SCHED, pf->state); in i40e_client_device_unregister()