• Heiko Carstens's avatar
    s390/atomic,cmpxchg: make constraints work with old compilers · 3e5ee323
    Heiko Carstens authored
    Old gcc versions may fail with an internal compiler error if only the
    T or S constraint is specified for an operand, and no displacement is
    needed at all.
    
    To fix this use RT and QS as constraints, which reflects the union of
    both. Later gcc versions do the right thing and always accept single T
    and S constraints.
    See gcc commit 3e4be43f69da ("S/390: Memory constraint cleanup").
    
    Fixes: ca897bb1 ("s390/atomic: use proper constraints")
    Fixes: b23eb636 ("s390/atomic: get rid of gcc atomic builtins")
    Fixes: d2b1f6d2 ("s390/cmpxchg: get rid of gcc atomic builtins")
    Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
    3e5ee323
atomic_ops.h 4.98 KB