All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: netdev@vger.kernel.org
Subject: Fw: [Bug 54491] New: UFO (UDP fragmentation offload) does not work if the payload size specified is within the range ( (MTU-28)  to (MTU-8) )
Date: Tue, 26 Feb 2013 07:46:06 -0800	[thread overview]
Message-ID: <20130226074606.4d16ebfb@nehalam.linuxnetplumber.net> (raw)



Begin forwarded message:

Date: Tue, 26 Feb 2013 00:52:33 -0800
From: "bugzilla-daemon@bugzilla.kernel.org" <bugzilla-daemon@bugzilla.kernel.org>
To: "stephen@networkplumber.org" <stephen@networkplumber.org>
Subject: [Bug 54491] New: UFO (UDP fragmentation offload) does not work if the payload size specified is within the range ( (MTU-28)  to (MTU-8) )


https://bugzilla.kernel.org/show_bug.cgi?id=54491

           Summary: UFO (UDP fragmentation offload) does not work if the
                    payload size specified is within the range ( (MTU-28)
                    to (MTU-8) )
           Product: Networking
           Version: 2.5
    Kernel Version: 3.3.4
          Platform: All
        OS/Version: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: IPV4
        AssignedTo: shemminger@linux-foundation.org
        ReportedBy: hnk437@gmail.com
        Regression: No


For IPv4/UDP if the payload size specified is within the range ( (MTU-28) 
to (MTU-8) ) packet gets segmented in kernel even if the following netdev
features are set:

NETIF_F_SG 
NETIF_F_GEN_CSUM 
NETIF_F_UFO 
NETIF_F_TSO 
NETIF_F_GSO 
NETIF_F_GSO_ROBUST

Analysis:
udp_sendmsg() computes packet length by adding UDP header size to payload size:
“ulen += sizeof(struct udphdr)”
Then the function calls ip_make_skb(), however IP header size is not added to
the packet length.
ip_make_skb() in turn calls __ip_append_data(). The same packet length is used
here. 
__ip_append_data() compares the packet length with MTU. The packet length still
does not include IP header size (20 bytes).
In result, when payload size “is within the range ( (MTU-28) to (MTU-8) )”
standard branch is taken rather than ip_ufo_append_data(). Gso_size is not
computed, therefore IP fragmentation is triggered from ip_finish_output().

The issue was reproduced on 3.4.3 as well

-- 
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

             reply	other threads:[~2013-02-26 15:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-26 15:46 Stephen Hemminger [this message]
2013-02-27  3:20 ` Fw: [Bug 54491] New: UFO (UDP fragmentation offload) does not work if the payload size specified is within the range ( (MTU-28) to (MTU-8) ) Cong Wang

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=20130226074606.4d16ebfb@nehalam.linuxnetplumber.net \
    --to=stephen@networkplumber.org \
    --cc=netdev@vger.kernel.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.