From 313119e81a7c2ad5f044d5ea876682633aa4827d Mon Sep 17 00:00:00 2001 From: "Dmitry V. Levin" Date: Sun, 12 May 2019 22:45:45 +0000 Subject: [PATCH] Implement and use new parsers of clock_gettime and clock_settime syscalls * time.c (SYS_FUNC(clock_gettime), SYS_FUNC(clock_settime)): Remove. [HAVE_ARCH_TIME32_SYSCALLS] (SYS_FUNC(clock_gettime32), SYS_FUNC(clock_settime32)): New functions. * linux/dummy.h (sys_clock_getres): Remove. (sys_clock_getres_time32): Redirect to sys_clock_gettime32. * linux/64/syscallent.h: Replace SEN(clock_gettime), SEN(clock_settime), and SEN(clock_getres) with SEN(clock_gettime64), SEN(clock_settime64), and SEN(clock_getres_time64), respectively. * linux/alpha/syscallent.h: Likewise. * linux/ia64/syscallent.h: Likewise. * linux/mips/syscallent-n64.h: Likewise. * linux/powerpc64/syscallent.h: Likewise. * linux/s390x/syscallent.h: Likewise. * linux/sh64/syscallent.h: Likewise. * linux/sparc64/syscallent.h: Likewise. * linux/x32/syscallent.h: Likewise. * linux/x86_64/syscallent.h: Likewise. * linux/32/syscallent.h: Replace SEN(clock_gettime), SEN(clock_settime), and SEN(clock_getres) with SEN(clock_gettime32), SEN(clock_settime32), and SEN(clock_getres_time32), respectively. * linux/arm/syscallent.h: Likewise. * linux/avr32/syscallent.h: Likewise. * linux/bfin/syscallent.h: Likewise. * linux/hppa/syscallent.h: Likewise. * linux/i386/syscallent.h: Likewise. * linux/m68k/syscallent.h: Likewise. * linux/microblaze/syscallent.h: Likewise. * linux/mips/syscallent-n32.h: Likewise. * linux/mips/syscallent-o32.h: Likewise. * linux/powerpc/syscallent.h: Likewise. * linux/s390/syscallent.h: Likewise. * linux/sh/syscallent.h: Likewise. * linux/sparc/syscallent.h: Likewise. * linux/xtensa/syscallent.h: Likewise. --- linux/32/syscallent.h | 6 +++--- linux/64/syscallent.h | 6 +++--- linux/alpha/syscallent.h | 6 +++--- linux/arm/syscallent.h | 6 +++--- linux/avr32/syscallent.h | 6 +++--- linux/bfin/syscallent.h | 6 +++--- linux/dummy.h | 2 +- linux/hppa/syscallent.h | 6 +++--- linux/i386/syscallent.h | 6 +++--- linux/ia64/syscallent.h | 6 +++--- linux/m68k/syscallent.h | 6 +++--- linux/microblaze/syscallent.h | 6 +++--- linux/mips/syscallent-n32.h | 6 +++--- linux/mips/syscallent-n64.h | 6 +++--- linux/mips/syscallent-o32.h | 6 +++--- linux/powerpc/syscallent.h | 6 +++--- linux/powerpc64/syscallent.h | 6 +++--- linux/s390/syscallent.h | 6 +++--- linux/s390x/syscallent.h | 6 +++--- linux/sh/syscallent.h | 6 +++--- linux/sh64/syscallent.h | 6 +++--- linux/sparc/syscallent.h | 6 +++--- linux/sparc64/syscallent.h | 6 +++--- linux/x32/syscallent.h | 6 +++--- linux/x86_64/syscallent.h | 6 +++--- linux/xtensa/syscallent.h | 6 +++--- time.c | 12 ++++++++---- 27 files changed, 84 insertions(+), 80 deletions(-) diff --git a/linux/32/syscallent.h b/linux/32/syscallent.h index 740af60e..95e28a36 100644 --- a/linux/32/syscallent.h +++ b/linux/32/syscallent.h @@ -124,9 +124,9 @@ [109] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [110] = { 4, 0, SEN(timer_settime), "timer_settime" }, [111] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[112] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[113] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[114] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[112] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[113] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[114] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [115] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [116] = { 3, 0, SEN(syslog), "syslog" }, [117] = { 4, 0, SEN(ptrace), "ptrace" }, diff --git a/linux/64/syscallent.h b/linux/64/syscallent.h index 0b17f285..850a1dd1 100644 --- a/linux/64/syscallent.h +++ b/linux/64/syscallent.h @@ -117,9 +117,9 @@ [109] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [110] = { 4, 0, SEN(timer_settime), "timer_settime" }, [111] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[112] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[113] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[114] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[112] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[113] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[114] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [115] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [116] = { 3, 0, SEN(syslog), "syslog" }, [117] = { 4, 0, SEN(ptrace), "ptrace" }, diff --git a/linux/alpha/syscallent.h b/linux/alpha/syscallent.h index 59cf73f7..ae3d23a6 100644 --- a/linux/alpha/syscallent.h +++ b/linux/alpha/syscallent.h @@ -362,9 +362,9 @@ [416] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [417] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [418] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[419] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[420] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[421] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[419] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[420] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[421] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [422] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [423] = { 4, TI, SEN(semtimedop_time64), "semtimedop" }, [424] = { 3, TS, SEN(tgkill), "tgkill" }, diff --git a/linux/arm/syscallent.h b/linux/arm/syscallent.h index a463c59b..644369f2 100644 --- a/linux/arm/syscallent.h +++ b/linux/arm/syscallent.h @@ -269,9 +269,9 @@ [259] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [260] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [261] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[262] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[263] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[264] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[262] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[263] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[264] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [265] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [266] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [267] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/avr32/syscallent.h b/linux/avr32/syscallent.h index 6d7cdda9..658c8a2f 100644 --- a/linux/avr32/syscallent.h +++ b/linux/avr32/syscallent.h @@ -221,9 +221,9 @@ [212] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [213] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [214] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[215] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[216] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[217] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[215] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[216] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[217] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [218] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [219] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [220] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/bfin/syscallent.h b/linux/bfin/syscallent.h index c3f98099..6f0b954b 100644 --- a/linux/bfin/syscallent.h +++ b/linux/bfin/syscallent.h @@ -271,9 +271,9 @@ [262] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [263] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [264] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[265] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[266] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[267] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[265] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[266] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[267] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [268] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [269] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [270] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/dummy.h b/linux/dummy.h index 012c844c..dfd316c4 100644 --- a/linux/dummy.h +++ b/linux/dummy.h @@ -40,7 +40,7 @@ /* like another call */ # define sys_acct sys_chdir # define sys_chroot sys_chdir -# define sys_clock_getres sys_clock_gettime +# define sys_clock_getres_time32 sys_clock_gettime32 # define sys_clock_getres_time64 sys_clock_gettime64 # define sys_connect sys_bind # define sys_fchdir sys_close diff --git a/linux/hppa/syscallent.h b/linux/hppa/syscallent.h index c4ec0d0a..9c245511 100644 --- a/linux/hppa/syscallent.h +++ b/linux/hppa/syscallent.h @@ -258,9 +258,9 @@ [252] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [253] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [254] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[255] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[256] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[257] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[255] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[256] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[257] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [258] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [259] = { 3, TS, SEN(tgkill), "tgkill" }, [260] = { 6, TM, SEN(mbind), "mbind" }, diff --git a/linux/i386/syscallent.h b/linux/i386/syscallent.h index 67e56f1b..9bcb55b3 100644 --- a/linux/i386/syscallent.h +++ b/linux/i386/syscallent.h @@ -270,9 +270,9 @@ [261] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [262] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [263] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[264] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[265] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[266] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[264] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[265] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[266] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [267] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [268] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [269] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/ia64/syscallent.h b/linux/ia64/syscallent.h index f76c1ebc..cdc72850 100644 --- a/linux/ia64/syscallent.h +++ b/linux/ia64/syscallent.h @@ -236,9 +236,9 @@ [1024 + 226] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [1024 + 227] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [1024 + 228] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[1024 + 229] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[1024 + 230] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[1024 + 231] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[1024 + 229] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[1024 + 230] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[1024 + 231] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [1024 + 232] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [1024 + 233] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, [1024 + 234] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, diff --git a/linux/m68k/syscallent.h b/linux/m68k/syscallent.h index ebb62174..428ed6ef 100644 --- a/linux/m68k/syscallent.h +++ b/linux/m68k/syscallent.h @@ -265,9 +265,9 @@ [256] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [257] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [258] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[259] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[260] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[261] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[259] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[260] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[261] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [262] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [263] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [264] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/microblaze/syscallent.h b/linux/microblaze/syscallent.h index bf1548df..b616845a 100644 --- a/linux/microblaze/syscallent.h +++ b/linux/microblaze/syscallent.h @@ -270,9 +270,9 @@ [261] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [262] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [263] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[264] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[265] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[266] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[264] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[265] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[266] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [267] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [268] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [269] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/mips/syscallent-n32.h b/linux/mips/syscallent-n32.h index 67fc9f2c..06001adf 100644 --- a/linux/mips/syscallent-n32.h +++ b/linux/mips/syscallent-n32.h @@ -232,9 +232,9 @@ [6222] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [6223] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [6224] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[6225] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[6226] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[6227] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[6225] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[6226] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[6227] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [6228] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [6229] = { 3, TS, SEN(tgkill), "tgkill" }, [6230] = { 2, TF, SEN(utimes), "utimes" }, diff --git a/linux/mips/syscallent-n64.h b/linux/mips/syscallent-n64.h index 50da3727..4c2ff19a 100644 --- a/linux/mips/syscallent-n64.h +++ b/linux/mips/syscallent-n64.h @@ -228,9 +228,9 @@ [5218] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [5219] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [5220] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[5221] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[5222] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[5223] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[5221] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[5222] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[5223] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [5224] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [5225] = { 3, TS, SEN(tgkill), "tgkill" }, [5226] = { 2, TF, SEN(utimes), "utimes" }, diff --git a/linux/mips/syscallent-o32.h b/linux/mips/syscallent-o32.h index 4f6bc31d..92023dd8 100644 --- a/linux/mips/syscallent-o32.h +++ b/linux/mips/syscallent-o32.h @@ -270,9 +270,9 @@ [4259] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [4260] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [4261] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[4262] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[4263] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[4264] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[4262] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[4263] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[4264] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [4265] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [4266] = { 3, TS, SEN(tgkill), "tgkill" }, [4267] = { 2, TF, SEN(utimes), "utimes" }, diff --git a/linux/powerpc/syscallent.h b/linux/powerpc/syscallent.h index 4579488f..8d001062 100644 --- a/linux/powerpc/syscallent.h +++ b/linux/powerpc/syscallent.h @@ -252,9 +252,9 @@ [242] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [243] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [244] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[245] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[246] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[247] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[245] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[246] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[247] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [248] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [249] = { 2, 0, SEN(printargs), "swapcontext" }, [250] = { 3, TS, SEN(tgkill), "tgkill" }, diff --git a/linux/powerpc64/syscallent.h b/linux/powerpc64/syscallent.h index 01803ad6..cc5b15a3 100644 --- a/linux/powerpc64/syscallent.h +++ b/linux/powerpc64/syscallent.h @@ -247,9 +247,9 @@ [242] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [243] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [244] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[245] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[246] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[247] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[245] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[246] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[247] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [248] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [249] = { 2, 0, SEN(printargs), "swapcontext" }, [250] = { 3, TS, SEN(tgkill), "tgkill" }, diff --git a/linux/s390/syscallent.h b/linux/s390/syscallent.h index 64228c1a..2b171e63 100644 --- a/linux/s390/syscallent.h +++ b/linux/s390/syscallent.h @@ -268,9 +268,9 @@ [256] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [257] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [258] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[259] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[260] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[261] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[259] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[260] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[261] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [262] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [263] = { 5, 0, SEN(vserver), "vserver" }, [264] = { 6, TD, SEN(fadvise64_64), "fadvise64_64" }, diff --git a/linux/s390x/syscallent.h b/linux/s390x/syscallent.h index 5d34ff8b..3848e5c3 100644 --- a/linux/s390x/syscallent.h +++ b/linux/s390x/syscallent.h @@ -252,9 +252,9 @@ [256] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [257] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [258] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[259] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[260] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[261] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[259] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[260] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[261] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [262] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [263] = { 5, 0, SEN(vserver), "vserver" }, [264] = { }, diff --git a/linux/sh/syscallent.h b/linux/sh/syscallent.h index ff8578d1..8e8ea671 100644 --- a/linux/sh/syscallent.h +++ b/linux/sh/syscallent.h @@ -270,9 +270,9 @@ [261] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [262] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [263] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[264] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[265] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[266] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[264] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[265] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[266] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [267] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [268] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [269] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/sh64/syscallent.h b/linux/sh64/syscallent.h index b441544f..3c88eee5 100644 --- a/linux/sh64/syscallent.h +++ b/linux/sh64/syscallent.h @@ -296,9 +296,9 @@ [289] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [290] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [291] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[292] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[293] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[294] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[292] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[293] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[294] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [295] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [296] = { 3, TF|TSF|TSFA, SEN(statfs64), "statfs64" }, [297] = { 3, TD|TFSF|TSFA, SEN(fstatfs64), "fstatfs64" }, diff --git a/linux/sparc/syscallent.h b/linux/sparc/syscallent.h index f470691a..e61d4aef 100644 --- a/linux/sparc/syscallent.h +++ b/linux/sparc/syscallent.h @@ -261,9 +261,9 @@ [253] = { 1, TD, SEN(fdatasync), "fdatasync" }, [254] = { 3, 0, SEN(nfsservctl), "nfsservctl" }, [255] = { 6, TD, SEN(sync_file_range), "sync_file_range" }, -[256] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[257] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[258] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[256] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[257] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[258] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [259] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [260] = { 3, 0, SEN(sched_getaffinity), "sched_getaffinity" }, [261] = { 3, 0, SEN(sched_setaffinity), "sched_setaffinity" }, diff --git a/linux/sparc64/syscallent.h b/linux/sparc64/syscallent.h index d82a3d68..c723c550 100644 --- a/linux/sparc64/syscallent.h +++ b/linux/sparc64/syscallent.h @@ -259,9 +259,9 @@ [253] = { 1, TD, SEN(fdatasync), "fdatasync" }, [254] = { 3, 0, SEN(nfsservctl), "nfsservctl" }, [255] = { 4, TD, SEN(sync_file_range), "sync_file_range" }, -[256] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[257] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[258] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[256] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[257] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[258] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [259] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [260] = { 3, 0, SEN(sched_getaffinity), "sched_getaffinity" }, [261] = { 3, 0, SEN(sched_setaffinity), "sched_setaffinity" }, diff --git a/linux/x32/syscallent.h b/linux/x32/syscallent.h index e2951cd2..7f9172d6 100644 --- a/linux/x32/syscallent.h +++ b/linux/x32/syscallent.h @@ -232,9 +232,9 @@ [224] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [225] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [226] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[227] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[228] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[229] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[227] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[228] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[229] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [230] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [231] = { 1, TP|SE, SEN(exit), "exit_group" }, [232] = { 4, TD, SEN(epoll_wait), "epoll_wait" }, diff --git a/linux/x86_64/syscallent.h b/linux/x86_64/syscallent.h index ae5e7d3d..fc759fb7 100644 --- a/linux/x86_64/syscallent.h +++ b/linux/x86_64/syscallent.h @@ -232,9 +232,9 @@ [224] = { 2, 0, SEN(timer_gettime), "timer_gettime" }, [225] = { 1, 0, SEN(timer_getoverrun), "timer_getoverrun" }, [226] = { 1, 0, SEN(timer_delete), "timer_delete" }, -[227] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[228] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[229] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[227] = { 2, 0, SEN(clock_settime64), "clock_settime" }, +[228] = { 2, 0, SEN(clock_gettime64), "clock_gettime" }, +[229] = { 2, 0, SEN(clock_getres_time64), "clock_getres" }, [230] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [231] = { 1, TP|SE, SEN(exit), "exit_group" }, [232] = { 4, TD, SEN(epoll_wait), "epoll_wait" }, diff --git a/linux/xtensa/syscallent.h b/linux/xtensa/syscallent.h index 6a50ac9f..6cf51237 100644 --- a/linux/xtensa/syscallent.h +++ b/linux/xtensa/syscallent.h @@ -241,9 +241,9 @@ [241] = { 3, 0, SEN(io_submit), "io_submit" }, [242] = { 5, 0, SEN(io_getevents_time32), "io_getevents" }, [243] = { 3, 0, SEN(io_cancel), "io_cancel" }, -[244] = { 2, 0, SEN(clock_settime), "clock_settime" }, -[245] = { 2, 0, SEN(clock_gettime), "clock_gettime" }, -[246] = { 2, 0, SEN(clock_getres), "clock_getres" }, +[244] = { 2, 0, SEN(clock_settime32), "clock_settime" }, +[245] = { 2, 0, SEN(clock_gettime32), "clock_gettime" }, +[246] = { 2, 0, SEN(clock_getres_time32), "clock_getres" }, [247] = { 4, 0, SEN(clock_nanosleep), "clock_nanosleep" }, [248] = { 3, 0, SEN(timer_create), "timer_create" }, [249] = { 1, 0, SEN(timer_delete), "timer_delete" }, diff --git a/time.c b/time.c index 53329917..364fca4d 100644 --- a/time.c +++ b/time.c @@ -234,10 +234,12 @@ do_clock_settime(struct tcb *const tcp, const print_obj_by_addr_fn print_ts) return RVAL_DECODED; } -SYS_FUNC(clock_settime) +#if HAVE_ARCH_TIME32_SYSCALLS +SYS_FUNC(clock_settime32) { - return do_clock_settime(tcp, print_timespec); + return do_clock_settime(tcp, print_timespec32); } +#endif SYS_FUNC(clock_settime64) { @@ -256,10 +258,12 @@ do_clock_gettime(struct tcb *const tcp, const print_obj_by_addr_fn print_ts) return 0; } -SYS_FUNC(clock_gettime) +#if HAVE_ARCH_TIME32_SYSCALLS +SYS_FUNC(clock_gettime32) { - return do_clock_gettime(tcp, print_timespec); + return do_clock_gettime(tcp, print_timespec32); } +#endif SYS_FUNC(clock_gettime64) { -- 2.40.0