All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/7] git pull request for tip/tracing/ftace
@ 2009-02-10 17:35 Steven Rostedt
  2009-02-10 17:35 ` [PATCH 1/7] ring_buffer: fix typing mistake Steven Rostedt
                   ` (7 more replies)
  0 siblings, 8 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel; +Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker

Ingo,

The following is based off of tip/tracing/ftrace.

-- Steve


The following patches are in:

  git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-2.6-trace.git

    branch: tip/tracing/ftrace


Lai Jiangshan (2):
      ring_buffer: fix typing mistake
      ring_buffer: fix ring_buffer_read_page()

Steven Rostedt (1):
      tracing, x86: fix constraint for parent variable

Tobias Klauser (1):
      tracing: storage class should be before const qualifier

Wenji Huang (3):
      tracing: remove unneeded variable
      tracing: provide correct return value after outputting the event
      tracing: fix typos in comments

----
 arch/x86/kernel/ftrace.c             |    9 +++---
 include/linux/ring_buffer.h          |    2 +-
 kernel/trace/ring_buffer.c           |   46 +++++++++++++++++++--------------
 kernel/trace/trace.c                 |    2 +-
 kernel/trace/trace_branch.c          |    4 +--
 kernel/trace/trace_functions_graph.c |   14 +++++-----
 kernel/trace/trace_hw_branches.c     |    2 +-
 kernel/trace/trace_sysprof.c         |    2 +-
 8 files changed, 42 insertions(+), 39 deletions(-)

-- 

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH 1/7] ring_buffer: fix typing mistake
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
@ 2009-02-10 17:35 ` Steven Rostedt
  2009-02-10 17:35 ` [PATCH 2/7] ring_buffer: fix ring_buffer_read_page() Steven Rostedt
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Lai Jiangshan,
	Steven Rostedt

[-- Attachment #1: 0001-ring_buffer-fix-typing-mistake.patch --]
[-- Type: text/plain, Size: 2169 bytes --]

From: Lai Jiangshan <laijs@cn.fujitsu.com>

Impact: Fix bug

I found several very very curious line.
It's so curious that it may be brought by typing mistake.

When (cpu_buffer->reader_page == cpu_buffer->commit_page):

1) We haven't copied it for bpage is changed:
   bpage = cpu_buffer->reader_page->page;
   memcpy(bpage->data, cpu_buffer->reader_page->page->data + read ... )
2) We need update cpu_buffer->reader_page->read, but
   "cpu_buffer->reader_page += read;" is not right.

[
  This bug was a typo. The commit->reader_page is a page pointer
  and not an index into the page. The line should have been
  commit->reader_page->read += read.  The other changes
  by Lai are nice clean ups to the code.  - SDR
]

Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
 kernel/trace/ring_buffer.c |    9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c
index 53ba3a6..eca2827 100644
--- a/kernel/trace/ring_buffer.c
+++ b/kernel/trace/ring_buffer.c
@@ -2406,7 +2406,7 @@ void ring_buffer_free_read_page(struct ring_buffer *buffer, void *data)
  * to swap with a page in the ring buffer.
  *
  * for example:
- *	rpage = ring_buffer_alloc_page(buffer);
+ *	rpage = ring_buffer_alloc_read_page(buffer);
  *	if (!rpage)
  *		return error;
  *	ret = ring_buffer_read_page(buffer, &rpage, cpu, 0);
