[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b43ad106-9459-0ce9-0999-a6e46af36782@gmail.com>
Date: Sun, 18 Oct 2020 16:11:14 -0700
From: Florian Fainelli <f.fainelli@...il.com>
To: Vladimir Oltean <vladimir.oltean@....com>,
Heiner Kallweit <hkallweit1@...il.com>
Cc: "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"andrew@...n.ch" <andrew@...n.ch>,
"vivien.didelot@...il.com" <vivien.didelot@...il.com>,
"kuba@...nel.org" <kuba@...nel.org>,
Christian Eggers <ceggers@...i.de>,
Kurt Kanzenbach <kurt@...utronix.de>
Subject: Re: [RFC PATCH 01/13] net: dsa: add plumbing for custom netdev
statistics
On 10/18/2020 3:58 PM, Vladimir Oltean wrote:
> On Sun, Oct 18, 2020 at 04:13:28PM +0200, Heiner Kallweit wrote:
>> On a side note, because I'm also just dealing with it: this_cpu_ptr()
>> is safe only if preemption is disabled. Is this the case here? Else
>> there's get_cpu_ptr/put_cpu_ptr.
>
> lockdep would shout about using smp_processor_id() in preemptible
> context? Because it doesn't do that, and never did, but I don't really
> understand why, coming to think of it.
>
>> Also, if irq's aren't disabled there might be a need to use
>> u64_stats_update_begin_irqsave() et al. See: 2695578b896a ("net:
>> usbnet: fix potential deadlock on 32bit hosts") But I don't know dsa
>> good enough to say whether this is applicable here.
>
> DSA xmit and receive path do not run from hardirq context, just softirq,
> so I believe the issue reported to Eric there does not apply here.
How about when used as a netconsole? We do support netconsole over DSA
interfaces.
--
Florian
Powered by blists - more mailing lists