Skip to content

Commit 880f615

Browse files
t-8chjmberg-intel
authored andcommitted
um: Remove redundant range check from __access_ok_vsyscall()
The only caller __access_ok() is already doing the same check through __addr_range_nowrap(). Remove the redundant check. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Link: https://patch.msgid.link/20251028-uml-remove-32bit-pseudo-vdso-v1-7-e930063eff5f@weissschuh.net Signed-off-by: Johannes Berg <johannes.berg@intel.com>
1 parent 78fdfc9 commit 880f615

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

arch/um/include/asm/uaccess.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@
1717

1818
#define __access_ok_vsyscall(addr, size) \
1919
(((unsigned long) (addr) >= FIXADDR_USER_START) && \
20-
((unsigned long) (addr) + (size) <= FIXADDR_USER_END) && \
21-
((unsigned long) (addr) + (size) >= (unsigned long)(addr)))
20+
((unsigned long) (addr) + (size) <= FIXADDR_USER_END))
2221

2322
#define __addr_range_nowrap(addr, size) \
2423
((unsigned long) (addr) <= ((unsigned long) (addr) + (size)))

0 commit comments

Comments
 (0)