Re: [PATCH] rcu: Use IRQ_WORK_INIT_HARD for srcu's irq_work
Sebastian Andrzej Siewior <[email protected]>
| Newsgroups | org.kernel.vger.rcu,dev.linux.lists.linux-rt-devel |
|---|---|
| Message-ID | <[email protected]> |
On 2026-08-21 00:59:32 [+0200], Frederic Weisbecker wrote: > > Urgh. irq_work shouldn't become a widespread user ;) > > If the scheduler is up but irq_work thread is not yet created and the > > irq_work uses sleeping locks then it would create warnings. > > In testing right now I see just wake_up_klogd_work_func() which is > > always LAZY but would qualify otherwise for a warning. We wouldn't > > trigger anything yet but you get the idea. > > Fair enough! But should we warn if a non-hard IRQ work is queued before > the kthread is created? It is not a problem in general. So for instance the printk thingy is enqueued and is invoked later. The wake up can be delayed. There is no need to trigger a warning here. There is no dependency and you can't know that. The difference with SRCU+tracing is that it first starts a grace period (the irq_wake from SRCU for tracing) and then expects the grace period to be completed (tracing). Even before SRCU is up, you can queue callbacks or start grace periods, etc. This is handled once everything is up. > Thanks. > Sebastian