From: "Aubrey Li" <aubreylee@gmail.com>
To: "Stephen Hemminger" <shemminger@osdl.org>,
"Herbert Xu" <herbert@gondor.apana.org.au>,
"Matt Mackall" <mpm@selenic.com>
Cc: netdev@vger.kernel.org, "Linux Kernel" <linux-kernel@vger.kernel.org>
Subject: udp checksum issue in netpoll mode.
Date: Thu, 12 Apr 2007 18:31:30 +0800 [thread overview]
Message-ID: <6d6a94c50704120331m36957148iae111ab7324c88c2@mail.gmail.com> (raw)
I think we discussed this issue before.
The current checksum function doesn't consider the kind of packet
which is padded to reach a specific minimum length. I believe that's
the problem caused my test case failed. Is this issue fixed? Or is it
acceptable if I make a patch not calculating this kind of packet?
Thanks,
-Aubrey
===============================================
static __sum16 checksum_udp(struct sk_buff *skb, struct udphdr *uh,
unsigned short ulen, __be32 saddr, __be32 daddr)
{
__wsum psum;
if (uh->check == 0 || skb->ip_summed == CHECKSUM_UNNECESSARY)
return 0;
psum = csum_tcpudp_nofold(saddr, daddr, ulen, IPPROTO_UDP, 0);
if (skb->ip_summed == CHECKSUM_COMPLETE &&
!csum_fold(csum_add(psum, skb->csum)))
return 0;
skb->csum = psum;
return __skb_checksum_complete(skb);
}
===============================================
next reply other threads:[~2007-04-12 10:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-12 10:31 Aubrey Li [this message]
2007-04-12 14:49 ` Stephen Hemminger
2007-04-16 10:02 ` Aubrey Li
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=6d6a94c50704120331m36957148iae111ab7324c88c2@mail.gmail.com \
--to=aubreylee@gmail.com \
--cc=herbert@gondor.apana.org.au \
--cc=linux-kernel@vger.kernel.org \
--cc=mpm@selenic.com \
--cc=netdev@vger.kernel.org \
--cc=shemminger@osdl.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®