linux/kernel/time
Deepa Dinamani ead25417f8 timex: use __kernel_timex internally
struct timex is not y2038 safe.
Replace all uses of timex with y2038 safe __kernel_timex.

Note that struct __kernel_timex is an ABI interface definition.
We could define a new structure based on __kernel_timex that
is only available internally instead. Right now, there isn't
a strong motivation for this as the structure is isolated to
a few defined struct timex interfaces and such a structure would
be exactly the same as struct timex.

The patch was generated by the following coccinelle script:

virtual patch

@depends on patch forall@
identifier ts;
expression e;
@@
(
- struct timex ts;
+ struct __kernel_timex ts;
|
- struct timex ts = {};
+ struct __kernel_timex ts = {};
|
- struct timex ts = e;
+ struct __kernel_timex ts = e;
|
- struct timex *ts;
+ struct __kernel_timex *ts;
|
(memset \| copy_from_user \| copy_to_user \)(...,
- sizeof(struct timex))
+ sizeof(struct __kernel_timex))
)

@depends on patch forall@
identifier ts;
identifier fn;
@@
fn(...,
- struct timex *ts,
+ struct __kernel_timex *ts,
...) {
...
}

@depends on patch forall@
identifier ts;
identifier fn;
@@
fn(...,
- struct timex *ts) {
+ struct __kernel_timex *ts) {
...
}

Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com>
Cc: linux-alpha@vger.kernel.org
Cc: netdev@vger.kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2019-02-07 00:13:27 +01:00
..
alarmtimer.c time: Remove license boilerplate 2018-11-23 11:51:21 +01:00
clockevents.c hrtimers/tick/clockevents: Remove sloppy license references 2018-11-23 11:51:21 +01:00
clocksource.c time: Remove license boilerplate 2018-11-23 11:51:21 +01:00
hrtimer.c hrtimers/tick/clockevents: Remove sloppy license references 2018-11-23 11:51:21 +01:00
itimer.c time: Remove useless filenames in top level comments 2018-11-23 11:51:20 +01:00
jiffies.c time: Remove license boilerplate 2018-11-23 11:51:21 +01:00
Kconfig clocksource: Provide clocksource_arch_init() 2018-10-04 23:00:24 +02:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
ntp_internal.h timex: use __kernel_timex internally 2019-02-07 00:13:27 +01:00
ntp.c timex: use __kernel_timex internally 2019-02-07 00:13:27 +01:00
posix-clock.c timex: use __kernel_timex internally 2019-02-07 00:13:27 +01:00
posix-cpu-timers.c posix-cpu-timers: Remove useless call to check_dl_overrun() 2018-11-08 07:43:35 +01:00
posix-stubs.c posix-timers/stubs: Remove license boilerplate 2018-11-23 11:51:21 +01:00
posix-timers.c timex: use __kernel_timex internally 2019-02-07 00:13:27 +01:00
posix-timers.h timex: use __kernel_timex internally 2019-02-07 00:13:27 +01:00
sched_clock.c sched/clock: Remove license boilerplate 2018-11-23 11:51:22 +01:00
test_udelay.c time/debug: Remove license boilerplate 2018-11-23 11:51:21 +01:00
tick-broadcast-hrtimer.c time: Remove useless filenames in top level comments 2018-11-23 11:51:20 +01:00
tick-broadcast.c hrtimers/tick/clockevents: Remove sloppy license references 2018-11-23 11:51:21 +01:00
tick-common.c hrtimers/tick/clockevents: Remove sloppy license references 2018-11-23 11:51:21 +01:00
tick-internal.h Revert: Unify CLOCK_MONOTONIC and CLOCK_BOOTTIME 2018-04-26 14:53:32 +02:00
tick-oneshot.c hrtimers/tick/clockevents: Remove sloppy license references 2018-11-23 11:51:21 +01:00
tick-sched.c hrtimers/tick/clockevents: Remove sloppy license references 2018-11-23 11:51:21 +01:00
tick-sched.h nohz: Gather tick_sched booleans under a common flag field 2018-04-09 11:54:57 +02:00
time.c timex: use __kernel_timex internally 2019-02-07 00:13:27 +01:00
timeconst.bc time: Add SPDX license identifiers 2018-11-23 11:51:20 +01:00
timeconv.c time: Add SPDX license identifiers 2018-11-23 11:51:20 +01:00
timecounter.c time: Remove license boilerplate 2018-11-23 11:51:21 +01:00
timekeeping_debug.c timekeeping: Convert to DEFINE_SHOW_ATTRIBUTE 2018-12-11 18:13:35 -08:00
timekeeping_internal.h timekeeping/ntp: Constify some function arguments 2018-07-19 17:08:05 -07:00
timekeeping.c timex: use __kernel_timex internally 2019-02-07 00:13:27 +01:00
timekeeping.h Revert: Unify CLOCK_MONOTONIC and CLOCK_BOOTTIME 2018-04-26 14:53:32 +02:00
timer_list.c hrtimers/tick/clockevents: Remove sloppy license references 2018-11-23 11:51:21 +01:00
timer.c time: Add SPDX license identifiers 2018-11-23 11:51:20 +01:00