aboutsummaryrefslogtreecommitdiff
path: root/arch/s390/kernel/diag.c
diff options
context:
space:
mode:
authorHeiko Carstens2021-06-09 22:59:13 +0200
committerVasily Gorbik2021-06-18 16:41:21 +0200
commit3c45a07bee619bb997b75b323f8d014e3efb36f8 (patch)
tree1485700a6ab4008b275892683b6ed9cf904025db /arch/s390/kernel/diag.c
parent75c89a2bc6ef00fd3c38c69cba82a92d0535887a (diff)
s390/diag: use register pair instead of register asm
Signed-off-by: Heiko Carstens <hca@linux.ibm.com> Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Diffstat (limited to 'arch/s390/kernel/diag.c')
-rw-r--r--arch/s390/kernel/diag.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/arch/s390/kernel/diag.c b/arch/s390/kernel/diag.c
index b8b0cd7b008f..a3f47464c3f1 100644
--- a/arch/s390/kernel/diag.c
+++ b/arch/s390/kernel/diag.c
@@ -141,16 +141,15 @@ EXPORT_SYMBOL(diag14);
static inline int __diag204(unsigned long *subcode, unsigned long size, void *addr)
{
- register unsigned long _subcode asm("0") = *subcode;
- register unsigned long _size asm("1") = size;
+ union register_pair rp = { .even = *subcode, .odd = size };
asm volatile(
- " diag %2,%0,0x204\n"
+ " diag %[addr],%[rp],0x204\n"
"0: nopr %%r7\n"
EX_TABLE(0b,0b)
- : "+d" (_subcode), "+d" (_size) : "d" (addr) : "memory");
- *subcode = _subcode;
- return _size;
+ : [rp] "+&d" (rp.pair) : [addr] "d" (addr) : "memory");
+ *subcode = rp.even;
+ return rp.odd;
}
int diag204(unsigned long subcode, unsigned long size, void *addr)