Lines Matching refs:nic_data

22 	struct efx_ef10_nic_data *nic_data = efx->nic_data;  in efx_ef10_evb_port_assign()  local
26 EVB_PORT_ASSIGN_IN_PF, nic_data->pf_index, in efx_ef10_evb_port_assign()
118 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_free_vf_vports() local
121 if (!nic_data->vf) in efx_ef10_sriov_free_vf_vports()
125 struct ef10_vf *vf = nic_data->vf + i; in efx_ef10_sriov_free_vf_vports()
153 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_free_vf_vswitching() local
156 kfree(nic_data->vf); in efx_ef10_sriov_free_vf_vswitching()
157 nic_data->vf = NULL; in efx_ef10_sriov_free_vf_vswitching()
163 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_assign_vf_vport() local
164 struct ef10_vf *vf = nic_data->vf + vf_i; in efx_ef10_sriov_assign_vf_vport()
167 if (WARN_ON_ONCE(!nic_data->vf)) in efx_ef10_sriov_assign_vf_vport()
192 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_alloc_vf_vswitching() local
196 nic_data->vf = kcalloc(efx->vf_count, sizeof(struct ef10_vf), in efx_ef10_sriov_alloc_vf_vswitching()
198 if (!nic_data->vf) in efx_ef10_sriov_alloc_vf_vswitching()
202 eth_random_addr(nic_data->vf[i].mac); in efx_ef10_sriov_alloc_vf_vswitching()
203 nic_data->vf[i].efx = NULL; in efx_ef10_sriov_alloc_vf_vswitching()
204 nic_data->vf[i].vlan = EFX_EF10_NO_VLAN; in efx_ef10_sriov_alloc_vf_vswitching()
214 kfree(nic_data->vf); in efx_ef10_sriov_alloc_vf_vswitching()
215 nic_data->vf = NULL; in efx_ef10_sriov_alloc_vf_vswitching()
238 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_vadaptor_alloc_set_features() local
242 rc = efx_ef10_vadaptor_alloc(efx, nic_data->vport_id); in efx_ef10_vadaptor_alloc_set_features()
246 rc = efx_ef10_vadaptor_query(efx, nic_data->vport_id, in efx_ef10_vadaptor_alloc_set_features()
270 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_vswitching_probe_pf() local
287 EFX_EF10_NO_VLAN, &nic_data->vport_id); in efx_ef10_vswitching_probe_pf()
291 rc = efx_ef10_vport_add_mac(efx, nic_data->vport_id, net_dev->dev_addr); in efx_ef10_vswitching_probe_pf()
294 ether_addr_copy(nic_data->vport_mac, net_dev->dev_addr); in efx_ef10_vswitching_probe_pf()
302 efx_ef10_vport_del_mac(efx, nic_data->vport_id, nic_data->vport_mac); in efx_ef10_vswitching_probe_pf()
303 eth_zero_addr(nic_data->vport_mac); in efx_ef10_vswitching_probe_pf()
305 efx_ef10_vport_free(efx, nic_data->vport_id); in efx_ef10_vswitching_probe_pf()
306 nic_data->vport_id = EVB_PORT_ID_ASSIGNED; in efx_ef10_vswitching_probe_pf()
320 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_vswitching_restore_pf() local
323 if (!nic_data->must_probe_vswitching) in efx_ef10_vswitching_restore_pf()
334 nic_data->must_probe_vswitching = false; in efx_ef10_vswitching_restore_pf()
341 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_vswitching_restore_vf() local
344 if (!nic_data->must_probe_vswitching) in efx_ef10_vswitching_restore_vf()
351 nic_data->must_probe_vswitching = false; in efx_ef10_vswitching_restore_vf()
357 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_vswitching_remove_pf() local
361 efx_ef10_vadaptor_free(efx, nic_data->vport_id); in efx_ef10_vswitching_remove_pf()
363 if (nic_data->vport_id == EVB_PORT_ID_ASSIGNED) in efx_ef10_vswitching_remove_pf()
366 if (!is_zero_ether_addr(nic_data->vport_mac)) { in efx_ef10_vswitching_remove_pf()
367 efx_ef10_vport_del_mac(efx, nic_data->vport_id, in efx_ef10_vswitching_remove_pf()
369 eth_zero_addr(nic_data->vport_mac); in efx_ef10_vswitching_remove_pf()
371 efx_ef10_vport_free(efx, nic_data->vport_id); in efx_ef10_vswitching_remove_pf()
372 nic_data->vport_id = EVB_PORT_ID_ASSIGNED; in efx_ef10_vswitching_remove_pf()
376 efx_ef10_vswitch_free(efx, nic_data->vport_id); in efx_ef10_vswitching_remove_pf()
445 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_fini() local
449 if (!nic_data->vf) { in efx_ef10_sriov_fini()
458 struct efx_nic *vf_efx = nic_data->vf[i].efx; in efx_ef10_sriov_fini()
491 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_set_vf_mac() local
495 if (!nic_data->vf) in efx_ef10_sriov_set_vf_mac()
500 vf = nic_data->vf + vf_i; in efx_ef10_sriov_set_vf_mac()
565 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_set_vf_vlan() local
575 vf = nic_data->vf + vf_i; in efx_ef10_sriov_set_vf_vlan()
702 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_set_vf_link_state() local
712 nic_data->pf_index, in efx_ef10_sriov_set_vf_link_state()
725 struct efx_ef10_nic_data *nic_data = efx->nic_data; in efx_ef10_sriov_get_vf_config() local
733 if (!nic_data->vf) in efx_ef10_sriov_get_vf_config()
736 vf = nic_data->vf + vf_i; in efx_ef10_sriov_get_vf_config()
747 nic_data->pf_index, in efx_ef10_sriov_get_vf_config()