Linux: Fix 32-bit vDSO for clock_gettime on powerpc32
authormaminjie <maminjie2@huawei.com>
Mon, 20 Dec 2021 11:36:32 +0000 (19:36 +0800)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Tue, 21 Dec 2021 12:47:16 +0000 (09:47 -0300)
commite0fc721ce600038dd390e77cfe52440707ef574d
treea73e91be713e1e136975e165f3896d80a8e8c3c6
parentde8a0897e3c084dc93676e331b610f146000a0ab
Linux: Fix 32-bit vDSO for clock_gettime on powerpc32

When the clock_id is CLOCK_PROCESS_CPUTIME_ID or CLOCK_THREAD_CPUTIME_ID,
on the 5.10 kernel powerpc 32-bit, the 32-bit vDSO is executed successfully (
because the __kernel_clock_gettime in arch/powerpc/kernel/vdso32/gettimeofday.S
does not support these two IDs, the 32-bit time_t syscall will be used),
but tp32.tv_sec is equal to 0, causing the 64-bit time_t syscall to continue to be used,
resulting in two system calls.

Fix commit 72e84d1db22203e01a43268de71ea8669eca2863.

Signed-off-by: maminjie <maminjie2@huawei.com>
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
sysdeps/unix/sysv/linux/clock_gettime.c