Commit eea4a0b1 authored by Ingo Molnar's avatar Ingo Molnar

Merge branch 'tip/perf/core-2' of...

Merge branch 'tip/perf/core-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-2.6-trace into perf/urgent
parents d7842da4 dd49a38c
...@@ -3996,13 +3996,9 @@ static void tracing_init_debugfs_percpu(long cpu) ...@@ -3996,13 +3996,9 @@ static void tracing_init_debugfs_percpu(long cpu)
{ {
struct dentry *d_percpu = tracing_dentry_percpu(); struct dentry *d_percpu = tracing_dentry_percpu();
struct dentry *d_cpu; struct dentry *d_cpu;
/* strlen(cpu) + MAX(log10(cpu)) + '\0' */ char cpu_dir[30]; /* 30 characters should be more than enough */
char cpu_dir[7];
if (cpu > 999 || cpu < 0) snprintf(cpu_dir, 30, "cpu%ld", cpu);
return;
sprintf(cpu_dir, "cpu%ld", cpu);
d_cpu = debugfs_create_dir(cpu_dir, d_percpu); d_cpu = debugfs_create_dir(cpu_dir, d_percpu);
if (!d_cpu) { if (!d_cpu) {
pr_warning("Could not create debugfs '%s' entry\n", cpu_dir); pr_warning("Could not create debugfs '%s' entry\n", cpu_dir);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment