OSDN Git Service

net: ena: fix rare bug when failed restart/resume is followed by driver removal
authorArthur Kiyanovski <akiyano@amazon.com>
Tue, 9 Oct 2018 08:21:28 +0000 (11:21 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 9 Oct 2018 17:49:49 +0000 (10:49 -0700)
commitd7703ddbd7c9cb1ab7c08e1b85b314ff8cea38e9
tree20f93958afcfac57f143f74409dbaf671e841f9d
parentd79c3888bde6581da7ff9f9d6f581900ecb5e632
net: ena: fix rare bug when failed restart/resume is followed by driver removal

In a rare scenario when ena_device_restore() fails, followed by device
remove, an FLR will not be issued. In this case, the device will keep
sending asynchronous AENQ keep-alive events, even after driver removal,
leading to memory corruption.

Fixes: 8c5c7abdeb2d ("net: ena: add power management ops to the ENA driver")
Signed-off-by: Arthur Kiyanovski <akiyano@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/amazon/ena/ena_netdev.c