diff options
author | Heiko Carstens <hca@linux.ibm.com> | 2024-11-07 16:11:44 +0100 |
---|---|---|
committer | Heiko Carstens <hca@linux.ibm.com> | 2024-11-13 14:31:33 +0100 |
commit | a6122f690af6deefc67cc95a7d8139e63bdbdb39 (patch) | |
tree | 3e7475ba26774be88e28970fa5af15e124366185 | |
parent | 5a5897d65b6f7b3c0f2dd39dcffa9b08317942a9 (diff) |
s390/diag: Convert to use flag output macros
Use flag output macros in inline asm to allow for better code generation if
the compiler has support for the flag output constraint.
Reviewed-by: Juergen Christ <jchrist@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
-rw-r--r-- | arch/s390/kernel/diag.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/s390/kernel/diag.c b/arch/s390/kernel/diag.c index 007e1795670e..cdd6e31344fa 100644 --- a/arch/s390/kernel/diag.c +++ b/arch/s390/kernel/diag.c @@ -16,6 +16,7 @@ #include <asm/diag.h> #include <asm/trace/diag.h> #include <asm/sections.h> +#include <asm/asm.h> #include "entry.h" struct diag_stat { @@ -307,16 +308,15 @@ EXPORT_SYMBOL(diag26c); int diag49c(unsigned long subcode) { - int rc; + int cc; diag_stat_inc(DIAG_STAT_X49C); asm volatile( " diag %[subcode],0,0x49c\n" - " ipm %[rc]\n" - " srl %[rc],28\n" - : [rc] "=d" (rc) + CC_IPM(cc) + : CC_OUT(cc, cc) : [subcode] "d" (subcode) - : "cc"); - return rc; + : CC_CLOBBER); + return CC_TRANSFORM(cc); } EXPORT_SYMBOL(diag49c); |