* [PATCH net-next] bareudp: Enable BIG TCP packets
@ 2026-10-01 4:23 Haishuang Yan
2026-10-02 9:00 ` Alice Mikityanska
0 siblings, 1 reply; 2+ messages in thread
From: Haishuang Yan @ 2026-10-01 4:23 UTC (permalink / raw)
To: netdev
Cc: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Alice Mikityanska, Daniel Borkmann, linux-kernel,
Haishuang Yan
Commit f3d0f753f066 ("vxlan: Enable BIG TCP packets") and commit
03ebe91b0f61 ("geneve: Enable BIG TCP packets") allowed BIG TCP on vxlan
and geneve, after the preceding patches of that series made the common
UDP tunnel transmit path handle GSO packets larger than 64KB.
bareudp transmits through the same helpers, udp_tunnel_handle_offloads()
followed by udp_tunnel_xmit_skb() or udp_tunnel6_xmit_skb(), and does
not fill in any length field itself. Bump tso_max_size up to
GSO_MAX_SIZE so that the admin can use BIG TCP with bareudp too.
The default gso_max_size and gso_ipv4_max_size stay at 64KB, so nothing
changes unless they are raised explicitly.
iperf3 TCP over bareudp (ethertype ipv4, IPv4 outer) between two netns
connected by veth, MTU 1600 on veth, 3 runs of 20 seconds each. This
was measured in a QEMU TCG guest, so only the relative numbers are
meaningful:
gso_max_size/gso_ipv4_max_size 65536:
4380.6, 4404.2, 4354.5 Mbit/s, average 4379.8 Mbit/s
gso_max_size/gso_ipv4_max_size 196608:
5509.4, 5454.7, 5497.4 Mbit/s, average 5487.2 Mbit/s (+25%)
With 196608, about 90k to 100k packets larger than 64KB were
transmitted on the bareudp device per run, none with 65536. Without
this patch, setting gso_max_size to 196608 is rejected.
Assisted-by: LLM
Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com>
---
drivers/net/bareudp.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/bareudp.c b/drivers/net/bareudp.c
index c3b5ed52d877..fcc33e302b9c 100644
--- a/drivers/net/bareudp.c
+++ b/drivers/net/bareudp.c
@@ -589,6 +589,7 @@ static void bareudp_setup(struct net_device *dev)
dev->max_mtu = IP_MAX_MTU - BAREUDP_BASE_HLEN;
dev->type = ARPHRD_NONE;
netif_keep_dst(dev);
+ netif_set_tso_max_size(dev, GSO_MAX_SIZE);
dev->priv_flags |= IFF_NO_QUEUE;
dev->lltx = true;
dev->flags = IFF_POINTOPOINT | IFF_NOARP | IFF_MULTICAST;
--
2.43.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH net-next] bareudp: Enable BIG TCP packets
2026-10-01 4:23 [PATCH net-next] bareudp: Enable BIG TCP packets Haishuang Yan
@ 2026-10-02 9:00 ` Alice Mikityanska
0 siblings, 0 replies; 2+ messages in thread
From: Alice Mikityanska @ 2026-10-02 9:00 UTC (permalink / raw)
To: Haishuang Yan, netdev
Cc: Andrew Lunn, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Daniel Borkmann, linux-kernel
On Thu, Oct 1, 2026, at 07:23, Haishuang Yan wrote:
> Commit f3d0f753f066 ("vxlan: Enable BIG TCP packets") and commit
> 03ebe91b0f61 ("geneve: Enable BIG TCP packets") allowed BIG TCP on vxlan
> and geneve, after the preceding patches of that series made the common
> UDP tunnel transmit path handle GSO packets larger than 64KB.
>
> bareudp transmits through the same helpers, udp_tunnel_handle_offloads()
> followed by udp_tunnel_xmit_skb() or udp_tunnel6_xmit_skb(), and does
> not fill in any length field itself. Bump tso_max_size up to
> GSO_MAX_SIZE so that the admin can use BIG TCP with bareudp too.
>
> The default gso_max_size and gso_ipv4_max_size stay at 64KB, so nothing
> changes unless they are raised explicitly.
>
> iperf3 TCP over bareudp (ethertype ipv4, IPv4 outer) between two netns
> connected by veth, MTU 1600 on veth, 3 runs of 20 seconds each. This
> was measured in a QEMU TCG guest, so only the relative numbers are
> meaningful:
>
> gso_max_size/gso_ipv4_max_size 65536:
> 4380.6, 4404.2, 4354.5 Mbit/s, average 4379.8 Mbit/s
>
> gso_max_size/gso_ipv4_max_size 196608:
> 5509.4, 5454.7, 5497.4 Mbit/s, average 5487.2 Mbit/s (+25%)
>
> With 196608, about 90k to 100k packets larger than 64KB were
> transmitted on the bareudp device per run, none with 65536. Without
> this patch, setting gso_max_size to 196608 is rejected.
>
> Assisted-by: LLM
> Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com>
> ---
> drivers/net/bareudp.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/net/bareudp.c b/drivers/net/bareudp.c
> index c3b5ed52d877..fcc33e302b9c 100644
> --- a/drivers/net/bareudp.c
> +++ b/drivers/net/bareudp.c
> @@ -589,6 +589,7 @@ static void bareudp_setup(struct net_device *dev)
> dev->max_mtu = IP_MAX_MTU - BAREUDP_BASE_HLEN;
> dev->type = ARPHRD_NONE;
> netif_keep_dst(dev);
> + netif_set_tso_max_size(dev, GSO_MAX_SIZE);
Acked-by: Alice Mikityanska <alice.kernel@fastmail.im>
Do you mind extending the big_tcp_tunnels.sh selftest to cover bareudp?
Besides, enabling BIG TCP with fou would also be a one-liner, the
basement was added in "udp: Support BIG TCP GSO packets where they
can occur":
https://lore.kernel.org/netdev/20260710134242.216538-4-alice.kernel@fastmail.im
> dev->priv_flags |= IFF_NO_QUEUE;
> dev->lltx = true;
> dev->flags = IFF_POINTOPOINT | IFF_NOARP | IFF_MULTICAST;
> --
> 2.43.0
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-10-02 9:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-01 4:23 [PATCH net-next] bareudp: Enable BIG TCP packets Haishuang Yan
2026-10-02 9:00 ` Alice Mikityanska
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®