e1000e: stop cleaning when we reach tx_ring->next_to_use
commitd69ac822016964c25bfbdcad165668f22d058390
authorTerry Loftin <terry.loftin@hp.com>
Fri, 9 Apr 2010 10:29:49 +0000 (9 10:29 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 26 Apr 2010 14:48:02 +0000 (26 07:48 -0700)
treef20fd80c62f01ad9a052d2c1c3e5da3aab78fbc4
parent6722260b066a1de80228d71da99ab71ebdcc7ae8
e1000e: stop cleaning when we reach tx_ring->next_to_use

commit dac876193cd79ced36d0462749ea47c05844fb49 upstream.

Tx ring buffers after tx_ring->next_to_use are volatile and could
change, possibly causing a crash.  Stop cleaning when we hit
tx_ring->next_to_use.

Signed-off-by: Terry Loftin <terry.loftin@hp.com>
Acked-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Cc: Matthew Burgess <matthew@linuxfromscratch.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/net/e1000e/netdev.c