All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: <netdev@vger.kernel.org>
Cc: <xen-devel@lists.xen.org>, Ian Campbell <ian.campbell@citrix.com>
Subject: [PATCH 4/4] netback: correct netbk_tx_err to handle wrap around.
Date: Wed, 6 Feb 2013 17:18:18 +0000	[thread overview]
Message-ID: <1360171098-1240-4-git-send-email-ian.campbell@citrix.com> (raw)
In-Reply-To: <1360171081.32479.20.camel@zakaz.uk.xensource.com>

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Jan Beulich <JBeulich@suse.com>
---
 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 1a99288..28d5e06 100644
--- a/drivers/net/xen-netback/netback.c
+++ b/drivers/net/xen-netback/netback.c
@@ -880,7 +880,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);
-- 
1.7.2.5

      parent reply	other threads:[~2013-02-06 17:18 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-06 17:18 [PATCH 0/4] XSA-39 CVE-2013-021[67]: Linux netback DoS via malicious guest ring Ian Campbell
2013-02-06 17:18 ` [PATCH 1/4] xen/netback: shutdown the ring if it contains garbage Ian Campbell
2013-02-06 17:18 ` Ian Campbell
2013-02-06 17:18 ` [PATCH 2/4] xen/netback: don't leak pages on failure in xen_netbk_tx_check_gop Ian Campbell
2013-02-06 17:18 ` Ian Campbell
2013-02-06 17:18 ` [PATCH 3/4] xen/netback: free already allocated memory on failure in xen_netbk_get_requests Ian Campbell
2013-02-06 17:31   ` Ben Pfaff
2013-02-06 17:31   ` Ben Pfaff
2013-02-06 18:47     ` David Miller
2013-02-06 18:47     ` David Miller
2013-02-07  9:40       ` Ian Campbell
2013-02-07  9:40       ` Ian Campbell
2013-02-06 17:18 ` Ian Campbell
2013-02-06 17:18 ` [PATCH 4/4] netback: correct netbk_tx_err to handle wrap around Ian Campbell
2013-02-06 17:18 ` Ian Campbell [this message]

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=1360171098-1240-4-git-send-email-ian.campbell@citrix.com \
    --to=ian.campbell@citrix.com \
    --cc=netdev@vger.kernel.org \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.