Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

arm64: vdso32: Code clean up

The compat vdso library had some checks that are not anymore relevant.

Remove the unused code from the compat vDSO library.

Note: This patch is preparatory for a future one that will introduce
asm/vdso/processor.h on arm64.

Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/lkml/20200317122220.30393-19-vincenzo.frascino@arm.com
Link: https://lkml.kernel.org/r/20200320145351.32292-19-vincenzo.frascino@arm.com

authored by

Vincenzo Frascino and committed by
Thomas Gleixner
94d0f5be b5580517

-20
-8
arch/arm64/include/asm/vdso/compat_gettimeofday.h
··· 76 76 register long ret asm ("r0"); 77 77 register long nr asm("r7") = __NR_compat_clock_getres_time64; 78 78 79 - /* The checks below are required for ABI consistency with arm */ 80 - if ((_clkid >= MAX_CLOCKS) && (_ts == NULL)) 81 - return -EINVAL; 82 - 83 79 asm volatile( 84 80 " swi #0\n" 85 81 : "=r" (ret) ··· 92 96 register clockid_t clkid asm("r0") = _clkid; 93 97 register long ret asm ("r0"); 94 98 register long nr asm("r7") = __NR_compat_clock_getres; 95 - 96 - /* The checks below are required for ABI consistency with arm */ 97 - if ((_clkid >= MAX_CLOCKS) && (_ts == NULL)) 98 - return -EINVAL; 99 99 100 100 asm volatile( 101 101 " swi #0\n"
-12
arch/arm64/kernel/vdso32/vgettimeofday.c
··· 11 11 int __vdso_clock_gettime(clockid_t clock, 12 12 struct old_timespec32 *ts) 13 13 { 14 - /* The checks below are required for ABI consistency with arm */ 15 - if ((u32)ts >= TASK_SIZE_32) 16 - return -EFAULT; 17 - 18 14 return __cvdso_clock_gettime32(clock, ts); 19 15 } 20 16 21 17 int __vdso_clock_gettime64(clockid_t clock, 22 18 struct __kernel_timespec *ts) 23 19 { 24 - /* The checks below are required for ABI consistency with arm */ 25 - if ((u32)ts >= TASK_SIZE_32) 26 - return -EFAULT; 27 - 28 20 return __cvdso_clock_gettime(clock, ts); 29 21 } 30 22 ··· 29 37 int __vdso_clock_getres(clockid_t clock_id, 30 38 struct old_timespec32 *res) 31 39 { 32 - /* The checks below are required for ABI consistency with arm */ 33 - if ((u32)res >= TASK_SIZE_32) 34 - return -EFAULT; 35 - 36 40 return __cvdso_clock_getres_time32(clock_id, res); 37 41 } 38 42