• Paul E. McKenney's avatar
    rcu: Regularize resetting of rcu_data wrap indicator · 3d18469a
    Paul E. McKenney authored
    The rcu_data structure's ->gpwrap indicator is currently reset only
    when the CPU in question detects a new grace period.  This is in theory
    sufficient because any CPU that has been out of action for long enough
    that its ->gpwrap indicator is set is guaranteed to see both the end
    of an old grace period and the start of a new one.
    
    However, the current code leaves a short window during which the ->gpwrap
    indicator has been reset but the corresponding ->gp_seq counter has not
    yet been brought up to date.  This is harmless because interrupts are
    disabled, but it is likely to (at the very least) cause confusion.
    
    This commit therefore moves the resetting of ->gpwrap to follow the
    updating of ->gp_seq.  While in the area, it also resets ->gp_seq_needed.
    Signed-off-by: default avatarPaul E. McKenney <paulmck@linux.vnet.ibm.com>
    3d18469a
tree.c 128 KB