aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/oprofile/cpu_buffer.c
diff options
context:
space:
mode:
authorRobert Richter <robert.richter@amd.com>2008-10-16 09:01:40 -0400
committerRobert Richter <robert.richter@amd.com>2008-10-16 09:01:40 -0400
commit6a18037d4165f691063b43816be3152e9006eb06 (patch)
tree61e5dab681cd0544f61b6d5ffad4c6a0c0c2b1a1 /drivers/oprofile/cpu_buffer.c
parent5a289395bf753f8a318d3a5fa335a757c16c0183 (diff)
oprofile: fixing whitespaces in drivers/oprofile/*
Signed-off-by: Robert Richter <robert.richter@amd.com>
Diffstat (limited to 'drivers/oprofile/cpu_buffer.c')
-rw-r--r--drivers/oprofile/cpu_buffer.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/oprofile/cpu_buffer.c b/drivers/oprofile/cpu_buffer.c
index b47ce038490f..5a178065cfa0 100644
--- a/drivers/oprofile/cpu_buffer.c
+++ b/drivers/oprofile/cpu_buffer.c
@@ -22,7 +22,7 @@
22#include <linux/oprofile.h> 22#include <linux/oprofile.h>
23#include <linux/vmalloc.h> 23#include <linux/vmalloc.h>
24#include <linux/errno.h> 24#include <linux/errno.h>
25 25
26#include "event_buffer.h" 26#include "event_buffer.h"
27#include "cpu_buffer.h" 27#include "cpu_buffer.h"
28#include "buffer_sync.h" 28#include "buffer_sync.h"
@@ -38,7 +38,7 @@ static int work_enabled;
38void free_cpu_buffers(void) 38void free_cpu_buffers(void)
39{ 39{
40 int i; 40 int i;
41 41
42 for_each_online_cpu(i) { 42 for_each_online_cpu(i) {
43 vfree(per_cpu(cpu_buffer, i).buffer); 43 vfree(per_cpu(cpu_buffer, i).buffer);
44 per_cpu(cpu_buffer, i).buffer = NULL; 44 per_cpu(cpu_buffer, i).buffer = NULL;
@@ -48,17 +48,17 @@ void free_cpu_buffers(void)
48int alloc_cpu_buffers(void) 48int alloc_cpu_buffers(void)
49{ 49{
50 int i; 50 int i;
51 51
52 unsigned long buffer_size = fs_cpu_buffer_size; 52 unsigned long buffer_size = fs_cpu_buffer_size;
53 53
54 for_each_online_cpu(i) { 54 for_each_online_cpu(i) {
55 struct oprofile_cpu_buffer *b = &per_cpu(cpu_buffer, i); 55 struct oprofile_cpu_buffer *b = &per_cpu(cpu_buffer, i);
56 56
57 b->buffer = vmalloc_node(sizeof(struct op_sample) * buffer_size, 57 b->buffer = vmalloc_node(sizeof(struct op_sample) * buffer_size,
58 cpu_to_node(i)); 58 cpu_to_node(i));
59 if (!b->buffer) 59 if (!b->buffer)
60 goto fail; 60 goto fail;
61 61
62 b->last_task = NULL; 62 b->last_task = NULL;
63 b->last_is_kernel = -1; 63 b->last_is_kernel = -1;
64 b->tracing = 0; 64 b->tracing = 0;
@@ -150,7 +150,7 @@ static void increment_head(struct oprofile_cpu_buffer *b)
150 150
151static inline void 151static inline void
152add_sample(struct oprofile_cpu_buffer *cpu_buf, 152add_sample(struct oprofile_cpu_buffer *cpu_buf,
153 unsigned long pc, unsigned long event) 153 unsigned long pc, unsigned long event)
154{ 154{
155 struct op_sample *entry = &cpu_buf->buffer[cpu_buf->head_pos]; 155 struct op_sample *entry = &cpu_buf->buffer[cpu_buf->head_pos];
156 entry->eip = pc; 156 entry->eip = pc;
@@ -205,7 +205,7 @@ static int log_sample(struct oprofile_cpu_buffer *cpu_buf, unsigned long pc,
205 cpu_buf->last_task = task; 205 cpu_buf->last_task = task;
206 add_code(cpu_buf, (unsigned long)task); 206 add_code(cpu_buf, (unsigned long)task);
207 } 207 }
208 208
209 add_sample(cpu_buf, pc, event); 209 add_sample(cpu_buf, pc, event);
210 return 1; 210 return 1;
211} 211}