diff options
author | Jonathan Cooper <jonathan.s.cooper@amd.com> | 2022-06-28 14:59:20 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-06-29 13:40:46 +0100 |
commit | 62ac3ce542fffdd71295cf8bbf6148e12efe4b4a (patch) | |
tree | 3b8e63e520d4dbc58d85b85cd8b2f6d1eb448eb9 /drivers/net/ethernet/sfc/efx.c | |
parent | 8b39db19b21b7edfa0a48ca8a00ba042353b7887 (diff) | |
download | linux-62ac3ce542fffdd71295cf8bbf6148e12efe4b4a.tar.gz linux-62ac3ce542fffdd71295cf8bbf6148e12efe4b4a.tar.bz2 linux-62ac3ce542fffdd71295cf8bbf6148e12efe4b4a.zip |
sfc: Remove netdev init from efx_init_struct
Move functionality involving the struct net_device out of
efx_init_struct so that we can initialise without a net dev
for VDPA operation.
Signed-off-by: Jonathan Cooper <jonathan.s.cooper@amd.com>
Co-developed-by: Martin Habets <habetsm.xilinx@gmail.com>
Signed-off-by: Martin Habets <habetsm.xilinx@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/sfc/efx.c')
-rw-r--r-- | drivers/net/ethernet/sfc/efx.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ethernet/sfc/efx.c b/drivers/net/ethernet/sfc/efx.c index 7f4e96a422e6..955271ff06bb 100644 --- a/drivers/net/ethernet/sfc/efx.c +++ b/drivers/net/ethernet/sfc/efx.c @@ -1056,9 +1056,10 @@ static int efx_pci_probe(struct pci_dev *pci_dev, pci_set_drvdata(pci_dev, efx); SET_NETDEV_DEV(net_dev, &pci_dev->dev); - rc = efx_init_struct(efx, pci_dev, net_dev); + rc = efx_init_struct(efx, pci_dev); if (rc) goto fail1; + efx->mdio.dev = net_dev; pci_info(pci_dev, "Solarflare NIC detected\n"); |