summary refs log tree commit diff
path: root/arch
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2019-11-08 21:34:25 +0100
committerThomas Gleixner <tglx@linutronix.de>2019-11-12 08:15:15 +0100
commit20d087368d38c7350a4519a3b316ef7eb2504692 (patch)
tree100e400b1bbb4909ef54689ce1907ac6ecf4e59e /arch
parent56144737e67329c9aaed15f942d46a6302e2e3d8 (diff)
downloadlinux-20d087368d38c7350a4519a3b316ef7eb2504692.tar.gz
time: Optimize ns_to_timespec64()
ns_to_timespec64() calls div_s64_rem(), which is a rather slow function on
32-bit architectures, as it cannot take advantage of the do_div()
optimizations for constant arguments.

Open-code the div_s64_rem() function in ns_to_timespec64(), so a constant
divider can be passed into the optimized div_u64_rem() function.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/r/20191108203435.112759-3-arnd@arndb.de
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions