summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/pensando/ionic/ionic_lif.c
diff options
context:
space:
mode:
authorShannon Nelson <snelson@pensando.io>2020-03-06 17:04:01 -0800
committerDavid S. Miller <davem@davemloft.net>2020-03-09 19:34:03 -0700
commit30a1e6d0f8e26069b45a16d92dc739764cd857bc (patch)
tree006b51fd24d75f60228953fc5d1123923b0c54a3 /drivers/net/ethernet/pensando/ionic/ionic_lif.c
parentc8e98343bf5c322026324d6ef9d8ac891ad19dc4 (diff)
ionic: keep ionic dev on lif init fail
If the basic ionic interface works but the lif creation fails, don't fail the probe. This will allow us to use the driver to help inspect the hw/fw/pci interface for debugging purposes. Signed-off-by: Shannon Nelson <snelson@pensando.io> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/pensando/ionic/ionic_lif.c')
-rw-r--r--drivers/net/ethernet/pensando/ionic/ionic_lif.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/pensando/ionic/ionic_lif.c b/drivers/net/ethernet/pensando/ionic/ionic_lif.c
index 191271f6260d..1b7e18fe83db 100644
--- a/drivers/net/ethernet/pensando/ionic/ionic_lif.c
+++ b/drivers/net/ethernet/pensando/ionic/ionic_lif.c
@@ -2408,6 +2408,9 @@ void ionic_lifs_unregister(struct ionic *ionic)
* current model, so don't bother searching the
* ionic->lif for candidates to unregister
*/
+ if (!ionic->master_lif)
+ return;
+
cancel_work_sync(&ionic->master_lif->deferred.work);
cancel_work_sync(&ionic->master_lif->tx_timeout_work);
if (ionic->master_lif->netdev->reg_state == NETREG_REGISTERED)