diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2022-05-02 09:20:42 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2022-05-02 09:28:31 +0200 |
commit | b91c0922bf1ed15b67a6faa404bc64e3ed532ec2 (patch) | |
tree | 5fee62012539f37ea0f3ba92ec145f080b50de12 /arch | |
parent | 8ad7e8f696951f192c6629a0cbda9ac94c773159 (diff) |
x86/fpu: Cleanup variable shadowing
Addresses: warning: Local variable 'mask' shadows outer variable
Remove extra variable declaration and switch the bit mask assignment to use
BIT_ULL() while at it.
Fixes: 522e92743b35 ("x86/fpu: Deduplicate copy_uabi_from_user/kernel_to_xstate()")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/lkml/202204262032.jFYKit5j-lkp@intel.com
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/kernel/fpu/xstate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/fpu/xstate.c b/arch/x86/kernel/fpu/xstate.c index 31c12f4d0770..81fcd04247de 100644 --- a/arch/x86/kernel/fpu/xstate.c +++ b/arch/x86/kernel/fpu/xstate.c @@ -1233,7 +1233,7 @@ static int copy_uabi_to_xstate(struct fpstate *fpstate, const void *kbuf, } for (i = 0; i < XFEATURE_MAX; i++) { - u64 mask = ((u64)1 << i); + mask = BIT_ULL(i); if (hdr.xfeatures & mask) { void *dst = __raw_xsave_addr(xsave, i); |