Thread (3 messages) flat view 3 messages, 3 authors, 3d ago

Re: [PATCH net] net: macb: exclude software FCS from TX byte statistics

From: patchwork-bot+netdevbpf@kernel.org
Date: 2026-09-03 02:31:14
Also in: lkml

Hello:

This patch was applied to netdev/net.git (main)
by Jakub Kicinski [off-list ref]:

On Mon, 31 Aug 2026 13:31:28 +0200 you wrote:
Frames for which macb_pad_and_fcs() supplies the FCS have four FCS
bytes appended, and TX completion then accounts the grown skb->len.
tx_bytes is defined to exclude the FCS, so these frames are reported
four bytes too large.

Track only the number of FCS bytes appended in software, 0 or
ETH_FCS_LEN, and subtract that from skb->len at completion. skb->len
already reflects the padded length by then, so there is nothing else
to store. macb_pad_and_fcs() already returns 0 on every non-error
path. Return the FCS length from there instead, rather than
recomputing the same check in the caller. BQL stays on the padded
skb->len that netdev_tx_sent_queue() saw.

[...]
Here is the summary with links:
  - [net] net: macb: exclude software FCS from TX byte statistics
    https://git.kernel.org/netdev/net/c/d85f521a9afb

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help