From: "tip-bot for Steven Rostedt (Red Hat)" <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: jolsa@redhat.com, linux-kernel@vger.kernel.org,
akpm@linux-foundation.org, hpa@zytor.com, rostedt@goodmis.org,
mingo@kernel.org, namhyung@kernel.org, acme@redhat.com,
tglx@linutronix.de
Subject: [tip:perf/core] tools lib traceevent: Add way to find sub buffer boundary
Date: Tue, 24 Mar 2015 09:35:09 -0700 [thread overview]
Message-ID: <tip-82ac952be6348dc072dcfd80a2dcb511d0cd6bea@git.kernel.org> (raw)
In-Reply-To: <20150324135923.650983637@goodmis.org>
Commit-ID: 82ac952be6348dc072dcfd80a2dcb511d0cd6bea
Gitweb: http://git.kernel.org/tip/82ac952be6348dc072dcfd80a2dcb511d0cd6bea
Author: Steven Rostedt (Red Hat) <rostedt@goodmis.org>
AuthorDate: Tue, 24 Mar 2015 09:57:56 -0400
Committer: Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Tue, 24 Mar 2015 12:22:09 -0300
tools lib traceevent: Add way to find sub buffer boundary
For debugging purposes, it may be helpful for the kbuffer library to flag
when crossing a sub buffer.
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: http://lkml.kernel.org/r/20150324135923.650983637@goodmis.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/lib/traceevent/kbuffer-parse.c | 11 +++++++++++
tools/lib/traceevent/kbuffer.h | 1 +
2 files changed, 12 insertions(+)
diff --git a/tools/lib/traceevent/kbuffer-parse.c b/tools/lib/traceevent/kbuffer-parse.c
index deb3569..3bcada3 100644
--- a/tools/lib/traceevent/kbuffer-parse.c
+++ b/tools/lib/traceevent/kbuffer-parse.c
@@ -729,3 +729,14 @@ void kbuffer_set_old_format(struct kbuffer *kbuf)
kbuf->next_event = __old_next_event;
}
+
+/**
+ * kbuffer_start_of_data - return offset of where data starts on subbuffer
+ * @kbuf: The kbuffer
+ *
+ * Returns the location on the subbuffer where the data starts.
+ */
+int kbuffer_start_of_data(struct kbuffer *kbuf)
+{
+ return kbuf->start;
+}
diff --git a/tools/lib/traceevent/kbuffer.h b/tools/lib/traceevent/kbuffer.h
index c831f64..03dce75 100644
--- a/tools/lib/traceevent/kbuffer.h
+++ b/tools/lib/traceevent/kbuffer.h
@@ -63,5 +63,6 @@ int kbuffer_missed_events(struct kbuffer *kbuf);
int kbuffer_subbuffer_size(struct kbuffer *kbuf);
void kbuffer_set_old_format(struct kbuffer *kbuf);
+int kbuffer_start_of_data(struct kbuffer *kbuf);
#endif /* _K_BUFFER_H */
next prev parent reply other threads:[~2015-03-24 16:35 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-24 13:57 [PATCH 0/9] tools lib traceevent: Pulling in updates from trace-cmd Steven Rostedt
2015-03-24 13:57 ` [PATCH 1/9] tools lib traceevent: Handle NULL comm name Steven Rostedt
2015-03-24 16:33 ` [tip:perf/core] " tip-bot for Josef Bacik
2015-03-24 13:57 ` [PATCH 2/9] tools lib traceevent: Copy trace_clock and free it Steven Rostedt
2015-03-24 15:14 ` Arnaldo Carvalho de Melo
2015-03-24 15:43 ` Steven Rostedt
2015-03-24 16:33 ` [tip:perf/core] " tip-bot for Steven Rostedt (Red Hat)
2015-03-24 13:57 ` [PATCH 3/9] tools lib traceevent: Handle %z in bprint format Steven Rostedt
2015-03-24 16:33 ` [tip:perf/core] " tip-bot for Steven Rostedt (Red Hat)
2015-03-24 13:57 ` [PATCH 4/9] tools lib traceevent: Add pevent_data_pid_from_comm() Steven Rostedt
2015-03-24 15:16 ` Arnaldo Carvalho de Melo
2015-03-24 16:34 ` [tip:perf/core] " tip-bot for Steven Rostedt (Red Hat)
2015-03-24 13:57 ` [PATCH 5/9] tools lib traceevent: Fix whitespace error Steven Rostedt
2015-03-24 15:19 ` Arnaldo Carvalho de Melo
2015-03-24 15:37 ` Steven Rostedt
2015-03-24 13:57 ` [PATCH 6/9] tools lib traceevent: Make plugin options either string or boolean Steven Rostedt
2015-03-24 16:34 ` [tip:perf/core] " tip-bot for Steven Rostedt
2015-03-24 13:57 ` [PATCH 7/9] tools lib traceevent kbuffer: Remove extra update to data pointer in PADDING Steven Rostedt
2015-03-24 16:34 ` [tip:perf/core] " tip-bot for Steven Rostedt (Red Hat)
2015-03-24 13:57 ` [PATCH 8/9] tools lib traceevent: Add way to find sub buffer boundary Steven Rostedt
2015-03-24 16:35 ` tip-bot for Steven Rostedt (Red Hat) [this message]
2015-03-24 13:57 ` [PATCH 9/9] tools lib traceevent: Free filter tokens in process_filter() Steven Rostedt
2015-03-24 16:35 ` [tip:perf/core] " tip-bot for Steven Rostedt (Red Hat)
2015-03-24 14:57 ` [PATCH 0/9] tools lib traceevent: Pulling in updates from trace-cmd Arnaldo Carvalho de Melo
2015-03-24 15:04 ` Steven Rostedt
2015-03-24 15:25 ` Arnaldo Carvalho de Melo
2015-03-24 15:26 ` Arnaldo Carvalho de Melo
2015-03-24 15:44 ` Steven Rostedt
2015-03-24 15:45 ` Steven Rostedt
2015-03-24 15:51 ` Arnaldo Carvalho de Melo
2015-03-24 16:19 ` Steven Rostedt
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=tip-82ac952be6348dc072dcfd80a2dcb511d0cd6bea@git.kernel.org \
--to=tipbot@zytor.com \
--cc=acme@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=hpa@zytor.com \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung@kernel.org \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.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