diff options
author | Steven Rostedt (Red Hat) <rostedt@goodmis.org> | 2014-07-24 01:45:12 +0200 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2014-07-24 01:45:12 +0200 |
commit | 10e83fd01ccbb7122ad2c9dce68fb01bebb3fc46 (patch) | |
tree | 0643420cd3f825c33a3802113a6fe635e4b090b2 /kernel/trace | |
parent | ftrace: Rename ftrace_ops field from trampolines to nr_trampolines (diff) | |
download | linux-10e83fd01ccbb7122ad2c9dce68fb01bebb3fc46.tar.xz linux-10e83fd01ccbb7122ad2c9dce68fb01bebb3fc46.zip |
ring-buffer: Use rb_page_size() instead of open coded head_page size
There's a helper function to get a ring buffer page size (the number
of bytes of data recorded on the page), called rb_page_size().
Use that instead of open coding it.
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace')
-rw-r--r-- | kernel/trace/ring_buffer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c index 35825a87d6a3..d8c267ec5cca 100644 --- a/kernel/trace/ring_buffer.c +++ b/kernel/trace/ring_buffer.c @@ -3763,7 +3763,7 @@ rb_iter_peek(struct ring_buffer_iter *iter, u64 *ts) if (rb_per_cpu_empty(cpu_buffer)) return NULL; - if (iter->head >= local_read(&iter->head_page->page->commit)) { + if (iter->head >= rb_page_size(iter->head_page)) { rb_inc_iter(iter); goto again; } |