[PATCH] nitpick: enclose hotplug only variables in hotplug ifdef

From: Glauber Costa
Date: Mon Sep 05 2011 - 22:35:31 EST


These variables are only used when CONFIG_HOTPLUG is enabled,
they are ifdef'ed everywhere else. So don't define them when
CONFIG_HOTPLUG is not enabled.

Signed-off-by: Glauber Costa <glommer@xxxxxxxxxxxxx>
CC: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---
lib/percpu_counter.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/lib/percpu_counter.c b/lib/percpu_counter.c
index 28f2c33..30cbe47 100644
--- a/lib/percpu_counter.c
+++ b/lib/percpu_counter.c
@@ -10,8 +10,10 @@
#include <linux/module.h>
#include <linux/debugobjects.h>

+#ifdef CONFIG_HOTPLUG_CPU
static LIST_HEAD(percpu_counters);
static DEFINE_MUTEX(percpu_counters_lock);
+#endif

#ifdef CONFIG_DEBUG_OBJECTS_PERCPU_COUNTER

--
1.7.6

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/