lkml.org 
[lkml]   [2009]   [Jun]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] scripts/checksyscalls.sh: only whine perf_counter_open when supported
Ingo Molnar writes:

> PMU support is not required to get perfcounters support: if an
> architecture hooks up the syscall it will get generic software
> counters and the tools will work as well.

It looks to me that to work properly, each architecture has to provide
set_perf_counter_pending() and some way to arrange to call
perf_counter_do_pending() once interrupts get re-enabled. We need
this because some software counters (the context-switch counter at
least, as well as all the tracepoint counters) use nmi = 1 because
their events happen at times when we can't do a wakeup.

Actually, as far as the tracepoints are concerned, I can't see any
reason to be sure that interrupts will be disabled when a tracepoint
event occurs. On powerpc, calling set_perf_counter_pending() when
interrupts are enabled won't result in perf_counter_do_pending()
getting called right away; the perf_counter_do_pending() call won't
happen until something disables and re-enables interrupts.

Paul.


\
 
 \ /
  Last update: 2009-06-13 07:37    [W:0.142 / U:25.888 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site