diff options
author | Ian Campbell <Ian.Campbell@citrix.com> | 2013-02-06 23:41:38 +0000 |
---|---|---|
committer | Ben Hutchings <ben@decadent.org.uk> | 2013-02-20 03:15:37 +0000 |
commit | adecb7c418057a934b327c1177d738e17f0cf98a (patch) | |
tree | ba49150d4e4ed302835806b044d6127a32c2bf44 | |
parent | 79d2fa0811ed0dadeb745daa0067eb672ec12fb7 (diff) | |
download | lwn-adecb7c418057a934b327c1177d738e17f0cf98a.tar.gz lwn-adecb7c418057a934b327c1177d738e17f0cf98a.zip |
netback: correct netbk_tx_err to handle wrap around.
[ Upstream commit b9149729ebdcfce63f853aa54a404c6a8f6ebbf3 ]
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Jan Beulich <JBeulich@suse.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
-rw-r--r-- | drivers/net/xen-netback/netback.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/xen-netback/netback.c b/drivers/net/xen-netback/netback.c index a14b3a2a2f1d..b802bb31213c 100644 --- a/drivers/net/xen-netback/netback.c +++ b/drivers/net/xen-netback/netback.c @@ -852,7 +852,7 @@ static void netbk_tx_err(struct xenvif *vif, do { make_tx_response(vif, txp, XEN_NETIF_RSP_ERROR); - if (cons >= end) + if (cons == end) break; txp = RING_GET_REQUEST(&vif->tx, cons++); } while (1); |