[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFwOv1SBOz6+0GxLxbK5riei83AQRJEHUTXUehSWfBq=Fg@mail.gmail.com>
Date: Wed, 17 Jan 2018 13:06:58 -0800
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: David Miller <davem@...emloft.net>
Cc: Mike Galbraith <efault@....de>,
Peter Zijlstra <peterz@...radead.org>,
Eric Dumazet <edumazet@...gle.com>,
Dmitry Safonov <dima@...sta.com>,
Frederic Weisbecker <frederic@...nel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Dmitry Safonov <0x7f454c46@...il.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Frederic Weisbecker <fweisbec@...il.com>,
Hannes Frederic Sowa <hannes@...essinduktion.org>,
Ingo Molnar <mingo@...nel.org>,
Sasha Levin <alexander.levin@...izon.com>,
Paolo Abeni <pabeni@...hat.com>,
Paul McKenney <paulmck@...ux.vnet.ibm.com>,
Radu Rendec <rrendec@...sta.com>,
Rik van Riel <riel@...hat.com>,
Stanislaw Gruszka <sgruszka@...hat.com>,
Thomas Gleixner <tglx@...utronix.de>,
Wanpeng Li <wanpeng.li@...mail.com>
Subject: Re: [RFC 1/2] softirq: Defer net rx/tx processing to ksoftirqd context
On Wed, Jan 17, 2018 at 12:30 PM, David Miller <davem@...emloft.net> wrote:
>
> I wanted to chime in about this earlier, and make it clear that it isn't
> just IRQs that can trigger softirqs. User context actions in the kernel
> can trigger softirqs too.
Yes, anybody can do that "raise_softirq()" thing, although the common
thing tends to be for it to be from an interrupt that wants to delay
more long-running things to a non-irq-dsiabled context.
It was in some way always a "poor mans interrupt thread" (with no
blocking like a real thread context, but at least not impacting actual
interrupt latency).
That said, this made me wonder a bit. I wonder how bounded the latency
is for raising a softirq from process context. We only _check_ the
softirq on the last hardirq exit, I think.
We latency was traditionally bounded by the timer irq, and non-idle
CPU's should still be running timers. But I do note that networking
does seem to have some private hacks for the latency problem (ie
net_tx_action())?
I wonder if we should run softirqs on return to user mode (and make
softirq set a thread flag if not in interrupt context).
Although maybe some people actually want the "delay until next
interrupt" kind of behavior to throttle things if they do softirqs
from process context. That sounds unlikely, but who knows.
Linus
Powered by blists - more mailing lists