Skip to content
  • Andrew Jones's avatar
    arm/arm64: spinlocks: fix memory barriers · 23fb3b17
    Andrew Jones authored
    
    
    It shouldn't be necessary to use a barrier on the way into
    spin_lock. We'll be focused on a single address until we get
    it (exclusively) set, and then we'll do a barrier on the way
    out. Also, it does make sense to do a barrier on the way in
    to spin_unlock, i.e. ensure what we did in the critical section
    is ordered wrt to what we do outside it, before we announce that
    we're outside.
    
    Signed-off-by: default avatarAndrew Jones <drjones@redhat.com>
    Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
    23fb3b17