[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20260131015438.972436-1-kuba@kernel.org>
Date: Fri, 30 Jan 2026 17:54:37 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: lukasz.majewski@...lbox.org
Cc: Jakub Kicinski <kuba@...nel.org>,
devicetree@...r.kernel.org,
horms@...nel.org,
krzk+dt@...nel.org,
s.hauer@...gutronix.de,
netdev@...r.kernel.org,
linux-kernel@...r.kernel.org,
kernel@...gutronix.de,
richardcochran@...il.com,
shawnguo@...nel.org,
edumazet@...gle.com,
linux-arm-kernel@...ts.infradead.org,
andrew+netdev@...n.ch,
pabeni@...hat.com,
wahrenst@....net,
davem@...emloft.net,
festevam@...il.com,
conor+dt@...nel.org,
imx@...ts.linux.dev,
andrew@...n.ch,
robh@...nel.org
Subject: Re: [net-next,v21,6/7] net: mtip: Extend the L2 switch driver with management operations
This is an AI-generated review of your patch. The human sending this
email has considered the AI review valid, or at least plausible.
For local reproduction steps see https://netdev-ai.bots.linux.dev/ai-local.html
---
net: mtip: Extend the L2 switch driver with management operations
This patch adds management functions for the L2 switch including VLAN
configuration, port learning/blocking, multicast/broadcast control,
and forced forwarding for port separation.
> diff --git a/drivers/net/ethernet/freescale/mtipsw/mtipl2sw_mgnt.c b/drivers/net/ethernet/freescale/mtipsw/mtipl2sw_mgnt.c
> --- /dev/null
> +++ b/drivers/net/ethernet/freescale/mtipsw/mtipl2sw_mgnt.c
[ ... ]
> +int mtip_vlan_input_process(struct switch_enet_private *fep,
> + int port, int mode, unsigned short port_vlanid,
> + int vlan_verify_en, int vlan_domain_num,
> + int vlan_domain_port)
> +{
> + /* Only modes from 1 to 4 are valid*/
> + if (mode < 0 || mode > 4) {
^^^^
The comment says modes 1-4 are valid, but the condition allows mode 0
to pass through. Should the check be "mode < 1" instead, or is the
comment incorrect and mode 0 is actually valid?
> + dev_err(&fep->pdev->dev,
> + "%s: VLAN input processing mode (%d) not supported\n",
> + __func__, mode);
> + return -EINVAL;
> + }
[ ... ]
Powered by blists - more mailing lists