Add -G flag to enable UDP segment offload in Linux.#61
Merged
bluhm merged 14 commits intobluhm:masterfrom May 24, 2025
Merged
Conversation
Collaborator
Author
|
The new commit also does UDP segment offload for sendmmsg(2). |
Collaborator
Author
|
There are still some problems with |
Collaborator
Author
|
Changing |
Collaborator
Author
|
Here is a link to the initial GSO patch: https://lwn.net/ml/netdev/20180417200059.30154-6-willemdebruijn.kernel@gmail.com/ |
Owner
|
Could you please rebase it and provide man page and test in Linux GNUmakefile. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The patch below can enable GRO on Linux (https://lwn.net/Articles/768995/, https://lwn.net/ml/netdev/a8112a7fbbfc39d5b59e5ace0d3c1409824f9261.1539957909.git.pabeni@redhat.com/).
I noticed that it only needs a sockopt and that udpbench does not
need many additional changes to cope with the changes in receive
behavior.
GRO:
NO GRO:
Currently the bitrate calculation is hacky with GRO, it takes the
total received payload and divides it by the rcvlen to get the
number of packets.
By using the UDP_GRO cmsg_type one supposedly could get back the
individual packet size and then divide for each msg in mmsg:
if(cmsg->cmsg_level == SOL_UDP && cmsg->cmsg_type == UDP_GRO) { ...However, I cannot get it to work. Below is my attempted diff for
that: