From: "Frank Ch. Eigler" <fche@redhat.com>
To: Jean Pihet <jean.pihet@newoldbits.com>
Cc: linux-trace-users@vger.kernel.org,
linux-pm@lists.linux-foundation.org,
linux-perf-users@vger.kernel.org, mingo@elte.hu,
arjan@linux.intel.com, rjw@sisk.pl, linux-omap@vger.kernel.org,
Thomas Renninger <trenn@suse.de>,
Peter Zijlstra <peterz@infradead.org>,
Kevin Hilman <khilman@deeprootsystems.com>,
Steven Rostedt <rostedt@goodmis.org>,
mathieu.desnoyers@efficios.com, Jean Pihet <j-pihet@ti.com>
Subject: Re: [PATCH 4/4] perf: provide a DEPRECTAED power trace API to user space
Date: Mon, 4 Oct 2010 12:10:51 -0400 [thread overview]
Message-ID: <20101004161051.GF16489@redhat.com> (raw)
In-Reply-To: <1286205661-24448-5-git-send-email-jean.pihet@newoldbits.com>
Hi -
> Provide a CONFIG_DEPRECATED_POWER_EVENT_TRACING option in order
> to provide backward compatibility with the user space tracing tools.
This is clever:
> +/* Map new events trace points calls to old ones */
> +#define trace_processor_idle(state, cpu_id) \
> + do { \
> + if (state != 0) \
> + trace_power_start(POWER_CSTATE, state, cpu_id); \
> + else \
> + trace_power_end(cpu_id); \
> + } while (0)
but with this code, are the new tracepoints firing at all? In other
words, does this backward-compatibility config option effectively
disable the newer ones? If so, this is probably avoidable.
Instead of redirecting the new tracepoint calls to these macros, an
alternative may intercept (un)registration for the old tracepoint
names, and map them to (un)registration of the real tracepoints. See
how syscall tracepoints map to a special (un)registration callback in
include/trace/events/syscalls.h (syscall_*regfunc). Instead of
setting a TIF flag, the new functions can call
register_processor_idle() et al., and their respective callbacks can
call the backward-compatibility tracepoints.
The starting point would be to recast the power_start, power_end,
power_frequency tracepoints via TRACE_EVENT_FN() instead of
TRACE_EVENT().
- FChE
next prev parent reply other threads:[~2010-10-04 16:11 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-04 15:20 PATCH [0/4] perf: clean-up of power events API Jean Pihet
2010-10-04 15:20 ` [PATCH 1/4] perf: cleanup " Jean Pihet
2010-10-04 15:20 ` [PATCH 2/4] perf: add OMAP support for the new power events Jean Pihet
2010-10-04 19:45 ` Thomas Renninger
2010-10-04 15:21 ` [PATCH 3/4] perf: add calls to suspend trace point Jean Pihet
2010-10-04 22:52 ` Rafael J. Wysocki
2010-10-04 15:21 ` [PATCH 4/4] perf: provide a DEPRECTAED power trace API to user space Jean Pihet
2010-10-04 16:10 ` Frank Ch. Eigler [this message]
2010-10-04 16:47 ` Jean Pihet
2010-10-06 21:34 ` PATCH [0/4] perf: clean-up of power events API Thomas Renninger
2010-10-07 15:08 ` Mathieu Desnoyers
2010-10-07 15:23 ` Pierre Tardy
2010-10-07 15:45 ` Steven Rostedt
2010-10-07 15:58 ` Frederic Weisbecker
2010-10-07 16:10 ` Pierre Tardy
2010-10-08 8:14 ` Tejun Heo
2010-10-08 8:38 ` Ingo Molnar
2010-10-08 13:17 ` Arjan van de Ven
2010-10-08 13:41 ` Mathieu Desnoyers
2010-10-08 16:22 ` Arjan van de Ven
2010-10-08 17:21 ` Steven Rostedt
2010-10-08 17:49 ` Frank Ch. Eigler
2010-10-08 18:11 ` Steven Rostedt
2010-10-08 17:32 ` Mathieu Desnoyers
2010-10-09 6:28 ` Ingo Molnar
2010-10-09 8:14 ` Pierre Tardy
2010-10-09 18:36 ` Linus Torvalds
2010-10-09 21:15 ` Steven Rostedt
2010-10-09 23:20 ` Linus Torvalds
2010-10-10 1:39 ` Steven Rostedt
2010-10-10 6:41 ` Peter Zijlstra
2010-10-10 15:11 ` Steven Rostedt
2010-10-18 12:15 ` Jean Pihet
2010-10-09 16:19 ` Arjan van de Ven
2010-10-09 21:34 ` Steven Rostedt
2010-10-10 12:19 ` Ingo Molnar
2010-10-19 11:31 ` Thomas Renninger
2010-10-19 11:45 ` Ingo Molnar
2010-10-19 11:47 ` Peter Zijlstra
2010-10-19 11:52 ` Ingo Molnar
2010-10-19 13:27 ` Arjan van de Ven
2010-10-19 13:50 ` Ingo Molnar
2010-10-19 13:52 ` Arjan van de Ven
2010-10-19 14:51 ` Ingo Molnar
2010-10-07 15:45 ` Jean Pihet
2010-10-07 15:49 ` Thomas Renninger
2010-10-07 15:56 ` Jean Pihet
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20101004161051.GF16489@redhat.com \
--to=fche@redhat.com \
--cc=arjan@linux.intel.com \
--cc=j-pihet@ti.com \
--cc=jean.pihet@newoldbits.com \
--cc=khilman@deeprootsystems.com \
--cc=linux-omap@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=linux-pm@lists.linux-foundation.org \
--cc=linux-trace-users@vger.kernel.org \
--cc=mathieu.desnoyers@efficios.com \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
--cc=rjw@sisk.pl \
--cc=rostedt@goodmis.org \
--cc=trenn@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox