Re: [PATCH net] net: stmmac: dwmac-sun8i: Honor the RX checksum offload setting
From: James Hilliard
Date: Sun Nov 15 2026 - 21:28:41 EST
On Sun, Nov 15, 2026 at 7:19 PM James Hilliard
<james.hilliard1@xxxxxxxxx> wrote:
>
> On Sun, Nov 15, 2026 at 6:03 PM <netdev-bot+sinfo@xxxxxxxxxx> wrote:
> >
> > Hi!
> >
> > This is an automated message. This series looks like a fix, but its
> > commit messages seem to be missing some information:
> >
> > - How the issue was discovered, e.g. hit in production, hit during
> > development, syzbot report, manual code inspection, LLM or static
> > analysis tool scan.
>
> This was found while investigating RX checksum offload behavior on
> H616 and reviewing the shared setup and feature-filtering paths.
>
> >
> > - Whether the issue was actually triggered, or is only theoretical
> > (e.g. found by LLM and not proven at runtime). If it was triggered
> > please include the symptoms, like the stack trace or kernel messages.
>
> The capability loss was reproduced in a source-extracted test using the
> actual GMAC, GMAC4 and XGMAC checksum callbacks with mocked MMIO and the
> relevant setup and feature-filtering logic.
I mixed up the two threads. That explanation belongs to the
separate checksum-capability fix [0].
For this sun8i patch, the issue was found and reproduced during MAC/PHY
receive testing on an Allwinner H616 board with an AC200 PHY. Even after
ethtool reported RX checksumming disabled, EMAC_RX_DO_CRC remained set
and the hardware kept dropping packets with invalid IP or transport
checksums before they reached an RX descriptor.
With the fix, disabling offload cleared that bit. In steady-state tests,
those packets then reached the host and were rejected by software
checksum validation. Valid traffic continued to work, and Ethernet FCS
rejection remained active.
[0] https://lore.kernel.org/r/20261115-submit-stmmac-rx-checksum-capability-v1-v1-1-ea26fa3689be@xxxxxxxxx/
>
> With the original code, disabling offload and following the reopen path
> clears plat->rx_coe. The feature filter then prevents offload from being
> enabled again. With the patch, the saved capability survives that
> sequence. A requested enable that fails hardware readback still clears
> the capability.
>
> >
> > - What hardware the change was tested on. For driver fixes please
> > mention the device (and if relevant firmware version) used for
> > testing, or say that the change was not tested on real hardware.
>
> Tested on an Allwinner H616 board with an AC200 PHY.
>
> >
> > Please do not repost the series just to address the above. Instead,
> > reply to this email with the missing information, so that reviewers
> > can take it into account.
> >
> > *IMPORTANT*: If you do repost (for other reasons) - please include
> > the relevant info in the cover letter or commit messages.
> > --
> > The evaluation is done by an LLM so it may be wrong, if you think
> > that is the case please reply and explain.