Re: [PATCH v5 1/4] ftrace: Implement fs notification for tracing_max_latency

From: Viktor Rosendahl
Date: Wed Sep 04 2019 - 14:17:27 EST


On 9/4/19 10:19 AM, Peter Zijlstra wrote:


Adding Paul since RCU faces similar situations, i.e. raising softirq risks
scheduler deadlock in rcu_read_unlock_special() -- but RCU's solution is to
avoid raising the softirq and instead use irq_work.

Which is right.


Thanks Joel and Peter for suggesting the irq_work facility.

I was ignorant of the existence of this facility.

It looks like it is the Holy Grail of deferred work, for this particular type of problem :)

It looks like it will be possible to both avoid deadlock and also avoid the ugly additions to the sched and idle code. In addition, the rest of the code will become a lot simpler.

best regards,

Viktor