From: Chunyan Zhang <zhang.chunyan@linaro.org>
To: rostedt@goodmis.org, mingo@redhat.com
Cc: mathieu.poirier@linaro.org, serge.broslavsky@linaro.org,
broonie@kernel.org, alexander.shishkin@linux.intel.com,
zhang.lyra@gmail.com, linux-kernel@vger.kernel.org
Subject: [RFC PATCH v3 0/4] Integration of trace events with System Trace IP blocks
Date: Tue, 7 Jul 2015 18:10:39 +0800 [thread overview]
Message-ID: <cover.1436262902.git.zhang.chunyan@linaro.org> (raw)
IP blocks allowing a variety of trace sources to log debugging
information to a pre-defined area have been introduced on a couple of
architecture [1][2]. These system trace blocks (also known as STM)
typically follow the MIPI STPv2 protocol [3] and provide a system wide
logging facility to any device, running a kernel or not, with access
to the block's log entry port(s). Since each trace message has a
timestamp is it possible to correlate events happening in the entire
system rather than being confined to the logging facility of a single
entity.
This patch is using a very simple "stm_source" introduced in [2] to
duplicate the output of the trace event subsystem to an STM, in this
case coresight STM. That way logging information generated by the
trace event subsystem and gathered in the coresight sink can be used
in conjunction with trace data from other board components, also
collected in the same trace sink. This example is using coresight but
the same would apply to any architecture wishing to do the same.
The goal of this RFC is to solicit comments on the method used to
connect trace event logging with STMs (using the generic STM API)
rather than function "stm_ftrace_write()" itself, which was provided
for completeness of the proof of concept only.
I'm eager to see your comments on this, and if you have some good
ideas that can slow down the overhead, please let me know. Any
questions are also welcome.
Thanks,
Chunyan
[1]. https://lkml.org/lkml/2015/2/4/729
[2]. http://comments.gmane.org/gmane.linux.kernel/1914526
[3]. http://mipi.org/specifications/debug#STP
Changes from RFC v2:
- Revised some types and variable's name according to the
code of v4.2-rc1
- Sorted this patch-set based on the v4.2-rc1
- Splited the patch 2/3 of my last patch-set to make code can
be compiled after each patch is applied in order.
Changes from RFC v1:
- Marked module init/exit functions with __init/__exit key word
according to the comments from Paul Bolle
Chunyan Zhang (3):
trace: Add an entry for printing trace log to STM
trace: Introduce trace log output function for STM
trace: Trace log handler for logging into STM blocks
Mathieu Poirier (1):
STM trace event: Adding generic buffer interface driver
drivers/stm/Kconfig | 11 +++++
drivers/stm/Makefile | 2 +
drivers/stm/stm_trace_event.c | 46 +++++++++++++++++++
include/linux/trace_events.h | 16 +++++++
include/trace/perf.h | 3 ++
include/trace/trace_events.h | 44 ++++++++++++++++++
kernel/trace/Makefile | 1 +
kernel/trace/trace_output_stm.c | 99 +++++++++++++++++++++++++++++++++++++++++
8 files changed, 222 insertions(+)
create mode 100644 drivers/stm/stm_trace_event.c
create mode 100644 kernel/trace/trace_output_stm.c
--
1.9.1
next reply other threads:[~2015-07-07 10:12 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-07 10:10 Chunyan Zhang [this message]
2015-07-07 10:10 ` [RFC PATCH v3 1/4] STM trace event: Adding generic buffer interface driver Chunyan Zhang
2015-07-08 10:23 ` Alexander Shishkin
2015-07-08 14:15 ` Mathieu Poirier
2015-07-08 12:10 ` Peter Zijlstra
2015-07-08 13:09 ` Alexander Shishkin
2015-07-07 10:10 ` [RFC PATCH v3 2/4] trace: Add an entry for printing trace log to STM Chunyan Zhang
2015-07-07 15:58 ` Steven Rostedt
2015-07-08 8:06 ` Chunyan Zhang
2015-07-07 10:10 ` [RFC PATCH v3 3/4] trace: Introduce trace log output function for STM Chunyan Zhang
2015-07-17 20:48 ` Steven Rostedt
2015-07-07 10:10 ` [RFC PATCH v3 4/4] trace: Trace log handler for logging into STM blocks Chunyan Zhang
2015-07-08 12:31 ` Peter Zijlstra
2015-07-08 13:06 ` Chunyan Zhang
2015-07-08 13:22 ` Ingo Molnar
2015-07-08 13:19 ` Steven Rostedt
2015-07-10 9:01 ` Chunyan Zhang
2015-07-17 5:59 ` Chunyan Zhang
2015-07-17 21:07 ` Steven Rostedt
2015-07-07 11:12 ` [RFC PATCH v3 0/4] Integration of trace events with System Trace IP blocks Alexander Shishkin
2015-07-08 7:42 ` Chunyan Zhang
2015-07-08 10:11 ` Alexander Shishkin
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=cover.1436262902.git.zhang.chunyan@linaro.org \
--to=zhang.chunyan@linaro.org \
--cc=alexander.shishkin@linux.intel.com \
--cc=broonie@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mathieu.poirier@linaro.org \
--cc=mingo@redhat.com \
--cc=rostedt@goodmis.org \
--cc=serge.broslavsky@linaro.org \
--cc=zhang.lyra@gmail.com \
/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