Re: [PATCH 1/6] sched/fair: Use guard(rcu) for sched_domain RCU sections

K Prateek Nayak
2026-04-28T11:05:14Z

Hello Andrea,

On 4/28/2026 4:13 PM, Andrea Righi wrote:
>>> - rcu_read_lock();
>>> + guard(rcu)();
>>
>> and since this is only called from:
>>
>> sched_tick() /* IRQs disabled */
>> sched_balance_trigger()
>> nohz_balancer_kick()
>>
>> with IRQs disabled, we can get rid of that rcu_read_lock() entirely.
>
> Yeah, all makes sense. I'll update the patch dropping rcu_read_lock/unlock()
> completely.
>
> Is it worth adding a lockdep_assert_irqs_disabled()?

Yes, that would be nice. Thank you!

--
Thanks and Regards,
Prateek