mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: netdev-bot+sashiko@kernel.org
To: mmyangfl@gmail.com
Cc: netdev@vger.kernel.org, andrew@lunn.ch, olteanv@gmail.com,
	davem@davemloft.net, edumazet@kernel.org, kuba@kernel.org,
	pabeni@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next 2/4] net: dsa: motorcomm: Fix RMON fragments stat
Date: Sun, 08 Nov 2026 14:22:27 +0000	[thread overview]
Message-ID: <179414774787.994134.16499462160004455221@kernel.org> (raw)
In-Reply-To: <20261107132040.1066996-3-mmyangfl@gmail.com>

Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.

Low priority / nit picks for your consideration:

- [Low] This commit fixes a statistics bug that users can see, but it has
  no Fixes: tag.

--

net: dsa: motorcomm: Fix RMON fragments stat

This commit changes yt921x_dsa_get_rmon_stats() so that the RMON
etherStatsFragments counter is read from rx_fragment_errors, not
rx_alignment_errors. The alignment error counter is already exported as
AlignmentErrors and rx_frame_errors.

> etherStatsFragments counts frames with a bad FCS due to fragmentation;
> report the dedicated RX fragment error counter instead of the alignment
> error one, which is already exported as AlignmentErrors and
> rx_frame_errors.
>
> Signed-off-by: David Yang <mmyangfl@gmail.com>

[Severity: Low]
Should this have a Fixes: tag? The wrong mapping looks like it goes back
to the commit that first added the driver.

In that commit, yt921x_dsa_get_rmon_stats() in drivers/net/dsa/yt921x.c
already had:

	rmon_stats->fragments = mib->rx_alignment_errors;

Since then the line has only been moved by "net: dsa: motorcomm: Split
MIB module" and converted to u64_stats_t. Neither change touched the
mapping.

Without the tag, stable kernels that contain the original driver will
keep reporting alignment errors as fragments in the ethtool RMON stats
for YT921x ports. Would something like this work?

Fixes: 186623f4aa72 ("net: dsa: yt921x: Add support for Motorcomm YT921x")

Older trees will probably need a hand-adjusted backport. Before the move
to motorcomm/, the code is in drivers/net/dsa/yt921x.c and uses plain u64
fields, not u64_stats_t.

-- 
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261107132040.1066996-1-mmyangfl%40gmail.com

  reply	other threads:[~2026-11-08 14:22 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-07 13:20 [PATCH net-next 0/4] net: dsa: motorcomm: MIB fixup David Yang
2026-11-07 13:20 ` [PATCH net-next 1/4] net: dsa: motorcomm: Fix stats64 error counter mapping David Yang
2026-11-08 14:22   ` netdev-bot+sashiko
2026-11-07 13:20 ` [PATCH net-next 2/4] net: dsa: motorcomm: Fix RMON fragments stat David Yang
2026-11-08 14:22   ` netdev-bot+sashiko [this message]
2026-11-07 13:20 ` [PATCH net-next 3/4] net: dsa: motorcomm: Use safe 64-bit counter reader David Yang
2026-11-08 14:22   ` netdev-bot+sashiko
2026-11-07 13:20 ` [PATCH net-next 4/4] net: dsa: motorcomm: Prevent rx_bytes/tx_bytes underflow David Yang
2026-11-08 14:22   ` netdev-bot+sashiko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=179414774787.994134.16499462160004455221@kernel.org \
    --to=netdev-bot+sashiko@kernel.org \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mmyangfl@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=pabeni@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®