Re: [PATCH] sky2: Lock transmit queue while disabling device
From: David Miller <davem@davemloft.net>
Date: 2010-01-07 04:26:53
From: David Miller <davem@davemloft.net>
Date: 2010-01-07 04:26:53
From: Mike McCormack <redacted> Date: Thu, 31 Dec 2009 19:55:31 +0900
netif_device_detach() does not take the tx_lock, so it's possible that a call to sky2_xmit_frame is still in progress after netif_device_detach() is complete. Take netif_tx_lock() to make sure all transmits have stopped while we're disabling the devices and that no other CPU is still transmitting a frame after we've disabling the device. Proposed fix for "sky2 panic under load" reported by Berck E. Nash. Signed-off-by: Mike McCormack <redacted>
Applied to net-next-2.6 Stephen has asked for some further refinements, once that is all sorted we can think about backporting this to net-2.6 and -stable if necessary. Thanks.