From 151d14f4ac5a02cc059cb05b2a2f27ec5b9d6831 Mon Sep 17 00:00:00 2001 From: Steven King Date: Wed, 14 May 2014 10:07:55 -0700 Subject: m68knommu: qspi declutter. Move the check for the QSPI config option inside the function body. If the option is not enabled, the compiler will optimize away the empty function body so we can remove the other check for the config option. Signed-off-by: Steven King Signed-off-by: Greg Ungerer --- arch/m68k/platform/coldfire/m5249.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'arch/m68k/platform/coldfire/m5249.c') diff --git a/arch/m68k/platform/coldfire/m5249.c b/arch/m68k/platform/coldfire/m5249.c index 405ff3ca4f4f..f6253a3313b3 100644 --- a/arch/m68k/platform/coldfire/m5249.c +++ b/arch/m68k/platform/coldfire/m5249.c @@ -73,17 +73,15 @@ static struct platform_device *m5249_devices[] __initdata = { /***************************************************************************/ -#if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) - static void __init m5249_qspi_init(void) { +#if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) /* QSPI irq setup */ writeb(MCFSIM_ICR_AUTOVEC | MCFSIM_ICR_LEVEL4 | MCFSIM_ICR_PRI0, MCFSIM_QSPIICR); mcf_mapirq2imr(MCF_IRQ_QSPI, MCFINTC_QSPI); -} - #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ +} /***************************************************************************/ @@ -112,9 +110,7 @@ void __init config_BSP(char *commandp, int size) #ifdef CONFIG_M5249C3 m5249_smc91x_init(); #endif -#if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) m5249_qspi_init(); -#endif } /***************************************************************************/ -- cgit v1.2.3