aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorArnd Bergmann <[email protected]>2017-10-19 14:29:04 +0200
committerJames Morris <[email protected]>2017-10-21 06:21:06 +0400
commit927340926ed61477e34f960eec64b7532e35d2f0 (patch)
tree8e48e194ded6863826462df91a837925bca559df /tools/perf/scripts/python
parentdbbbe1105ea6aa0c49d78a4ea0d924e0c02307eb (diff)
tomoyo: fix timestamping for y2038
Tomoyo uses an open-coded version of time_to_tm() to create a timestamp from the current time as read by get_seconds(). This will overflow and give wrong results on 32-bit systems in 2038. To correct this, this changes the code to use ktime_get_real_seconds() and the generic time64_to_tm() function that are both y2038-safe. Using the library function avoids adding an expensive 64-bit division in this code and can benefit from any optimizations we do in common code. Acked-by: Tetsuo Handa <[email protected]> Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: James Morris <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions