summaryrefslogtreecommitdiff
path: root/arch/s390/lib
diff options
context:
space:
mode:
authorHeiko Carstens <hca@linux.ibm.com>2023-03-24 17:00:22 +0300
committerVasily Gorbik <gor@linux.ibm.com>2023-04-04 19:27:24 +0300
commit7f65d18329a2546ce6f64ac6bf141c38b15c2ab3 (patch)
tree357f52328c9909cfa037343d1d3346a639528699 /arch/s390/lib
parentafdcc2ce3970ccad0ec4fb2d2c614e444c59f770 (diff)
downloadlinux-7f65d18329a2546ce6f64ac6bf141c38b15c2ab3.tar.xz
s390/uaccess: rename tmp1 and tmp2 variables
Rename tmp1 and tmp2 variables to more meaningful val (for value) and rem (for remainder). Except for debug sections the output of "objdump -Dr" of the uaccess object file is identical before/after this change. Reviewed-by: Gerald Schaefer <gerald.schaefer@linux.ibm.com> Signed-off-by: Heiko Carstens <hca@linux.ibm.com> Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Diffstat (limited to 'arch/s390/lib')
-rw-r--r--arch/s390/lib/uaccess.c70
1 files changed, 35 insertions, 35 deletions
diff --git a/arch/s390/lib/uaccess.c b/arch/s390/lib/uaccess.c
index 7f33eb4dffba..a89f6639818a 100644
--- a/arch/s390/lib/uaccess.c
+++ b/arch/s390/lib/uaccess.c
@@ -34,7 +34,7 @@ void debug_user_asce(int exit)
static unsigned long raw_copy_from_user_key(void *to, const void __user *from,
unsigned long size, unsigned long key)
{
- unsigned long tmp1, tmp2;
+ unsigned long val, rem;
union oac spec = {
.oac2.key = key,
.oac2.as = PSW_BITS_AS_SECONDARY,
@@ -42,22 +42,22 @@ static unsigned long raw_copy_from_user_key(void *to, const void __user *from,
.oac2.a = 1,
};
- tmp1 = -4096UL;
+ val = -4096UL;
asm volatile(
" lr 0,%[spec]\n"
"0: mvcos 0(%[to]),0(%[from]),%[size]\n"
"1: jz 5f\n"
- " algr %[size],%[tmp1]\n"
- " slgr %[from],%[tmp1]\n"
- " slgr %[to],%[tmp1]\n"
+ " algr %[size],%[val]\n"
+ " slgr %[from],%[val]\n"
+ " slgr %[to],%[val]\n"
" j 0b\n"
- "2: la %[tmp2],4095(%[from])\n"/* tmp2 = from + 4095 */
- " nr %[tmp2],%[tmp1]\n" /* tmp2 = (from + 4095) & -4096 */
- " slgr %[tmp2],%[from]\n"
- " clgr %[size],%[tmp2]\n" /* copy crosses next page boundary? */
+ "2: la %[rem],4095(%[from])\n" /* rem = from + 4095 */
+ " nr %[rem],%[val]\n" /* rem = (from + 4095) & -4096 */
+ " slgr %[rem],%[from]\n"
+ " clgr %[size],%[rem]\n" /* copy crosses next page boundary? */
" jnh 6f\n"
- "3: mvcos 0(%[to]),0(%[from]),%[tmp2]\n"
- "4: slgr %[size],%[tmp2]\n"
+ "3: mvcos 0(%[to]),0(%[from]),%[rem]\n"
+ "4: slgr %[size],%[rem]\n"
" j 6f\n"
"5: slgr %[size],%[size]\n"
"6:\n"
@@ -66,7 +66,7 @@ static unsigned long raw_copy_from_user_key(void *to, const void __user *from,
EX_TABLE(3b, 6b)
EX_TABLE(4b, 6b)
: [size] "+a" (size), [from] "+a" (from), [to] "+a" (to),
- [tmp1] "+a" (tmp1), [tmp2] "=a" (tmp2)
+ [val] "+a" (val), [rem] "=a" (rem)
: [spec] "d" (spec.val)
: "cc", "memory", "0");
return size;
@@ -98,7 +98,7 @@ EXPORT_SYMBOL(_copy_from_user_key);
static unsigned long raw_copy_to_user_key(void __user *to, const void *from,
unsigned long size, unsigned long key)
{
- unsigned long tmp1, tmp2;
+ unsigned long val, rem;
union oac spec = {
.oac1.key = key,
.oac1.as = PSW_BITS_AS_SECONDARY,
@@ -106,22 +106,22 @@ static unsigned long raw_copy_to_user_key(void __user *to, const void *from,
.oac1.a = 1,
};
- tmp1 = -4096UL;
+ val = -4096UL;
asm volatile(
" lr 0,%[spec]\n"
"0: mvcos 0(%[to]),0(%[from]),%[size]\n"
"1: jz 5f\n"
- " algr %[size],%[tmp1]\n"
- " slgr %[to],%[tmp1]\n"
- " slgr %[from],%[tmp1]\n"
+ " algr %[size],%[val]\n"
+ " slgr %[to],%[val]\n"
+ " slgr %[from],%[val]\n"
" j 0b\n"
- "2: la %[tmp2],4095(%[to])\n" /* tmp2 = to + 4095 */
- " nr %[tmp2],%[tmp1]\n" /* tmp2 = (to + 4095) & -4096 */
- " slgr %[tmp2],%[to]\n"
- " clgr %[size],%[tmp2]\n" /* copy crosses next page boundary? */
+ "2: la %[rem],4095(%[to])\n" /* rem = to + 4095 */
+ " nr %[rem],%[val]\n" /* rem = (to + 4095) & -4096 */
+ " slgr %[rem],%[to]\n"
+ " clgr %[size],%[rem]\n" /* copy crosses next page boundary? */
" jnh 6f\n"
- "3: mvcos 0(%[to]),0(%[from]),%[tmp2]\n"
- "4: slgr %[size],%[tmp2]\n"
+ "3: mvcos 0(%[to]),0(%[from]),%[rem]\n"
+ "4: slgr %[size],%[rem]\n"
" j 6f\n"
"5: slgr %[size],%[size]\n"
"6:\n"
@@ -130,7 +130,7 @@ static unsigned long raw_copy_to_user_key(void __user *to, const void *from,
EX_TABLE(3b, 6b)
EX_TABLE(4b, 6b)
: [size] "+a" (size), [to] "+a" (to), [from] "+a" (from),
- [tmp1] "+a" (tmp1), [tmp2] "=a" (tmp2)
+ [val] "+a" (val), [rem] "=a" (rem)
: [spec] "d" (spec.val)
: "cc", "memory", "0");
return size;
@@ -155,27 +155,27 @@ EXPORT_SYMBOL(_copy_to_user_key);
unsigned long __clear_user(void __user *to, unsigned long size)
{
- unsigned long tmp1, tmp2;
+ unsigned long val, rem;
union oac spec = {
.oac1.as = PSW_BITS_AS_SECONDARY,
.oac1.a = 1,
};
- tmp1 = -4096UL;
+ val = -4096UL;
asm volatile(
" lr 0,%[spec]\n"
"0: mvcos 0(%[to]),0(%[zeropg]),%[size]\n"
"1: jz 5f\n"
- " algr %[size],%[tmp1]\n"
- " slgr %[to],%[tmp1]\n"
+ " algr %[size],%[val]\n"
+ " slgr %[to],%[val]\n"
" j 0b\n"
- "2: la %[tmp2],4095(%[to])\n" /* tmp2 = to + 4095 */
- " nr %[tmp2],%[tmp1]\n" /* tmp2 = (to + 4095) & -4096 */
- " slgr %[tmp2],%[to]\n"
- " clgr %[size],%[tmp2]\n" /* copy crosses next page boundary? */
+ "2: la %[rem],4095(%[to])\n" /* rem = to + 4095 */
+ " nr %[rem],%[val]\n" /* rem = (to + 4095) & -4096 */
+ " slgr %[rem],%[to]\n"
+ " clgr %[size],%[rem]\n" /* copy crosses next page boundary? */
" jnh 6f\n"
- "3: mvcos 0(%[to]),0(%[zeropg]),%[tmp2]\n"
- "4: slgr %[size],%[tmp2]\n"
+ "3: mvcos 0(%[to]),0(%[zeropg]),%[rem]\n"
+ "4: slgr %[size],%[rem]\n"
" j 6f\n"
"5: slgr %[size],%[size]\n"
"6:\n"
@@ -184,7 +184,7 @@ unsigned long __clear_user(void __user *to, unsigned long size)
EX_TABLE(3b, 6b)
EX_TABLE(4b, 6b)
: [size] "+&a" (size), [to] "+&a" (to),
- [tmp1] "+a" (tmp1), [tmp2] "=&a" (tmp2)
+ [val] "+a" (val), [rem] "=&a" (rem)
: [zeropg] "a" (empty_zero_page), [spec] "d" (spec.val)
: "cc", "memory", "0");
return size;