@@ -2461,18 +2461,17 @@ int ring_buffer_read_page(struct ring_buffer *buffer,
 	 */
 	if (cpu_buffer->reader_page == cpu_buffer->commit_page) {
 		unsigned int read = cpu_buffer->reader_page->read;
+		unsigned int commit = rb_page_commit(cpu_buffer->reader_page);
 
 		if (full)
 			goto out;
 		/* The writer is still on the reader page, we must copy */
-		bpage = cpu_buffer->reader_page->page;
 		memcpy(bpage->data,
 		       cpu_buffer->reader_page->page->data + read,
-		       local_read(&bpage->commit) - read);
+		       commit - read);
 
 		/* consume what was read */
-		cpu_buffer->reader_page += read;
-
+		cpu_buffer->reader_page->read = commit;
 	} else {
 		/* swap the pages */
 		rb_init_page(bpage);
-- 
1.5.6.5

-- 

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 2/7] ring_buffer: fix ring_buffer_read_page()
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
  2009-02-10 17:35 ` [PATCH 1/7] ring_buffer: fix typing mistake Steven Rostedt
@ 2009-02-10 17:35 ` Steven Rostedt
  2009-02-10 17:35 ` [PATCH 3/7] tracing, x86: fix constraint for parent variable Steven Rostedt
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Lai Jiangshan,
	Steven Rostedt

[-- Attachment #1: 0002-ring_buffer-fix-ring_buffer_read_page.patch --]
[-- Type: text/plain, Size: 4034 bytes --]

From: Lai Jiangshan <laijs@cn.fujitsu.com>

Impact: change API and init bpage when copy

ring_buffer_read_page()/rb_remove_entries() may be called for
a partially consumed page.

Add a parameter for rb_remove_entries() and make it update
cpu_buffer->entries correctly for partially consumed pages.

ring_buffer_read_page() now returns the offset to the next event.

Init the bpage's time_stamp when return value is 0.

Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
 kernel/trace/ring_buffer.c |   33 ++++++++++++++++++++-------------
 1 files changed, 20 insertions(+), 13 deletions(-)

diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c
index eca2827..10d202e 100644
--- a/kernel/trace/ring_buffer.c
+++ b/kernel/trace/ring_buffer.c
@@ -2332,13 +2332,14 @@ int ring_buffer_swap_cpu(struct ring_buffer *buffer_a,
 EXPORT_SYMBOL_GPL(ring_buffer_swap_cpu);
 
 static void rb_remove_entries(struct ring_buffer_per_cpu *cpu_buffer,
-			      struct buffer_data_page *bpage)
+			      struct buffer_data_page *bpage,
+			      unsigned int offset)
 {
 	struct ring_buffer_event *event;
 	unsigned long head;
 
 	__raw_spin_lock(&cpu_buffer->lock);
-	for (head = 0; head < local_read(&bpage->commit);
+	for (head = offset; head < local_read(&bpage->commit);
 	     head += rb_event_length(event)) {
 
 		event = __rb_data_page_index(bpage, head);
@@ -2410,8 +2411,8 @@ void ring_buffer_free_read_page(struct ring_buffer *buffer, void *data)
  *	if (!rpage)
  *		return error;
  *	ret = ring_buffer_read_page(buffer, &rpage, cpu, 0);
- *	if (ret)
- *		process_page(rpage);
+ *	if (ret >= 0)
+ *		process_page(rpage, ret);
  *
  * When @full is set, the function will not return true unless
  * the writer is off the reader page.
@@ -2422,8 +2423,8 @@ void ring_buffer_free_read_page(struct ring_buffer *buffer, void *data)
  *  responsible for that.
  *
  * Returns:
- *  1 if data has been transferred
- *  0 if no data has been transferred.
+ *  >=0 if data has been transferred, returns the offset of consumed data.
+ *  <0 if no data has been transferred.
  */
 int ring_buffer_read_page(struct ring_buffer *buffer,
 			    void **data_page, int cpu, int full)
@@ -2432,7 +2433,8 @@ int ring_buffer_read_page(struct ring_buffer *buffer,
 	struct ring_buffer_event *event;
 	struct buffer_data_page *bpage;
 	unsigned long flags;
-	int ret = 0;
+	unsigned int read;
+	int ret = -1;
 
 	if (!data_page)
 		return 0;
@@ -2454,24 +2456,29 @@ int ring_buffer_read_page(struct ring_buffer *buffer,
 	/* check for data */
 	if (!local_read(&cpu_buffer->reader_page->page->commit))
 		goto out;
+
+	read = cpu_buffer->reader_page->read;
 	/*
 	 * If the writer is already off of the read page, then simply
 	 * switch the read page with the given page. Otherwise
 	 * we need to copy the data from the reader to the writer.
 	 */
 	if (cpu_buffer->reader_page == cpu_buffer->commit_page) {
-		unsigned int read = cpu_buffer->reader_page->read;
 		unsigned int commit = rb_page_commit(cpu_buffer->reader_page);
+		struct buffer_data_page *rpage = cpu_buffer->reader_page->page;
 
 		if (full)
 			goto out;
 		/* The writer is still on the reader page, we must copy */
-		memcpy(bpage->data,
-		       cpu_buffer->reader_page->page->data + read,
-		       commit - read);
+		memcpy(bpage->data + read, rpage->data + read, commit - read);
 
 		/* consume what was read */
 		cpu_buffer->reader_page->read = commit;
+
+		/* update bpage */
+		local_set(&bpage->commit, commit);
+		if (!read)
+			bpage->time_stamp = rpage->time_stamp;
 	} else {
 		/* swap the pages */
 		rb_init_page(bpage);
@@ -2480,10 +2487,10 @@ int ring_buffer_read_page(struct ring_buffer *buffer,
 		cpu_buffer->reader_page->read = 0;
 		*data_page = bpage;
 	}
-	ret = 1;
+	ret = read;
 
 	/* update the entry counter */
-	rb_remove_entries(cpu_buffer, bpage);
+	rb_remove_entries(cpu_buffer, bpage, read);
  out:
 	spin_unlock_irqrestore(&cpu_buffer->reader_lock, flags);
 
-- 
1.5.6.5

-- 

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 3/7] tracing, x86: fix constraint for parent variable
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
  2009-02-10 17:35 ` [PATCH 1/7] ring_buffer: fix typing mistake Steven Rostedt
  2009-02-10 17:35 ` [PATCH 2/7] ring_buffer: fix ring_buffer_read_page() Steven Rostedt
@ 2009-02-10 17:35 ` Steven Rostedt
  2009-02-10 17:35 ` [PATCH 4/7] tracing: storage class should be before const qualifier Steven Rostedt
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Steven Rostedt

[-- Attachment #1: 0003-tracing-x86-fix-constraint-for-parent-variable.patch --]
[-- Type: text/plain, Size: 1533 bytes --]

From: Steven Rostedt <srostedt@redhat.com>

The constraint used for retrieving and restoring the parent function
pointer is incorrect. The parent variable is a pointer, and the
address of the pointer is modified by the asm statement and not
the pointer itself. It is incorrect to pass it in as an output
constraint since the asm will never update the pointer.

Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
 arch/x86/kernel/ftrace.c |    9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/arch/x86/kernel/ftrace.c b/arch/x86/kernel/ftrace.c
index 18828ae..370bafa 100644
--- a/arch/x86/kernel/ftrace.c
+++ b/arch/x86/kernel/ftrace.c
@@ -468,8 +468,8 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
 	 * ignore such a protection.
 	 */
 	asm volatile(
-		"1: " _ASM_MOV " (%[parent_old]), %[old]\n"
-		"2: " _ASM_MOV " %[return_hooker], (%[parent_replaced])\n"
+		"1: " _ASM_MOV " (%[parent]), %[old]\n"
+		"2: " _ASM_MOV " %[return_hooker], (%[parent])\n"
 		"   movl $0, %[faulted]\n"
 
 		".section .fixup, \"ax\"\n"
@@ -479,9 +479,8 @@ void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
 		_ASM_EXTABLE(1b, 3b)
 		_ASM_EXTABLE(2b, 3b)
 
-		: [parent_replaced] "=r" (parent), [old] "=r" (old),
-		  [faulted] "=r" (faulted)
-		: [parent_old] "0" (parent), [return_hooker] "r" (return_hooker)
+		: [old] "=r" (old), [faulted] "=r" (faulted)
+		: [parent] "r" (parent), [return_hooker] "r" (return_hooker)
 		: "memory"
 	);
 
-- 
1.5.6.5

-- 

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 4/7] tracing: storage class should be before const qualifier
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
                   ` (2 preceding siblings ...)
  2009-02-10 17:35 ` [PATCH 3/7] tracing, x86: fix constraint for parent variable Steven Rostedt
@ 2009-02-10 17:35 ` Steven Rostedt
  2009-02-10 17:35 ` [PATCH 5/7] tracing: remove unneeded variable Steven Rostedt
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Tobias Klauser,
	Steven Rostedt

[-- Attachment #1: 0004-tracing-storage-class-should-be-before-const-qualif.patch --]
[-- Type: text/plain, Size: 949 bytes --]

From: Tobias Klauser <tklauser@distanz.ch>

The C99 specification states in section 6.11.5:

The placement of a storage-class specifier other than at the beginning
of the declaration specifiers in a declaration is an obsolescent
feature.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
 kernel/trace/trace_sysprof.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/trace/trace_sysprof.c b/kernel/trace/trace_sysprof.c
index 84ca9d8..4e2de4d 100644
--- a/kernel/trace/trace_sysprof.c
+++ b/kernel/trace/trace_sysprof.c
@@ -88,7 +88,7 @@ static void backtrace_address(void *data, unsigned long addr, int reliable)
 	}
 }
 
-const static struct stacktrace_ops backtrace_ops = {
+static const struct stacktrace_ops backtrace_ops = {
 	.warning		= backtrace_warning,
 	.warning_symbol		= backtrace_warning_symbol,
 	.stack			= backtrace_stack,
-- 
1.5.6.5

-- 

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 5/7] tracing: remove unneeded variable
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
                   ` (3 preceding siblings ...)
  2009-02-10 17:35 ` [PATCH 4/7] tracing: storage class should be before const qualifier Steven Rostedt
@ 2009-02-10 17:35 ` Steven Rostedt
  2009-02-10 17:35 ` [PATCH 6/7] tracing: provide correct return value after outputting the event Steven Rostedt
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Wenji Huang,
	Steven Rostedt

[-- Attachment #1: 0005-tracing-remove-unneeded-variable.patch --]
[-- Type: text/plain, Size: 926 bytes --]

From: Wenji Huang <wenji.huang@oracle.com>

Impact: clean up.

Remove the unnecessary variable ret.

Signed-off-by: Wenji Huang <wenji.huang@oracle.com>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
 kernel/trace/trace_branch.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/kernel/trace/trace_branch.c b/kernel/trace/trace_branch.c
index f8ae2c5..c2e68d4 100644
--- a/kernel/trace/trace_branch.c
+++ b/kernel/trace/trace_branch.c
@@ -91,8 +91,6 @@ void trace_likely_condition(struct ftrace_branch_data *f, int val, int expect)
 
 int enable_branch_tracing(struct trace_array *tr)
 {
-	int ret = 0;
-
 	mutex_lock(&branch_tracing_mutex);
 	branch_tracer = tr;
 	/*
@@ -103,7 +101,7 @@ int enable_branch_tracing(struct trace_array *tr)
 	branch_tracing_enabled++;
 	mutex_unlock(&branch_tracing_mutex);
 
-	return ret;
+	return 0;
 }
 
 void disable_branch_tracing(void)
-- 
1.5.6.5

-- 

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 6/7] tracing: provide correct return value after outputting the event
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
                   ` (4 preceding siblings ...)
  2009-02-10 17:35 ` [PATCH 5/7] tracing: remove unneeded variable Steven Rostedt
@ 2009-02-10 17:35 ` Steven Rostedt
  2009-02-10 17:35 ` [PATCH 7/7] tracing: fix typos in comments Steven Rostedt
  2009-02-11  9:10 ` [PATCH 0/7] git pull request for tip/tracing/ftace Ingo Molnar
  7 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Wenji Huang,
	Steven Rostedt

