Thread View: linux.kernel.netdev
2 messages
2 total messages
Started by Daniel Zahka
Tue, 10 Nov 2026 22:06
[PATCH net-next v2 0/6] eth: mpnic: checksum and segmentation offloads
Author: Daniel Zahka
Date: Tue, 10 Nov 2026 22:06
Date: Tue, 10 Nov 2026 22:06
69 lines
13874 bytes
13874 bytes
Add checksum and segmentation offload support. Tx checksum offload
follows the generic csum_start/csum_offset model. Rx checksum also
follows the normal unnecessary/complete model. The device can validate l4
checksums for tcp or udp, when the l3 type is one of: ipv4, ipv6,
ipv4-in-ipv6, or ipv6-in-ipv6. The full l2 checksum of a frame is always
passed to driver via a Rx completion descriptor field, which can be used
for checksum complete on other packet types.
Tx segmentation supports tcp or udp in ipv4, ipv6, 4-in-6, or 6-in-6
natively, and can support most other tunnels with GSO_PARTIAL.
Counters for CSO/LSO are exported via the netdev qstats API.
Signed-off-by: Daniel Zahka <daniel.zahka@gmail.com>
---
Changes in v2:
- eth: mpnic: Tx checksum offload
- use skb_network_offset() for the L2 header length in
mpnic_features_check(), since the mac header is not yet set when
called from the IP GSO slow path
- also enable Tx checksum offload for encapsulated packets via
hw_enc_features (moved from the IPv4 and IPv6 in IPv6 patch)
- eth: mpnic: Rx checksum offload
- convert l2_csum with cpu_to_le16() before csum_unfold(), since the
device reports it in network byte order and skb->csum was wrong on
big-endian hosts
- eth: mpnic: TCP segmentation offload
- count discarded skbs rather than segments in twq.dropped, matching
the xmit error path and the core's tx_dropped
- report only hw_gso_wire_packets; drop the super-packet counter
- eth: mpnic: UDP segmentation offload
- fall back to SW GSO for skbs shorter than MPNIC_MIN_FRAME_LEN, since
HW LSO would segment the zero padding as payload
- eth: mpnic: IPv4 and IPv6 in IPv6 tunnel segmentation
- derive inner L3 header length from csum_start rather than
inner_transport_header, which can be stale for DODGY skbs
- check the outer header is IPv6 in mpnic_ipxip6_gso_ok(), since
SKB_GSO_IPXIP6 can be set by a nested tunnel under an IPv4 outer
- move hw_enc_features setup to the Tx checksum offload patch
- eth: mpnic: add GSO_PARTIAL for other tunnels
- derive the L3 header length from csum_start rather than
inner_transport_header, matching mpnic_features_check() and
mpnic_tx_lso()
- Link to v1: https://lore.kernel.org/r/20261106-mpnic-lso-v1-0-e943ff1493e4@gmail.com
---
Daniel Zahka (6):
eth: mpnic: Tx checksum offload
eth: mpnic: Rx checksum offload
eth: mpnic: TCP segmentation offload
eth: mpnic: UDP segmentation offload
eth: mpnic: IPv4 and IPv6 in IPv6 tunnel segmentation
eth: mpnic: add GSO_PARTIAL for other tunnels
drivers/net/ethernet/meta/mpnic/mpnic_csr.h | 41 +++++
drivers/net/ethernet/meta/mpnic/mpnic_init.c | 14 ++
drivers/net/ethernet/meta/mpnic/mpnic_netdev.c | 40 +++-
drivers/net/ethernet/meta/mpnic/mpnic_netdev.h | 5 +
drivers/net/ethernet/meta/mpnic/mpnic_txrx.c | 242 ++++++++++++++++++++++++-
drivers/net/ethernet/meta/mpnic/mpnic_txrx.h | 8 +
6 files changed, 346 insertions(+), 4 deletions(-)
---
base-commit: 97ced2c090bfc2156db31fca9f52cf253e4bc186
change-id: 20261102-mpnic-lso-19aeb38e5648
Best regards,
--
Daniel Zahka <daniel.zahka@gmail.com>
Re: [PATCH net-next v2 0/6] eth: mpnic: checksum and segmentation offloads
Author: patchwork-bot+netdevbpf
Date: Fri, 13 Nov 2026 16:40
Date: Fri, 13 Nov 2026 16:40
35 lines
9437 bytes
9437 bytes
Hello:
This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Tue, 10 Nov 2026 14:06:33 -0800 you wrote:
> Add checksum and segmentation offload support. Tx checksum offload
> follows the generic csum_start/csum_offset model. Rx checksum also
> follows the normal unnecessary/complete model. The device can validate l4
> checksums for tcp or udp, when the l3 type is one of: ipv4, ipv6,
> ipv4-in-ipv6, or ipv6-in-ipv6. The full l2 checksum of a frame is always
> passed to driver via a Rx completion descriptor field, which can be used
> for checksum complete on other packet types.
>
> [...]
Here is the summary with links:
- [net-next,v2,1/6] eth: mpnic: Tx checksum offload
https://git.kernel.org/netdev/net-next/c/164fe254d1e8
- [net-next,v2,2/6] eth: mpnic: Rx checksum offload
https://git.kernel.org/netdev/net-next/c/47fcc7451a71
- [net-next,v2,3/6] eth: mpnic: TCP segmentation offload
https://git.kernel.org/netdev/net-next/c/148df1a778fc
- [net-next,v2,4/6] eth: mpnic: UDP segmentation offload
https://git.kernel.org/netdev/net-next/c/6617d7ba6ea8
- [net-next,v2,5/6] eth: mpnic: IPv4 and IPv6 in IPv6 tunnel segmentation
https://git.kernel.org/netdev/net-next/c/25284507aca0
- [net-next,v2,6/6] eth: mpnic: add GSO_PARTIAL for other tunnels
https://git.kernel.org/netdev/net-next/c/0ad78e7740d4
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads