Re: [PATCH net v2] net/mlx5e: strip runt Ethernet padding in HW-GRO (SHAMPO)
From: Tariq Toukan
Date: Tue Aug 04 2026 - 03:27:52 EST
On 04/08/2026 0:44, Glenn Judd wrote:
When hardware GRO (SHAMPO) coalesces a small IPv4/TCP segmentHi,
that was padded up to the 60-byte minimum Ethernet frame, the trailing
padding is folded into the merged payload.
The selftest tools/testing/selftests/drivers/net/hw/gro.py subtest
hw_ipv4_data_lrg_1byte sends {100, 1} expecting to receive {101}.
In current code, it receives {106} (100 + 1 payload + 5 pad) instead.
Fix is to compute the real (unpadded) frame length from the segment's
IPv4 total (padded) length and drop the padding before it is merged.
Fixes: 92552d3abd32 ("net/mlx5e: HW_GRO cqe handler implementation")
Cc: stable@xxxxxxxxxxxxxxx
Assisted-by: Claude:claude-opus-4-8
Assisted-by: Codex:gpt-5.6
Assisted-by: Meta:internal-AI-tooling
Signed-off-by: Glenn Judd <gmj@xxxxxxxx>
---
Notes:
v2:
- No functional change.
- Address the netdev checkpatch 80-column warning.
- Add a comment noting the IPv4 header offset intentionally mirrors the
driver's existing no-IP-options logic (raised in review).
Changing that logic is outside the scope of this change.
v1: https://lore.kernel.org/netdev/20260731185442.2778723-1-gmj@xxxxxxxx/
Please note that I posted comments on v1, ~1h before your v2.