LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] s390/jump_label: Correct asm contraint
@ 2019-01-23 12:55 Laura Abbott
  2019-01-23 13:24 ` Heiko Carstens
  0 siblings, 1 reply; 8+ messages in thread
From: Laura Abbott @ 2019-01-23 12:55 UTC (permalink / raw)
  To: Martin Schwidefsky, Heiko Carstens; +Cc: Laura Abbott, linux-s390, linux-kernel

There's a build failure with gcc9:

 ./arch/s390/include/asm/jump_label.h: Assembler messages:
 ./arch/s390/include/asm/jump_label.h:23: Error: bad expression
 ./arch/s390/include/asm/jump_label.h:23: Error: junk at end of line, first unrecognized character is `r'
 make[1]: *** [scripts/Makefile.build:277: init/main.o] Error 1

According to the toolchain people, the actual issue is the use of
"X" constraint which is too permissive. Switch to using "i" instead.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1668703
Signed-off-by: Laura Abbott <labbott@redhat.com>
---
 arch/s390/include/asm/jump_label.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/s390/include/asm/jump_label.h b/arch/s390/include/asm/jump_label.h
index e2d3e6c43395..41dabfd8518d 100644
--- a/arch/s390/include/asm/jump_label.h
+++ b/arch/s390/include/asm/jump_label.h
@@ -22,7 +22,7 @@ static inline bool arch_static_branch(struct static_key *key, bool branch)
 			  ".long	0b-.,%l[label]-.\n"
 			  ".quad	%0-.\n"
 			  ".popsection\n"
-			  : : "X" (&((char *)key)[branch]) : : label);
+			  : : "i" (&((char *)key)[branch]) : : label);
 	return false;
 label:
 	return true;
@@ -36,7 +36,7 @@ static inline bool arch_static_branch_jump(struct static_key *key, bool branch)
 			  ".long	0b-.,%l[label]-.\n"
 			  ".quad	%0-.\n"
 			  ".popsection\n"
-			  : : "X" (&((char *)key)[branch]) : : label);
+			  : : "i" (&((char *)key)[branch]) : : label);
 	return false;
 label:
 	return true;
-- 
2.20.1


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2019-02-20 18:40 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-23 12:55 [PATCH] s390/jump_label: Correct asm contraint Laura Abbott
2019-01-23 13:24 ` Heiko Carstens
2019-01-29  7:25   ` Laura Abbott
2019-01-30  8:53     ` Heiko Carstens
2019-02-05 12:43     ` Heiko Carstens
2019-02-09 20:34       ` Laura Abbott
2019-02-20  8:58         ` Heiko Carstens
2019-02-20 18:40           ` Laura Abbott

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).