public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: Hong Zhiguo <honkiko@gmail.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net,
	stephen@networkplumber.org, zhiguo.hong@emc.com
Subject: Re: [PATCH net-next] don't compare skb->network_header with skb->tail
Date: Sun, 10 Mar 2013 10:48:22 +0100	[thread overview]
Message-ID: <1362908902.4051.31.camel@edumazet-glaptop> (raw)
In-Reply-To: <1362906925-45308-1-git-send-email-honkiko@gmail.com>

On Sun, 2013-03-10 at 17:15 +0800, Hong Zhiguo wrote:
> in the case of NET_SKBUFF_DATA_USES_OFFSET(on 64-bit arch),
> skb->network_header is just offset over skb->head.
> 
> Signed-off-by: Hong Zhiguo <honkiko@gmail.com>
> ---
>  net/core/dev.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/net/core/dev.c b/net/core/dev.c
> index 90cee5b..378e0b9 100644
> --- a/net/core/dev.c
> +++ b/net/core/dev.c
> @@ -1705,7 +1705,7 @@ static void dev_queue_xmit_nit(struct sk_buff *skb, struct net_device *dev)
>  			skb_reset_mac_header(skb2);
>  
>  			if (skb_network_header(skb2) < skb2->data ||
> -			    skb2->network_header > skb2->tail) {
> +			    skb_network_header(skb2) > skb2->tail) {
>  				net_crit_ratelimited("protocol %04x is buggy, dev %s\n",
>  						     ntohs(skb2->protocol),
>  						     dev->name);

Sorry I dont understand this patch.

Could you elaborate ?

  reply	other threads:[~2013-03-10  9:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-10  9:15 [PATCH net-next] don't compare skb->network_header with skb->tail Hong Zhiguo
2013-03-10  9:48 ` Eric Dumazet [this message]
  -- strict thread matches above, loose matches on Subject: below --
2013-03-10  8:42 Hong Zhiguo
2013-03-10 20:52 ` David Miller

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=1362908902.4051.31.camel@edumazet-glaptop \
    --to=eric.dumazet@gmail.com \
    --cc=davem@davemloft.net \
    --cc=honkiko@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.org \
    --cc=zhiguo.hong@emc.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