[-- Attachment #1: 0006-tracing-provide-correct-return-value-after-outputti.patch --]
[-- Type: text/plain, Size: 1620 bytes --]

From: Wenji Huang <wenji.huang@oracle.com>

This patch is to make the function return early on failure, and give
correct return value on success.

Signed-off-by: Wenji Huang <wenji.huang@oracle.com>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
 kernel/trace/trace_functions_graph.c |   14 +++++++-------
 1 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/kernel/trace/trace_functions_graph.c b/kernel/trace/trace_functions_graph.c
index 782ec0f..519a0ca 100644
--- a/kernel/trace/trace_functions_graph.c
+++ b/kernel/trace/trace_functions_graph.c
@@ -186,30 +186,30 @@ verif_pid(struct trace_seq *s, pid_t pid, int cpu, pid_t *last_pids_cpu)
 	ret = trace_seq_printf(s,
 		" ------------------------------------------\n");
 	if (!ret)
-		TRACE_TYPE_PARTIAL_LINE;
+		return TRACE_TYPE_PARTIAL_LINE;
 
 	ret = print_graph_cpu(s, cpu);
 	if (ret == TRACE_TYPE_PARTIAL_LINE)
-		TRACE_TYPE_PARTIAL_LINE;
+		return TRACE_TYPE_PARTIAL_LINE;
 
 	ret = print_graph_proc(s, prev_pid);
 	if (ret == TRACE_TYPE_PARTIAL_LINE)
-		TRACE_TYPE_PARTIAL_LINE;
+		return TRACE_TYPE_PARTIAL_LINE;
 
 	ret = trace_seq_printf(s, " => ");
 	if (!ret)
-		TRACE_TYPE_PARTIAL_LINE;
+		return TRACE_TYPE_PARTIAL_LINE;
 
 	ret = print_graph_proc(s, pid);
 	if (ret == TRACE_TYPE_PARTIAL_LINE)
-		TRACE_TYPE_PARTIAL_LINE;
+		return TRACE_TYPE_PARTIAL_LINE;
 
 	ret = trace_seq_printf(s,
 		"\n ------------------------------------------\n\n");
 	if (!ret)
-		TRACE_TYPE_PARTIAL_LINE;
+		return TRACE_TYPE_PARTIAL_LINE;
 
-	return ret;
+	return TRACE_TYPE_HANDLED;
 }
 
 static struct ftrace_graph_ret_entry *
