lkml.org 
[lkml]   [2007]   [Nov]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[patch 3/3] Linux Kernel Markers - fix samples to follow format string standard
Add the field names to marker example format string.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
---
samples/markers/marker-example.c | 3 ++-
samples/markers/probe-example.c | 2 +-
2 files changed, 3 insertions(+), 2 deletions(-)

Index: linux-2.6-lttng/samples/markers/marker-example.c
===================================================================
--- linux-2.6-lttng.orig/samples/markers/marker-example.c 2007-11-03 20:56:35.000000000 -0400
+++ linux-2.6-lttng/samples/markers/marker-example.c 2007-11-03 20:57:08.000000000 -0400
@@ -19,7 +19,8 @@ static int my_open(struct inode *inode,
{
int i;

- trace_mark(subsystem_event, "%d %s", 123, "example string");
+ trace_mark(subsystem_event, "integer %d string %s", 123,
+ "example string");
for (i = 0; i < 10; i++)
trace_mark(subsystem_eventb, MARK_NOARGS);
return -EPERM;
Index: linux-2.6-lttng/samples/markers/probe-example.c
===================================================================
--- linux-2.6-lttng.orig/samples/markers/probe-example.c 2007-11-03 20:57:38.000000000 -0400
+++ linux-2.6-lttng/samples/markers/probe-example.c 2007-11-03 20:57:51.000000000 -0400
@@ -53,7 +53,7 @@ void probe_subsystem_eventb(const struct
static struct probe_data probe_array[] =
{
{ .name = "subsystem_event",
- .format = "%d %s",
+ .format = "integer %d string %s",
.probe_func = probe_subsystem_event },
{ .name = "subsystem_eventb",
.format = MARK_NOARGS,
--
Mathieu Desnoyers
Computer Engineering Ph.D. Student, Ecole Polytechnique de Montreal
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-11-13 19:47    [W:0.071 / U:0.236 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site