lkml.org 
[lkml]   [2015]   [Oct]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/1] perf/x86: Fix time_shift in perf_event_mmap_page

* Adrian Hunter <adrian.hunter@intel.com> wrote:

> Commit b20112edeadf ("perf/x86: Improve accuracy of perf/sched clock")
> allowed the time_shift value in perf_event_mmap_page to be as much
> as 32. Unfortunately the documented algorithms for using time_shift
> have it shifting an integer, whereas to work correctly with the value
> 32, the type must be u64.
>
> Fix by limiting the shift to 31 and adjusting the multiplier accordingly.
>
> Also update the documentation of perf_event_mmap_page so that new code
> based on it will be more future-proof.
>
> Fixes: b20112edeadf ("perf/x86: Improve accuracy of perf/sched clock")
> Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>

Would be nice to point out via what symptoms the code misbehaves and how users
notice.

Thanks,

Ingo


\
 
 \ /
  Last update: 2015-10-19 10:41    [W:0.090 / U:0.176 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site