[lkml]   [2015]   [May]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC] x86, perf: Add an aperfmperf driver

* Andy Lutomirski <> wrote:

> + event->hw.idx = -1;
> + event->hw.event_base = (event->attr.config == APERFMPERF_EVENT_APERF ?

So instead of having a separate driver per MSR, I think it might be
more useful to have a generic 'MSR as counters' PMU driver, for such
really simple cases where MSR contents represent an interesting
hardware metric, and have a table that enumerates the MSRs we allow to
be measured, and a sysfs list of them, to allow easy discovery.

APERF/MPERF would be one such MSR, MSR_SMI_COUNT another one - but
there are also other interesting ones.

Some of these are per CPU, some are system wide. Such an approach
would be far more robust than tooling poking around in /dev/msr (!).



 \ /
  Last update: 2015-05-11 12:21    [W:0.095 / U:5.648 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site