s390/uaccess: use symbolic names for inline assembler operands
authorHeiko Carstens <hca@linux.ibm.com>
Sun, 29 May 2022 16:55:06 +0000 (18:55 +0200)
committerHeiko Carstens <hca@linux.ibm.com>
Wed, 1 Jun 2022 10:03:16 +0000 (12:03 +0200)
Make code easier to read by using symbolic names.

Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
arch/s390/include/asm/uaccess.h

index 1f150a7..5ffb88b 100644 (file)
@@ -278,12 +278,12 @@ int __noreturn __put_kernel_bad(void);
        int __rc;                                                       \
                                                                        \
        asm volatile(                                                   \
-               "0:   " insn "  %2,%1\n"                                \
-               "1:     xr      %0,%0\n"                                \
+               "0:   " insn "  %[_val],%[_to]\n"                       \
+               "1:     xr      %[rc],%[rc]\n"                          \
                "2:\n"                                                  \
                EX_TABLE_UA(0b,2b,%0) EX_TABLE_UA(1b,2b,%0)             \
-               : "=d" (__rc), "+Q" (*(to))                             \
-               : "d" (val)                                             \
+               : [rc] "=d" (__rc), [_to] "+Q" (*(to))                  \
+               : [_val] "d" (val)                                      \
                : "cc");                                                \
        __rc;                                                           \
 })
@@ -321,12 +321,12 @@ int __noreturn __get_kernel_bad(void);
        int __rc;                                                       \
                                                                        \
        asm volatile(                                                   \
-               "0:   " insn "  %1,%2\n"                                \
-               "1:     xr      %0,%0\n"                                \
+               "0:   " insn "  %[_val],%[_from]\n"                     \
+               "1:     xr      %[rc],%[rc]\n"                          \
                "2:\n"                                                  \
                EX_TABLE_UA(0b,2b,%0) EX_TABLE_UA(1b,2b,%0)             \
-               : "=d" (__rc), "+d" (val)                               \
-               : "Q" (*(from))                                         \
+               : [rc] "=d" (__rc), [_val] "+d" (val)                   \
+               : [_from] "Q" (*(from))                                 \
                : "cc");                                                \
        __rc;                                                           \
 })