sfc: add ndo_set_vf_mac() function for EF10
[deliverable/linux.git] / drivers / net / ethernet / sfc / ef10_sriov.h
index 86bac7ebb01a3eff4bd380d1a35e115ce84576aa..7f12942656531615f9cabd90e4488816eafe49ab 100644 (file)
 
 /**
  * struct ef10_vf - PF's store of VF data
+ * @efx: efx_nic struct for the current VF
  * @vport_id: vport ID for the VF
  * @vport_assigned: record whether the vport is currently assigned to the VF
  * @mac: MAC address for the VF, zero when address is removed from the vport
  */
 struct ef10_vf {
+       struct efx_nic *efx;
        unsigned int vport_id;
        unsigned int vport_assigned;
        u8 mac[ETH_ALEN];
@@ -31,16 +33,15 @@ static inline bool efx_ef10_sriov_wanted(struct efx_nic *efx)
 
 int efx_ef10_sriov_configure(struct efx_nic *efx, int num_vfs);
 int efx_ef10_sriov_init(struct efx_nic *efx);
-static inline void efx_ef10_sriov_mac_address_changed(struct efx_nic *efx) {}
+static inline int efx_ef10_sriov_mac_address_changed(struct efx_nic *efx)
+{
+       return -EOPNOTSUPP;
+}
 static inline void efx_ef10_sriov_reset(struct efx_nic *efx) {}
 void efx_ef10_sriov_fini(struct efx_nic *efx);
 static inline void efx_ef10_sriov_flr(struct efx_nic *efx, unsigned vf_i) {}
 
-static inline int efx_ef10_sriov_set_vf_mac(struct efx_nic *efx, int vf,
-                                           u8 *mac)
-{
-       return -EOPNOTSUPP;
-}
+int efx_ef10_sriov_set_vf_mac(struct efx_nic *efx, int vf, u8 *mac);
 
 static inline int efx_ef10_sriov_set_vf_vlan(struct efx_nic *efx, int vf,
                                             u16 vlan, u8 qos)
This page took 0.043658 seconds and 5 git commands to generate.