Lines Matching refs:iov_data

155 	struct fm10k_iov_data *iov_data;  in fm10k_iov_event()  local
160 if (!READ_ONCE(interface->iov_data)) in fm10k_iov_event()
165 iov_data = interface->iov_data; in fm10k_iov_event()
168 if (!iov_data) in fm10k_iov_event()
179 i = iov_data->num_vfs; in fm10k_iov_event()
182 struct fm10k_vf_info *vf_info = &iov_data->vf_info[i]; in fm10k_iov_event()
200 struct fm10k_iov_data *iov_data; in fm10k_iov_mbx() local
204 if (!READ_ONCE(interface->iov_data)) in fm10k_iov_mbx()
209 iov_data = interface->iov_data; in fm10k_iov_mbx()
212 if (!iov_data) in fm10k_iov_mbx()
226 for (i = iov_data->next_vf_mbx ? : iov_data->num_vfs; i--;) { in fm10k_iov_mbx()
227 struct fm10k_vf_info *vf_info = &iov_data->vf_info[i]; in fm10k_iov_mbx()
267 iov_data->next_vf_mbx = i + 1; in fm10k_iov_mbx()
268 } else if (iov_data->next_vf_mbx) { in fm10k_iov_mbx()
269 iov_data->next_vf_mbx = 0; in fm10k_iov_mbx()
285 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_iov_suspend() local
290 num_vfs = iov_data ? iov_data->num_vfs : 0; in fm10k_iov_suspend()
298 struct fm10k_vf_info *vf_info = &iov_data->vf_info[i]; in fm10k_iov_suspend()
329 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_iov_resume() local
335 num_vfs = iov_data ? iov_data->num_vfs : 0; in fm10k_iov_resume()
338 if (!iov_data) in fm10k_iov_resume()
363 struct fm10k_vf_info *vf_info = &iov_data->vf_info[i]; in fm10k_iov_resume()
385 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_iov_update_pvid() local
391 if (!iov_data) in fm10k_iov_update_pvid()
395 if (vf_idx >= iov_data->num_vfs) in fm10k_iov_update_pvid()
399 vf_info = &iov_data->vf_info[vf_idx]; in fm10k_iov_update_pvid()
412 if (!interface->iov_data) in fm10k_iov_free_data()
419 kfree_rcu(interface->iov_data, rcu); in fm10k_iov_free_data()
420 interface->iov_data = NULL; in fm10k_iov_free_data()
426 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_iov_alloc_data() local
432 if (iov_data) in fm10k_iov_alloc_data()
445 iov_data = kzalloc(size, GFP_KERNEL); in fm10k_iov_alloc_data()
446 if (!iov_data) in fm10k_iov_alloc_data()
450 iov_data->num_vfs = num_vfs; in fm10k_iov_alloc_data()
454 struct fm10k_vf_info *vf_info = &iov_data->vf_info[i]; in fm10k_iov_alloc_data()
466 kfree(iov_data); in fm10k_iov_alloc_data()
472 interface->iov_data = iov_data; in fm10k_iov_alloc_data()
533 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_iov_update_stats() local
537 if (!iov_data) in fm10k_iov_update_stats()
540 for (i = 0; i < iov_data->num_vfs; i++) in fm10k_iov_update_stats()
541 hw->iov.ops.update_stats(hw, iov_data->vf_info[i].stats, i); in fm10k_iov_update_stats()
570 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_ndo_set_vf_mac() local
574 if (!iov_data || vf_idx >= iov_data->num_vfs) in fm10k_ndo_set_vf_mac()
582 vf_info = &iov_data->vf_info[vf_idx]; in fm10k_ndo_set_vf_mac()
594 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_ndo_set_vf_vlan() local
599 if (!iov_data || vf_idx >= iov_data->num_vfs) in fm10k_ndo_set_vf_vlan()
610 vf_info = &iov_data->vf_info[vf_idx]; in fm10k_ndo_set_vf_vlan()
631 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_ndo_set_vf_bw() local
635 if (!iov_data || vf_idx >= iov_data->num_vfs) in fm10k_ndo_set_vf_bw()
644 iov_data->vf_info[vf_idx].rate = max_rate; in fm10k_ndo_set_vf_bw()
656 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_ndo_get_vf_config() local
660 if (!iov_data || vf_idx >= iov_data->num_vfs) in fm10k_ndo_get_vf_config()
663 vf_info = &iov_data->vf_info[vf_idx]; in fm10k_ndo_get_vf_config()
679 struct fm10k_iov_data *iov_data = interface->iov_data; in fm10k_ndo_get_vf_stats() local
685 if (!iov_data || vf_idx >= iov_data->num_vfs) in fm10k_ndo_get_vf_stats()
689 hw_stats = iov_data->vf_info[vf_idx].stats; in fm10k_ndo_get_vf_stats()