xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: jeremy@goop.org
Cc: Steven.Smith@eu.citrix.com, xen-devel@lists.xensource.com,
	Ian Campbell <ian.campbell@citrix.com>,
	JBeulich@novell.com
Subject: [PATCH 2/4] xen: netback: handle NET_SKBUFF_DATA_USES_OFFSET correctly
Date: Fri, 11 Jun 2010 15:19:09 +0100	[thread overview]
Message-ID: <1276265951-24490-2-git-send-email-ian.campbell@citrix.com> (raw)
In-Reply-To: <1276265928.19091.3469.camel@zakaz.uk.xensource.com>

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Cc: Jan Beulich <JBeulich@novell.com>
---
 drivers/xen/netback/netback.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/drivers/xen/netback/netback.c b/drivers/xen/netback/netback.c
index 9e4793f..8cd7875 100644
--- a/drivers/xen/netback/netback.c
+++ b/drivers/xen/netback/netback.c
@@ -218,7 +218,11 @@ static struct sk_buff *netbk_copy_skb(struct sk_buff *skb)
 		len -= copy;
 	}
 
+#ifdef NET_SKBUFF_DATA_USES_OFFSET
+	offset = 0;
+#else
 	offset = nskb->data - skb->data;
+#endif
 
 	nskb->transport_header = skb->transport_header + offset;
 	nskb->network_header = skb->network_header + offset;
-- 
1.5.6.5

  parent reply	other threads:[~2010-06-11 14:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-11 14:18 [GIT 0/4] netback patches from XCP patch queue Ian Campbell
2010-06-11 14:19 ` [PATCH 1/4] xen: netback: Fixes for delayed copy of tx network packets Ian Campbell
2010-06-11 14:19 ` Ian Campbell [this message]
2010-06-11 14:19 ` [PATCH 3/4] xen: netback: drop frag member from struct netbk_rx_meta Ian Campbell
2010-06-11 14:19 ` [PATCH 4/4] xen/netback: linearise SKBs as we copy them into guest memory on guest-RX Ian Campbell

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=1276265951-24490-2-git-send-email-ian.campbell@citrix.com \
    --to=ian.campbell@citrix.com \
    --cc=JBeulich@novell.com \
    --cc=Steven.Smith@eu.citrix.com \
    --cc=jeremy@goop.org \
    --cc=xen-devel@lists.xensource.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).