diff options
author | Jann Horn <jannh@google.com> | 2019-03-29 22:46:52 +0100 |
---|---|---|
committer | Borislav Petkov <bp@suse.de> | 2019-04-03 16:26:17 +0200 |
commit | a6cbfbe6677efb5ca47bb7958c2718236c25126e (patch) | |
tree | 8a7b650f68c49510c536e0de18f073368557a45f /lib/extable.c | |
parent | x86/cpufeature: Remove __pure attribute to _static_cpu_has() (diff) | |
download | linux-a6cbfbe6677efb5ca47bb7958c2718236c25126e.tar.xz linux-a6cbfbe6677efb5ca47bb7958c2718236c25126e.zip |
x86/uaccess: Fix implicit cast of __user pointer
The first two arguments of __user_atomic_cmpxchg_inatomic() are:
- @uval is a kernel pointer into which the old value should be stored
- @ptr is the user pointer on which the cmpxchg should operate
This means that casting @uval to __typeof__(ptr) is wrong. Since @uval
is only used once inside the macro, just get rid of __uval and use
(uval) directly.
Signed-off-by: Jann Horn <jannh@google.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Reviewed-by: Mukesh Ojha <mojha@codeaurora.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Andy Lutomirski <luto@kernel.org>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Mike Rapoport <rppt@linux.ibm.com>
Cc: Qiaowei Ren <qiaowei.ren@intel.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Will Deacon <will.deacon@arm.com>
Cc: x86-ml <x86@kernel.org>
Link: https://lkml.kernel.org/r/20190329214652.258477-4-jannh@google.com
Diffstat (limited to 'lib/extable.c')
0 files changed, 0 insertions, 0 deletions