On 2025-11-02 14:49:43 [-0800], Paul E. McKenney wrote:
> --- a/kernel/rcu/refscale.c
> +++ b/kernel/rcu/refscale.c
> @@ -636,6 +636,37 @@ static const struct ref_scale_ops jiffies_ops = {
>       .name           = "jiffies"
>  };
>  
> +static void ref_bh_section(const int nloops)
> +{
> +     int i;
> +
> +     preempt_disable();
> +     for (i = nloops; i >= 0; i--) {
> +             local_bh_disable();

This (preempt off followed by bh off) may cause warnings. That would be
bh is disabled on the CPU, it gets preempted by _this_ which disables
first preemption and then bh. 
I hid the code under CONFIG_PREEMPT_RT_NEEDS_BH_LOCK so it shouldn't be
a problem in the long term I think. So just if you see a warning here
under RT you know why :)

> +             local_bh_enable();
> +     }
> +     preempt_enable();
> +}

Sebastian

Reply via email to