From: netdev-bot+sashiko@kernel.org
To: eric.joyner@amd.com
Cc: netdev@vger.kernel.org, brett.creeley@amd.com,
andrew+netdev@lunn.ch, davem@davemloft.net, kuba@kernel.org,
pabeni@redhat.com, horms@kernel.org, vadim.fedorenko@linux.dev,
nikhil.rao@amd.com, edumazet@kernel.org
Subject: Re: [PATCH net-next v4 2/6] ionic: report FEC off as a supported link mode
Date: Tue, 17 Nov 2026 23:10:26 +0000 [thread overview]
Message-ID: <179495702693.3136.14857089621112634448@kernel.org> (raw)
In-Reply-To: <20261116-ionic-get-fec-stats-v4-2-d25cae9f1e87@amd.com>
Thank you for your contribution! Sashiko AI review found 1 potential
issue(s) to consider.
Critical: 0 · High: 0 · Medium: 1 · Low: 0
If you believe none of the issues are legitimate, please reply to each
issue of Medium severity or higher and explain why the AI is wrong.
If any of them are legitimate and you plan to respin, please let patchwork
know by including "pw-bot: cr" as a separate line at the end of your reply
(one such reply per series is enough).
- [Medium] ionic_get_link_ksettings()
(drivers/net/ethernet/pensando/ionic/ionic_ethtool.c) now sets…
--
ionic: report FEC off as a supported link mode
This patch adds FEC_NONE to the supported link modes that
ionic_get_link_ksettings() reports. It also adds FEC_NONE to the
advertised modes when the port is configured with FEC off. According to
the commit message, firmware does not report per-port FEC capabilities,
so every mode any ionic device can use is listed, and firmware rejects
the ones a given port cannot run.
> diff --git a/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c b/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c
> index 119ac720c0787..84378bef9fb8b 100644
> --- a/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c
> +++ b/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c
> @@ -298,9 +298,16 @@ static int ionic_get_link_ksettings(struct net_device *netdev,
>
> linkmode_copy(ks->link_modes.advertising, ks->link_modes.supported);
>
> + /* Firmware does not report which FEC modes a port supports, so list
> + * every mode an ionic device can use; firmware rejects a request for
> + * a mode the port cannot run.
> + */
> + ethtool_link_ksettings_add_link_mode(ks, supported, FEC_NONE);
[Severity: Medium]
Is the claim in this comment accurate? The firmware ABI in ionic_if.h
seems to define a per-port list of supported FEC types:
drivers/net/ethernet/pensando/ionic/ionic_if.h:
* @fec_type: supported fec types
...
union ionic_port_identity {
struct {
...
u8 fec_type[4];
u8 pause_type[2];
u8 loopback_mode[2];
__le32 speeds[16];
...
ionic_port_identify() in ionic_main.c already copies this structure into
ionic->ident.port with memcpy_fromio(). However, nothing in the driver
reads ident.port.fec_type[].
The commit message says AINIC firmware rejects FEC off. With this change,
ethtool on an AINIC port will show "None" as a supported FEC mode. A
request for FEC off then reaches firmware through ionic_set_fecparam():
if (fec_type != lif->ionic->idev.port_info->config.fec_type) {
mutex_lock(&lif->ionic->dev_cmd_lock);
ionic_dev_cmd_port_fec(&lif->ionic->idev, fec_type);
ret = ionic_dev_cmd_wait(lif->ionic, DEVCMD_TIMEOUT);
and the firmware error comes back to userspace.
If firmware fills identity.fec_type[], could the supported FEC set be
built from it instead of extending the hardcoded list?
If firmware does not fill it, should the comment say that the field
exists but is not populated? As written, the comment contradicts the
documented ABI.
There is also another way to tell the parts apart. The driver already
reads dev_info.asic_type in ionic_init_devinfo(), and
ionic_doorbell_wa() uses it for per-ASIC behaviour. Could asic_type be
used to leave FEC_NONE out on parts whose firmware rejects FEC off?
The later patches in this series do not appear to change this. At the
end of the series, FEC_NONE is still added to supported unconditionally,
and ident.port.fec_type[] is still never read.
> ethtool_link_ksettings_add_link_mode(ks, supported, FEC_BASER);
> ethtool_link_ksettings_add_link_mode(ks, supported, FEC_RS);
[ ... ]
--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261116-ionic-get-fec-stats-v4-0-d25cae9f1e87%40amd.com
next prev parent reply other threads:[~2026-11-17 23:10 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-16 23:06 [PATCH net-next v4 0/6] ionic: FEC reporting fixes and .get_fec_stats handler Eric Joyner
2026-11-16 23:06 ` [PATCH net-next v4 1/6] ionic: write the extra_stats invalid markers one counter at a time Eric Joyner
2026-11-16 23:06 ` [PATCH net-next v4 2/6] ionic: report FEC off as a supported link mode Eric Joyner
2026-11-17 23:10 ` netdev-bot+sashiko [this message]
2026-11-16 23:06 ` [PATCH net-next v4 3/6] ionic: report the configured FEC mode in ethtool_fecparam.fec Eric Joyner
2026-11-16 23:06 ` [PATCH net-next v4 4/6] ionic: map the FEC type through a helper in ionic_get_fecparam() Eric Joyner
2026-11-17 23:10 ` netdev-bot+sashiko
2026-11-16 23:06 ` [PATCH net-next v4 5/6] ionic: report the operational FEC mode from ethtool --show-fec Eric Joyner
2026-11-17 23:10 ` netdev-bot+sashiko
2026-11-16 23:06 ` [PATCH net-next v4 6/6] ionic: Add .get_fec_stats ethtool handler Eric Joyner
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=179495702693.3136.14857089621112634448@kernel.org \
--to=netdev-bot+sashiko@kernel.org \
--cc=andrew+netdev@lunn.ch \
--cc=brett.creeley@amd.com \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=eric.joyner@amd.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=nikhil.rao@amd.com \
--cc=pabeni@redhat.com \
--cc=vadim.fedorenko@linux.dev \
/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