summaryrefslogtreecommitdiffstats
path: root/drivers/oprofile/oprofile_stats.c
diff options
context:
space:
mode:
authorTejun Heo2009-10-29 14:34:13 +0100
committerTejun Heo2009-10-29 14:34:13 +0100
commitb3e9f672b6cd0f4c2982c1bcc0b3c3fb39d3b0fe (patch)
tree4aaac8850226d81df5f90240839c1d1310c0ae75 /drivers/oprofile/oprofile_stats.c
parentpercpu: make percpu symbols in tracer unique (diff)
downloadkernel-qcow2-linux-b3e9f672b6cd0f4c2982c1bcc0b3c3fb39d3b0fe.tar.gz
kernel-qcow2-linux-b3e9f672b6cd0f4c2982c1bcc0b3c3fb39d3b0fe.tar.xz
kernel-qcow2-linux-b3e9f672b6cd0f4c2982c1bcc0b3c3fb39d3b0fe.zip
percpu: make percpu symbols in oprofile unique
This patch updates percpu related symbols in oprofile such that percpu symbols are unique and don't clash with local symbols. This serves two purposes of decreasing the possibility of global percpu symbol collision and allowing dropping per_cpu__ prefix from percpu symbols. * drivers/oprofile/cpu_buffer.c: s/cpu_buffer/op_cpu_buffer/ Partly based on Rusty Russell's "alloc_percpu: rename percpu vars which cause name clashes" patch. Signed-off-by: Tejun Heo <tj@kernel.org> Acked-by: Robert Richter <robert.richter@amd.com> Cc: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'drivers/oprofile/oprofile_stats.c')
-rw-r--r--drivers/oprofile/oprofile_stats.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/oprofile/oprofile_stats.c b/drivers/oprofile/oprofile_stats.c
index 61689e814d46..917d28ebeacd 100644
--- a/drivers/oprofile/oprofile_stats.c
+++ b/drivers/oprofile/oprofile_stats.c
@@ -23,7 +23,7 @@ void oprofile_reset_stats(void)
int i;
for_each_possible_cpu(i) {
- cpu_buf = &per_cpu(cpu_buffer, i);
+ cpu_buf = &per_cpu(op_cpu_buffer, i);
cpu_buf->sample_received = 0;
cpu_buf->sample_lost_overflow = 0;
cpu_buf->backtrace_aborted = 0;
@@ -51,7 +51,7 @@ void oprofile_create_stats_files(struct super_block *sb, struct dentry *root)
return;
for_each_possible_cpu(i) {
- cpu_buf = &per_cpu(cpu_buffer, i);
+ cpu_buf = &per_cpu(op_cpu_buffer, i);
snprintf(buf, 10, "cpu%d", i);
cpudir = oprofilefs_mkdir(sb, dir, buf);