[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <951229905.101031.1767965900074.JavaMail.zimbra@couthit.local>
Date: Fri, 9 Jan 2026 19:08:20 +0530 (IST)
From: Parvathi Pudi <parvathi@...thit.com>
To: Paolo Abeni <pabeni@...hat.com>
Cc: Parvathi Pudi <parvathi@...thit.com>, andrew+netdev <andrew+netdev@...n.ch>,
davem <davem@...emloft.net>, edumazet <edumazet@...gle.com>,
kuba <kuba@...nel.org>, danishanwar <danishanwar@...com>,
rogerq <rogerq@...nel.org>, pmohan <pmohan@...thit.com>,
basharath <basharath@...thit.com>, afd <afd@...com>,
linux-kernel <linux-kernel@...r.kernel.org>,
netdev <netdev@...r.kernel.org>,
linux-arm-kernel <linux-arm-kernel@...ts.infradead.org>,
ALOK TIWARI <alok.a.tiwari@...cle.com>, horms <horms@...nel.org>,
pratheesh <pratheesh@...com>, j-rameshbabu <j-rameshbabu@...com>,
Vignesh Raghavendra <vigneshr@...com>, praneeth <praneeth@...com>,
srk <srk@...com>, rogerq <rogerq@...com>,
krishna <krishna@...thit.com>, mohan <mohan@...thit.com>
Subject: Re: [PATCH net-next v11 3/3] net: ti: icssm-prueth: Add support for
ICSSM RSTP switch
Hi,
> On 1/5/26 1:23 PM, Parvathi Pudi wrote:
>> +static int icssm_prueth_ndev_port_link(struct net_device *ndev,
>> + struct net_device *br_ndev)
>> +{
>> + struct prueth_emac *emac = netdev_priv(ndev);
>> + struct prueth *prueth = emac->prueth;
>> + unsigned long flags;
>> + int ret = 0;
>> +
>> + dev_dbg(prueth->dev, "%s: br_mbrs=0x%x %s\n",
>> + __func__, prueth->br_members, ndev->name);
>> +
>> + spin_lock_irqsave(&emac->addr_lock, flags);
>> +
>> + if (!prueth->br_members) {
>> + prueth->hw_bridge_dev = br_ndev;
>> + } else {
>> + /* This is adding the port to a second bridge,
>> + * this is unsupported
>> + */
>> + if (prueth->hw_bridge_dev != br_ndev) {
>> + spin_unlock_irqrestore(&emac->addr_lock, flags);
>> + return -EOPNOTSUPP;
>> + }
>> + }
>> +
>> + prueth->br_members |= BIT(emac->port_id);
>> +
>> + ret = icssm_prueth_port_offload_fwd_mark_update(prueth);
>
> More AI generated feedback here that still looks valid to me:
>
> """
> ndo_stop() can sleep (e.g., via rproc_shutdown()). This function appears
> to be called while holding a spinlock via the call chain:
>
> icssm_prueth_ndev_port_link()
> -> spin_lock_irqsave(&emac->addr_lock)
> -> icssm_prueth_port_offload_fwd_mark_update()
> -> icssm_prueth_change_mode()
> -> ndo_stop() / ndo_open()
>
> Is this intentional? The ndo_open() path also calls
> icssm_prueth_sw_init_fdb_table() which does kmalloc(GFP_KERNEL) and
> rproc_boot(), both of which may sleep.
> """
>
> There are other similar cases; for the full report see:
>
> https://netdev-ai.bots.linux.dev/ai-review.html?id=ce23f731-f25b-4082-a5d0-c1261ab829ed
>
> /P
Sure, we will review them and address the applicable changes in the next version.
Thanks and Regards,
Parvathi.
Powered by blists - more mailing lists