From: Heiko Carstens <hca@linux.ibm.com>
Date: Mon, 22 Mar 2021 15:12:56 +0000 (+0100)
Subject: s390/spinlock: use R constraint in inline assembly
X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=4f9abb7e70f2f4808f0fce36b66232890201c6a3;p=linux.git

s390/spinlock: use R constraint in inline assembly

Allow the compiler to generate slightly better code by using the R
constraint.

Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
---

diff --git a/arch/s390/include/asm/spinlock.h b/arch/s390/include/asm/spinlock.h
index 3a37172d53985..ef59588a3042d 100644
--- a/arch/s390/include/asm/spinlock.h
+++ b/arch/s390/include/asm/spinlock.h
@@ -88,7 +88,7 @@ static inline void arch_spin_unlock(arch_spinlock_t *lp)
 	asm_inline volatile(
 		ALTERNATIVE("", ".long 0xb2fa0070", 49)	/* NIAI 7 */
 		"	sth	%1,%0\n"
-		: "=Q" (((unsigned short *) &lp->lock)[1])
+		: "=R" (((unsigned short *) &lp->lock)[1])
 		: "d" (0) : "cc", "memory");
 }