Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 140630
b: refs/heads/master
c: 6f3b344
h: refs/heads/master
v: v3
  • Loading branch information
Lai Jiangshan authored and Ingo Molnar committed Jan 15, 2009
1 parent 0e595a0 commit e5f3107
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 428aee1460a75197f0190534b4d610450ee59af1
refs/heads/master: 6f3b34402e7282cde49dff395d7ea462bf33bf50
10 changes: 5 additions & 5 deletions trunk/kernel/trace/ring_buffer.c
Original file line number Diff line number Diff line change
Expand Up @@ -1017,12 +1017,8 @@ __rb_reserve_next(struct ring_buffer_per_cpu *cpu_buffer,
}

if (next_page == head_page) {
if (!(buffer->flags & RB_FL_OVERWRITE)) {
/* reset write */
if (tail <= BUF_PAGE_SIZE)
local_set(&tail_page->write, tail);
if (!(buffer->flags & RB_FL_OVERWRITE))
goto out_unlock;
}

/* tail_page has not moved yet? */
if (tail_page == cpu_buffer->tail_page) {
Expand Down Expand Up @@ -1097,6 +1093,10 @@ __rb_reserve_next(struct ring_buffer_per_cpu *cpu_buffer,
return event;

out_unlock:
/* reset write */
if (tail <= BUF_PAGE_SIZE)
local_set(&tail_page->write, tail);

__raw_spin_unlock(&cpu_buffer->lock);
local_irq_restore(flags);
return NULL;
Expand Down

0 comments on commit e5f3107

Please sign in to comment.