-- 
1.5.6.5

-- 

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 7/7] tracing: fix typos in comments
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
                   ` (5 preceding siblings ...)
  2009-02-10 17:35 ` [PATCH 6/7] tracing: provide correct return value after outputting the event Steven Rostedt
@ 2009-02-10 17:35 ` Steven Rostedt
  2009-02-11  9:10 ` [PATCH 0/7] git pull request for tip/tracing/ftace Ingo Molnar
  7 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-10 17:35 UTC (permalink / raw)
  To: linux-kernel
  Cc: Ingo Molnar, Andrew Morton, Frederic Weisbecker, Wenji Huang,
	Steven Rostedt

[-- Attachment #1: 0007-tracing-fix-typos-in-comments.patch --]
[-- Type: text/plain, Size: 3226 bytes --]

From: Wenji Huang <wenji.huang@oracle.com>

Impact: clean up.

Fix typos in the comments.

Signed-off-by: Wenji Huang <wenji.huang@oracle.com>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
---
 include/linux/ring_buffer.h      |    2 +-
 kernel/trace/ring_buffer.c       |    8 ++++----
 kernel/trace/trace.c             |    2 +-
 kernel/trace/trace_hw_branches.c |    2 +-
 4 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/include/linux/ring_buffer.h b/include/linux/ring_buffer.h
index 3c103d6..8e6646a 100644
--- a/include/linux/ring_buffer.h
+++ b/include/linux/ring_buffer.h
@@ -8,7 +8,7 @@ struct ring_buffer;
 struct ring_buffer_iter;
 
 /*
- * Don't reference this struct directly, use functions below.
+ * Don't refer to this struct directly, use functions below.
  */
 struct ring_buffer_event {
 	u32		type:2, len:3, time_delta:27;
diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c
index 10d202e..fa64e1f 100644
--- a/kernel/trace/ring_buffer.c
+++ b/kernel/trace/ring_buffer.c
@@ -91,7 +91,7 @@ EXPORT_SYMBOL_GPL(tracing_off);
  * tracing_off_permanent - permanently disable ring buffers
  *
  * This function, once called, will disable all ring buffers
- * permanenty.
+ * permanently.
  */
 void tracing_off_permanent(void)
 {
@@ -210,7 +210,7 @@ EXPORT_SYMBOL_GPL(ring_buffer_event_data);
 
 struct buffer_data_page {
 	u64		 time_stamp;	/* page time stamp */
-	local_t		 commit;	/* write commited index */
+	local_t		 commit;	/* write committed index */
 	unsigned char	 data[];	/* data of buffer page */
 };
 
@@ -260,7 +260,7 @@ struct ring_buffer_per_cpu {
 	struct list_head		pages;
 	struct buffer_page		*head_page;	/* read from head */
 	struct buffer_page		*tail_page;	/* write to tail */
-	struct buffer_page		*commit_page;	/* commited pages */
+	struct buffer_page		*commit_page;	/* committed pages */
 	struct buffer_page		*reader_page;
 	unsigned long			overrun;
 	unsigned long			entries;
@@ -303,7 +303,7 @@ struct ring_buffer_iter {
  * check_pages - integrity check of buffer pages
  * @cpu_buffer: CPU buffer with pages to test
  *
- * As a safty measure we check to make sure the data pages have not
+ * As a safety measure we check to make sure the data pages have not
  * been corrupted.
  */
 static int rb_check_pages(struct ring_buffer_per_cpu *cpu_buffer)
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index d898212..d7c175a 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -1963,7 +1963,7 @@ tracing_trace_options_read(struct file *filp, char __user *ubuf,
 	struct tracer_opt *trace_opts = current_trace->flags->opts;
 
 
-	/* calulate max size */
+	/* calculate max size */
 	for (i = 0; trace_options[i]; i++) {
 		len += strlen(trace_options[i]);
 		len += 3; /* "no" and space */
diff --git a/kernel/trace/trace_hw_branches.c b/kernel/trace/trace_hw_branches.c
index e3e7db6..0794dd3 100644
--- a/kernel/trace/trace_hw_branches.c
+++ b/kernel/trace/trace_hw_branches.c
@@ -75,7 +75,7 @@ static void bts_trace_start(struct trace_array *tr)
 }
 
 /*
- * Start tracing on the current cpu.
+ * Stop tracing on the current cpu.
  * The argument is ignored.
  *
  * pre: bts_tracer_mutex must be locked.
-- 
1.5.6.5

-- 

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [PATCH 0/7] git pull request for tip/tracing/ftace
  2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
                   ` (6 preceding siblings ...)
  2009-02-10 17:35 ` [PATCH 7/7] tracing: fix typos in comments Steven Rostedt
@ 2009-02-11  9:10 ` Ingo Molnar
  2009-02-11 14:31   ` Steven Rostedt
  7 siblings, 1 reply; 10+ messages in thread
From: Ingo Molnar @ 2009-02-11  9:10 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: linux-kernel, Andrew Morton, Frederic Weisbecker


* Steven Rostedt <rostedt@goodmis.org> wrote:

> Ingo,
> 
> The following is based off of tip/tracing/ftrace.
> 
> -- Steve
> 
> 
> The following patches are in:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-2.6-trace.git
> 
>     branch: tip/tracing/ftrace
> 
> 
> Lai Jiangshan (2):
>       ring_buffer: fix typing mistake
>       ring_buffer: fix ring_buffer_read_page()
> 
> Steven Rostedt (1):
>       tracing, x86: fix constraint for parent variable
> 
> Tobias Klauser (1):
>       tracing: storage class should be before const qualifier
> 
> Wenji Huang (3):
>       tracing: remove unneeded variable
>       tracing: provide correct return value after outputting the event
>       tracing: fix typos in comments
> 
> ----
>  arch/x86/kernel/ftrace.c             |    9 +++---
>  include/linux/ring_buffer.h          |    2 +-
>  kernel/trace/ring_buffer.c           |   46 +++++++++++++++++++--------------
>  kernel/trace/trace.c                 |    2 +-
>  kernel/trace/trace_branch.c          |    4 +--
>  kernel/trace/trace_functions_graph.c |   14 +++++-----
>  kernel/trace/trace_hw_branches.c     |    2 +-
>  kernel/trace/trace_sysprof.c         |    2 +-
>  8 files changed, 42 insertions(+), 39 deletions(-)

Pulled into tip:tracing/ftrace, thanks Steve!

Note, i cherry-picked this fix into tip:tracing/urgent:

  9666578: tracing, x86: fix constraint for parent variable

As in theory GCC can miscompile the function-return-tracer, right?

	Ingo

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 0/7] git pull request for tip/tracing/ftace
  2009-02-11  9:10 ` [PATCH 0/7] git pull request for tip/tracing/ftace Ingo Molnar
@ 2009-02-11 14:31   ` Steven Rostedt
  0 siblings, 0 replies; 10+ messages in thread
From: Steven Rostedt @ 2009-02-11 14:31 UTC (permalink / raw)
  To: Ingo Molnar; +Cc: linux-kernel, Andrew Morton, Frederic Weisbecker


On Wed, 11 Feb 2009, Ingo Molnar wrote:
> Note, i cherry-picked this fix into tip:tracing/urgent:
> 
>   9666578: tracing, x86: fix constraint for parent variable
> 
> As in theory GCC can miscompile the function-return-tracer, right?

Yeah, I was thinking that, but I could not make it do so with the few 
test cases that I tried. But in theory, I guess it can.

-- Steve


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2009-02-11 14:31 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-10 17:35 [PATCH 0/7] git pull request for tip/tracing/ftace Steven Rostedt
2009-02-10 17:35 ` [PATCH 1/7] ring_buffer: fix typing mistake Steven Rostedt
2009-02-10 17:35 ` [PATCH 2/7] ring_buffer: fix ring_buffer_read_page() Steven Rostedt
2009-02-10 17:35 ` [PATCH 3/7] tracing, x86: fix constraint for parent variable Steven Rostedt
2009-02-10 17:35 ` [PATCH 4/7] tracing: storage class should be before const qualifier Steven Rostedt
2009-02-10 17:35 ` [PATCH 5/7] tracing: remove unneeded variable Steven Rostedt
2009-02-10 17:35 ` [PATCH 6/7] tracing: provide correct return value after outputting the event Steven Rostedt
2009-02-10 17:35 ` [PATCH 7/7] tracing: fix typos in comments Steven Rostedt
2009-02-11  9:10 ` [PATCH 0/7] git pull request for tip/tracing/ftace Ingo Molnar
2009-02-11 14:31   ` Steven Rostedt

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.