[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAAEAJfCYH5SnhiPyJCeBTquj8roUnt3AxQ2rWwugo=tN+EUZTA@mail.gmail.com>
Date: Wed, 30 Mar 2016 01:59:13 -0300
From: Ezequiel Garcia <ezequiel@...guardiasur.com.ar>
To: David Miller <davem@...emloft.net>
Cc: Thomas Petazzoni <thomas.petazzoni@...e-electrons.com>,
netdev@...r.kernel.org
Subject: Re: [PATCH] ethernet: mvneta: Support netpoll
Hi David,
On 30 March 2016 at 00:09, David Miller <davem@...emloft.net> wrote:
> From: Ezequiel Garcia <ezequiel@...guardiasur.com.ar>
> Date: Mon, 28 Mar 2016 17:41:18 -0300
>
>> +/* Polled functionality used by netconsole and others in non interrupt mode */
>> +static void mvneta_poll_controller(struct net_device *dev)
>> +{
>> + struct mvneta_port *pp = netdev_priv(dev);
>> +
>> + on_each_cpu(mvneta_percpu_poll_controller, pp, false);
>> +}
>
> This doesn't work.
>
> netpoll may be invoked from any context whatsoever, even hardware
> interrupt handlers or contexts where cpu interrupts are disabled.
>
> smp_call_function() and thus on_each_cpu() may not be called with
> disabled interrupts or from a hardware interrupt handler or from
> a bottom half handler, all of which are valid situations where
> netpoll may occur since printk's can occur anywhere.
Well, I hated the idea of using on_each_cpu here, but wasn't sure
if there was a real reason that forbid it.
Thanks a lot for the feedback.
--
Ezequiel GarcĂa, VanguardiaSur
www.vanguardiasur.com.ar
Powered by blists - more mailing lists