aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/call-graph-from-postgresql.py
diff options
context:
space:
mode:
authorJohn Stultz <[email protected]>2015-09-09 16:07:30 -0700
committerIngo Molnar <[email protected]>2015-09-13 10:30:47 +0200
commit2619d7e9c92d524cb155ec89fd72875321512e5b (patch)
tree90ec69c5e8b7604b184fe385392a947e094781d3 /tools/perf/scripts/python/call-graph-from-postgresql.py
parent6ff33f3902c3b1c5d0db6b1e2c70b6d76fba357f (diff)
time: Fix timekeeping_freqadjust()'s incorrect use of abs() instead of abs64()
The internal clocksteering done for fine-grained error correction uses a logarithmic approximation, so any time adjtimex() adjusts the clock steering, timekeeping_freqadjust() quickly approximates the correct clock frequency over a series of ticks. Unfortunately, the logic in timekeeping_freqadjust(), introduced in commit: dc491596f639 ("timekeeping: Rework frequency adjustments to work better w/ nohz") used the abs() function with a s64 error value to calculate the size of the approximated adjustment to be made. Per include/linux/kernel.h: "abs() should not be used for 64-bit types (s64, u64, long long) - use abs64()". Thus on 32-bit platforms, this resulted in the clocksteering to take a quite dampended random walk trying to converge on the proper frequency, which caused the adjustments to be made much slower then intended (most easily observed when large adjustments are made). This patch fixes the issue by using abs64() instead. Reported-by: Nuno Gonçalves <[email protected]> Tested-by: Nuno Goncalves <[email protected]> Signed-off-by: John Stultz <[email protected]> Cc: <[email protected]> # v3.17+ Cc: Linus Torvalds <[email protected]> Cc: Miroslav Lichvar <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Prarit Bhargava <[email protected]> Cc: Richard Cochran <[email protected]> Cc: Thomas Gleixner <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Ingo Molnar <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions