public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Jonas Gorski <jonas.gorski@gmail.com>
To: Alok Tiwari <alok.a.tiwari@oracle.com>,
	tchornyi@marvell.com, vmytnyk@marvell.com,
	yevhen.orlov@plvision.eu, vkochan@marvell.com,
	taras.chornyi@plvision.eu, pabeni@redhat.com, kuba@kernel.org,
	edumazet@google.com, davem@davemloft.net, andrew+netdev@lunn.ch,
	netdev@vger.kernel.org
Cc: alok.a.tiwarilinux@gmail.com
Subject: Re: [PATCH net-next] net: marvell: prestera: fix FEC error message for SFP ports
Date: Mon, 2 Feb 2026 11:26:00 +0100	[thread overview]
Message-ID: <795c3351-d65b-4a9a-83dc-b530177b9d28@gmail.com> (raw)
In-Reply-To: <20260202052816.28191-1-alok.a.tiwari@oracle.com>

Hi,

On 02/02/2026 06:28, Alok Tiwari wrote:
> In prestera_ethtool_set_fecparam(), the error message is opposite of
> the condition checking PRESTERA_PORT_TCVR_SFP. FEC configuration is
> not allowed on SFP ports, but the message says "non-SFP ports", which
> does not match the condition.
> 
> Fix the message to match the condition.
> 
> Signed-off-by: Alok Tiwari <alok.a.tiwari@oracle.com>
> ---
>  drivers/net/ethernet/marvell/prestera/prestera_ethtool.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/marvell/prestera/prestera_ethtool.c b/drivers/net/ethernet/marvell/prestera/prestera_ethtool.c
> index 2f52daba58e6..a259da9f30f4 100644
> --- a/drivers/net/ethernet/marvell/prestera/prestera_ethtool.c
> +++ b/drivers/net/ethernet/marvell/prestera/prestera_ethtool.c
> @@ -718,7 +718,7 @@ static int prestera_ethtool_set_fecparam(struct net_device *dev,
>  	}
>  
>  	if (port->caps.transceiver == PRESTERA_PORT_TCVR_SFP) {
> -		netdev_err(dev, "FEC set is not allowed on non-SFP ports\n");
> +		netdev_err(dev, "FEC set is not allowed on SFP ports\n");
>  		return -EINVAL;
>  	}
>  

I'm pretty sure that the condition here is wrong, not the error message.

AFAIK it doesn't make sense to configure FEC on ethernet/copper ports,
but for SFP ports, it may be required depending on the transceiver or
cable used, especially for fiber modules.

I may be wrong though.

This check was introduced with bb5dbf2cc64d ("net: marvell: prestera:
add firmware v4.0 support"), but that commit does not offer any
explanation for it in the commit message.

Best regards,
Jonas

  parent reply	other threads:[~2026-02-02 10:26 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-02  5:28 [PATCH net-next] net: marvell: prestera: fix FEC error message for SFP ports Alok Tiwari
2026-02-02  9:47 ` [EXTERNAL] " Elad Nachman
2026-02-02 10:26 ` Jonas Gorski [this message]
2026-02-04  3:15   ` Jakub Kicinski
2026-02-04 13:13     ` [EXTERNAL] " Elad Nachman
2026-02-05  2:27       ` Jakub Kicinski
2026-02-05  3:16         ` ALOK TIWARI

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=795c3351-d65b-4a9a-83dc-b530177b9d28@gmail.com \
    --to=jonas.gorski@gmail.com \
    --cc=alok.a.tiwari@oracle.com \
    --cc=alok.a.tiwarilinux@gmail.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=taras.chornyi@plvision.eu \
    --cc=tchornyi@marvell.com \
    --cc=vkochan@marvell.com \
    --cc=vmytnyk@marvell.com \
    --cc=yevhen.orlov@plvision.eu \
    /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