ARM: imx: avic: Move avic_saved_mask_reg under CONFIG_PM
authorFabio Estevam <fabio.estevam@freescale.com>
Tue, 5 Feb 2013 17:36:16 +0000 (15:36 -0200)
committerShawn Guo <shawn.guo@linaro.org>
Tue, 2 Apr 2013 12:43:07 +0000 (20:43 +0800)
When building a kernel with CONFIG_PM undefined, the following warning happens:

arch/arm/mach-imx/avic.c:57:12: warning: 'avic_saved_mask_reg' defined but not used [-Wunused-variable]

Move avic_saved_mask_reg definition inside the '#ifdef CONFIG_PM' block to
avoid the warning.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
arch/arm/mach-imx/avic.c

index 0eff23ed92b930c5e2c56b3b0c3753420ac09ff5..49c87e7aa81752f7c7cba634efa89ce000868c5c 100644 (file)
@@ -54,8 +54,6 @@
 void __iomem *avic_base;
 static struct irq_domain *domain;
 
-static u32 avic_saved_mask_reg[2];
-
 #ifdef CONFIG_MXC_IRQ_PRIOR
 static int avic_irq_set_priority(unsigned char irq, unsigned char prio)
 {
@@ -113,6 +111,8 @@ static struct mxc_extra_irq avic_extra_irq = {
 };
 
 #ifdef CONFIG_PM
+static u32 avic_saved_mask_reg[2];
+
 static void avic_irq_suspend(struct irq_data *d)
 {
        struct irq_chip_generic *gc = irq_data_get_irq_chip_data(d);