]> git.baikalelectronics.ru Git - kernel.git/commitdiff
s390/ipl: use register pair instead of register asm
authorHeiko Carstens <hca@linux.ibm.com>
Mon, 14 Jun 2021 20:32:21 +0000 (22:32 +0200)
committerVasily Gorbik <gor@linux.ibm.com>
Fri, 18 Jun 2021 14:41:24 +0000 (16:41 +0200)
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
arch/s390/kernel/ipl.c

index dba04fbc37a210b4a412281c6074fcac13398e28..9ae33977e0b7469dbfc323151ce35adf92c7d3f5 100644 (file)
@@ -162,16 +162,18 @@ static bool reipl_ccw_clear;
 
 static inline int __diag308(unsigned long subcode, void *addr)
 {
-       register unsigned long _addr asm("0") = (unsigned long) addr;
-       register unsigned long _rc asm("1") = 0;
+       union register_pair r1;
 
+       r1.even = (unsigned long) addr;
+       r1.odd  = 0;
        asm volatile(
-               "       diag    %0,%2,0x308\n"
+               "       diag    %[r1],%[subcode],0x308\n"
                "0:     nopr    %%r7\n"
                EX_TABLE(0b,0b)
-               : "+d" (_addr), "+d" (_rc)
-               : "d" (subcode) : "cc", "memory");
-       return _rc;
+               : [r1] "+&d" (r1.pair)
+               : [subcode] "d" (subcode)
+               : "cc", "memory");
+       return r1.odd;
 }
 
 int diag308(unsigned long subcode, void *addr)