qede: make driver reliable on unload after failures
authorIgor Russkikh <irusskikh@marvell.com>
Sun, 23 Aug 2020 11:19:34 +0000 (14:19 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 25 Aug 2020 01:01:33 +0000 (18:01 -0700)
commitadc100d0988841c56dc5caebc3abec3871985b3a
treeda9fe17aef47514c3715b1bfe55b54a9b22bf52a
parentc5c642c55e2fd43fcf42262fd1e87271d413fb42
qede: make driver reliable on unload after failures

In case recovery was not successful, netdev still should be
present. But we should clear cdev if something bad happens
on recovery.

We also check cdev for null on dev close. That could be a case
if recovery was not successful.

Signed-off-by: Igor Russkikh <irusskikh@marvell.com>
Signed-off-by: Alexander Lobakin <alobakin@marvell.com>
Signed-off-by: Michal Kalderon <michal.kalderon@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qede/qede_main.c