• Paul E. McKenney's avatar
    rcu: Make Tiny RCU explicitly disable preemption · 11b8b378
    Paul E. McKenney authored
    Because Tiny RCU is used only in kernels built with either
    CONFIG_PREEMPT_NONE=y or CONFIG_PREEMPT_VOLUNTARY=y, there has not been
    any need for TINY RCU to explicitly disable preemption.  However, the
    prospect of lazy preemption changes that, and preemption means that
    the non-atomic increment in synchronize_rcu() can be preempted, with
    the possibility that one of the increments is lost.  This could cause
    failures for users of the APIs that poll RCU grace periods.
    
    This commit therefore adds the needed preempt_disable() and
    preempt_enable() call to Tiny RCU.
    Signed-off-by: default avatarPaul E. McKenney <paulmck@kernel.org>
    Cc: Ankur Arora <ankur.a.arora@oracle.com>
    Cc: Thomas Gleixner <tglx@linutronix.de>
    Signed-off-by: default avatarUladzislau Rezki (Sony) <urezki@gmail.com>
    11b8b378
tiny.c 6.98 KB