[Intel-wired-lan] [PATCH v4] ixgbevf: handle race between close and suspend on shutdown
Bowers, AndrewX
andrewx.bowers at intel.com
Thu Dec 8 15:55:23 UTC 2016
> -----Original Message-----
> From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On
> Behalf Of Emil Tantilov
> Sent: Friday, November 11, 2016 10:13 AM
> To: intel-wired-lan at lists.osuosl.org
> Subject: [Intel-wired-lan] [PATCH v4] ixgbevf: handle race between close and
> suspend on shutdown
>
> When an interface is part of a namespace it is possible that
> ixgbevf_close() may be called while ixgbevf_suspend() is running which ends
> up in a double free WARN and/or a BUG in free_msi_irqs()
>
> To handle this situation we extend the rtnl_lock() to protect the call to
> netif_device_detach() and check for !netif_device_present() to avoid
> entering close while in suspend.
>
> Also added rtnl locks to ixgbevf_queue_reset_subtask().
>
> -v2 handle the race with netif_device_detach/present() and rtnl locks as
> suggested by Alex Duyck
>
> -v3 add rtnl locks and check in ixgbevf_remove()
>
> -v4 revert the ixgbevf_remove() changes from v3, I will submit a separate
> patch to deal with the PCIe AER issue on failed recovery
>
> CC: Alexander Duyck <alexander.h.duyck at intel.com>
> Signed-off-by: Emil Tantilov <emil.s.tantilov at intel.com>
> ---
> drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 11 +++++++++--
> 1 file changed, 9 insertions(+), 2 deletions(-)
Tested-by: Andrew Bowers <andrewx.bowers at intel.com>
More information about the Intel-wired-lan
mailing list