Commit a257e97
sched_ext: Fix possible deadlock in the deferred_irq_workfn()
For PREEMPT_RT=y kernels, the deferred_irq_workfn() is executed in
the per-cpu irq_work/* task context and not disable-irq, if the rq
returned by container_of() is current CPU's rq, the following scenarios
may occur:
lock(&rq->__lock);
<Interrupt>
lock(&rq->__lock);
This commit use IRQ_WORK_INIT_HARD() to replace init_irq_work() to
initialize rq->scx.deferred_irq_work, make the deferred_irq_workfn()
is always invoked in hard-irq context.
Signed-off-by: Zqiang <[email protected]>
Signed-off-by: Tejun Heo <[email protected]>1 parent c87488a commit a257e97
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5321 | 5321 | | |
5322 | 5322 | | |
5323 | 5323 | | |
5324 | | - | |
| 5324 | + | |
5325 | 5325 | | |
5326 | 5326 | | |
5327 | 5327 | | |
| |||
0 commit comments