diff options
author | Edward Cree <ecree@solarflare.com> | 2020-07-27 13:04:57 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-27 12:26:56 -0700 |
commit | 4e5675bbabd69f1f30feef56f670527f3330b6df (patch) | |
tree | dca744f20de3058485278df3d54945585568c740 /drivers/net | |
parent | d802b0ae652fb8aa917205c3ad29998e0e097b61 (diff) | |
download | linux-4e5675bbabd69f1f30feef56f670527f3330b6df.tar.bz2 |
sfc_ef100: actually perform resets
In ef100_reset(), make the MCDI call to do the reset.
Also, do a reset at start-of-day during probe, to put the function in
a clean state.
Signed-off-by: Edward Cree <ecree@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ethernet/sfc/ef100_nic.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/net/ethernet/sfc/ef100_nic.c b/drivers/net/ethernet/sfc/ef100_nic.c index bb246acca574..5e6a8337a336 100644 --- a/drivers/net/ethernet/sfc/ef100_nic.c +++ b/drivers/net/ethernet/sfc/ef100_nic.c @@ -332,6 +332,10 @@ static int ef100_reset(struct efx_nic *efx, enum reset_type reset_type) __clear_bit(reset_type, &efx->reset_pending); rc = dev_open(efx->net_dev, NULL); } else if (reset_type == RESET_TYPE_ALL) { + rc = efx_mcdi_reset(efx, reset_type); + if (rc) + return rc; + netif_device_attach(efx->net_dev); rc = dev_open(efx->net_dev, NULL); @@ -466,6 +470,11 @@ static int ef100_probe_main(struct efx_nic *efx) } if (rc) goto fail; + /* Reset (most) configuration for this function */ + rc = efx_mcdi_reset(efx, RESET_TYPE_ALL); + if (rc) + goto fail; + rc = efx_ef100_init_datapath_caps(efx); if (rc < 0) goto fail; |