diff options
author | 2012-08-21 20:30:48 -0400 | |
---|---|---|
committer | 2012-08-22 10:42:13 +0200 | |
commit | 6ea565a9be32a3c8d1092017686f183b6d8c4514 (patch) | |
tree | 2db67e9659f91f11997998ba9845f4c7cb0d89ab /tools/perf/scripts/python/export-to-postgresql.py | |
parent | time: Fix casting issue in timekeeping_forward_now (diff) | |
download | linux-dev-6ea565a9be32a3c8d1092017686f183b6d8c4514.tar.xz linux-dev-6ea565a9be32a3c8d1092017686f183b6d8c4514.zip |
time: Avoid potential shift overflow with large shift values
Andreas Schwab noticed that the 1 << tk->shift could overflow if the
shift value was greater than 30, since 1 would be a 32bit long on
32bit architectures. This issue was introduced by 1e75fa8be (time:
Condense timekeeper.xtime into xtime_sec)
Use 1ULL instead to ensure we don't overflow on the shift.
Reported-by: Andreas Schwab <schwab@linux-m68k.org>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Cc: Prarit Bhargava <prarit@redhat.com>
Cc: Ingo Molnar <mingo@kernel.org>
Link: http://lkml.kernel.org/r/1345595449-34965-4-git-send-email-john.stultz@linaro.org
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions