From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Abeni Subject: Re: [RFC PATCH 0/2] net: threadable napi poll loop Date: Thu, 12 May 2016 22:58:34 +0200 Message-ID: <1463086714.5281.8.camel@redhat.com> References: <1462890590.23934.68.camel@edumazet-glaptop3.roam.corp.google.com> <90f3db8c-c30c-b204-576a-454939ac93ce@stressinduktion.org> <94f323a9-515e-4d75-cac8-ef0214f0499e@stressinduktion.org> <1462920697.23934.113.camel@edumazet-glaptop3.roam.corp.google.com> <20160511065527.GD3193@twins.programming.kicks-ass.net> <1463003804.23934.154.camel@edumazet-glaptop3.roam.corp.google.com> <1463083620.5281.1.camel@redhat.com> <1463086179.23934.162.camel@edumazet-glaptop3.roam.corp.google.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: Peter Zijlstra , Hannes Frederic Sowa , Eric Dumazet , netdev , "David S. Miller" , Jiri Pirko , Daniel Borkmann , Alexei Starovoitov , Alexander Duyck , Tom Herbert , Ingo Molnar , Rik van Riel , LKML , "Paul E. McKenney" To: Eric Dumazet Return-path: In-Reply-To: <1463086179.23934.162.camel@edumazet-glaptop3.roam.corp.google.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: netdev.vger.kernel.org On Thu, 2016-05-12 at 13:49 -0700, Eric Dumazet wrote: > On Thu, 2016-05-12 at 22:07 +0200, Paolo Abeni wrote: > > > > > static inline bool ksoftirqd_running(void) > > > > { > > > > return __this_cpu_read(ksoftirqd)->state == TASK_RUNNING; > > > > here something like: > > > > struct task_struct *tsk = __this_cpu_read(ksoftirqd); > > return tsk && (tsk->state == TASK_RUNNING); > > > > is needed since __this_cpu_read(ksoftirqd) can be NULL on boot. > > Indeed I've seen this but only when backporting to an older linux kernel > this morning. > > Have you got this with current linux kernel ? Yes, on net-next updated to commit c66b2581123cd1527b6a084f39e9271cb02673b7 Author: Sergei Shtylyov Date: Sat May 7 14:09:01 2016 -0700 sh_eth: reuse sh_eth_chip_reset() Cheers, Paolo