From: Terry Loftin <terry.loftin@hp•com>
To: netdev@vger•kernel.org, e1000-devel@lists•sourceforge.net,
Jeff Kirsher <jeffrey.t.kirsher@intel•com>,
Jesse Brandeburg <jesse.brandeburg@intel•com>
Subject: [PATCH 1/1] e1000e: stop cleaning when we reach tx_ring->next_to_use
Date: Wed, 31 Mar 2010 14:01:52 -0600 [thread overview]
Message-ID: <4BB3AA30.3060906@hp.com> (raw)
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>
---
diff --git a/drivers/net/e1000e/netdev.c b/drivers/net/e1000e/netdev.c
index e1cceb6..60288e4 100644
--- a/drivers/net/e1000e/netdev.c
+++ b/drivers/net/e1000e/netdev.c
@@ -660,6 +660,8 @@ static bool e1000_clean_tx_irq(struct e1000_adapter *adapter)
i = 0;
}
+ if (i == tx_ring->next_to_use)
+ break;
eop = tx_ring->buffer_info[i].next_to_watch;
eop_desc = E1000_TX_DESC(*tx_ring, eop);
}
next reply other threads:[~2010-03-31 20:01 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-31 20:01 Terry Loftin [this message]
2010-04-02 2:33 ` [PATCH 1/1] e1000e: stop cleaning when we reach tx_ring->next_to_use David Miller
2010-04-02 4:13 ` Jeff Kirsher
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4BB3AA30.3060906@hp.com \
--to=terry.loftin@hp$(echo .)com \
--cc=e1000-devel@lists$(echo .)sourceforge.net \
--cc=jeffrey.t.kirsher@intel$(echo .)com \
--cc=jesse.brandeburg@intel$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox