diff options
author | Steven King <sfking@fdwdc.com> | 2012-05-06 15:22:53 -0400 |
---|---|---|
committer | Greg Ungerer <gerg@uclinux.org> | 2012-05-07 23:06:51 -0400 |
commit | 83ca60094e5e907b8b43c60b4c29b1119604cbb8 (patch) | |
tree | c29bc1f8db186f1c6adcb205c0b7cbe1be3cef2e /arch | |
parent | d48b97b403d23f6df0b990cee652bdf9a52337a3 (diff) |
m68knommu: enable qspi support when SPI_COLDFIRE_QSPI = m
Enable Coldfire QSPI support when SPI_COLDFIRE_QSPI is built as a module.
This version of the patch combines changes to the config files and device.c
and uses IF_ENABLED (thanks to Sam Ravnborg for the suggestion).
Signed-off-by: Steven King <sfking@fdwdc.com>
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/m68k/platform/520x/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/platform/523x/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/platform/5249/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/platform/527x/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/platform/528x/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/platform/532x/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/platform/coldfire/device.c | 6 |
7 files changed, 21 insertions, 21 deletions
diff --git a/arch/m68k/platform/520x/config.c b/arch/m68k/platform/520x/config.c index 235947844f27..09df4b89e8be 100644 --- a/arch/m68k/platform/520x/config.c +++ b/arch/m68k/platform/520x/config.c | |||
@@ -22,7 +22,7 @@ | |||
22 | 22 | ||
23 | /***************************************************************************/ | 23 | /***************************************************************************/ |
24 | 24 | ||
25 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 25 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
26 | 26 | ||
27 | static void __init m520x_qspi_init(void) | 27 | static void __init m520x_qspi_init(void) |
28 | { | 28 | { |
@@ -35,7 +35,7 @@ static void __init m520x_qspi_init(void) | |||
35 | writew(par, MCF_GPIO_PAR_UART); | 35 | writew(par, MCF_GPIO_PAR_UART); |
36 | } | 36 | } |
37 | 37 | ||
38 | #endif /* CONFIG_SPI_COLDFIRE_QSPI */ | 38 | #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ |
39 | 39 | ||
40 | /***************************************************************************/ | 40 | /***************************************************************************/ |
41 | 41 | ||
@@ -79,7 +79,7 @@ void __init config_BSP(char *commandp, int size) | |||
79 | mach_sched_init = hw_timer_init; | 79 | mach_sched_init = hw_timer_init; |
80 | m520x_uarts_init(); | 80 | m520x_uarts_init(); |
81 | m520x_fec_init(); | 81 | m520x_fec_init(); |
82 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 82 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
83 | m520x_qspi_init(); | 83 | m520x_qspi_init(); |
84 | #endif | 84 | #endif |
85 | } | 85 | } |
diff --git a/arch/m68k/platform/523x/config.c b/arch/m68k/platform/523x/config.c index c8b405d5a961..d47dfd8f50a2 100644 --- a/arch/m68k/platform/523x/config.c +++ b/arch/m68k/platform/523x/config.c | |||
@@ -22,7 +22,7 @@ | |||
22 | 22 | ||
23 | /***************************************************************************/ | 23 | /***************************************************************************/ |
24 | 24 | ||
25 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 25 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
26 | 26 | ||
27 | static void __init m523x_qspi_init(void) | 27 | static void __init m523x_qspi_init(void) |
28 | { | 28 | { |
@@ -36,7 +36,7 @@ static void __init m523x_qspi_init(void) | |||
36 | writew(par, MCFGPIO_PAR_TIMER); | 36 | writew(par, MCFGPIO_PAR_TIMER); |
37 | } | 37 | } |
38 | 38 | ||
39 | #endif /* CONFIG_SPI_COLDFIRE_QSPI */ | 39 | #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ |
40 | 40 | ||
41 | /***************************************************************************/ | 41 | /***************************************************************************/ |
42 | 42 | ||
@@ -58,7 +58,7 @@ void __init config_BSP(char *commandp, int size) | |||
58 | { | 58 | { |
59 | mach_sched_init = hw_timer_init; | 59 | mach_sched_init = hw_timer_init; |
60 | m523x_fec_init(); | 60 | m523x_fec_init(); |
61 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 61 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
62 | m523x_qspi_init(); | 62 | m523x_qspi_init(); |
63 | #endif | 63 | #endif |
64 | } | 64 | } |
diff --git a/arch/m68k/platform/5249/config.c b/arch/m68k/platform/5249/config.c index bbf05135bb98..300e729a58d0 100644 --- a/arch/m68k/platform/5249/config.c +++ b/arch/m68k/platform/5249/config.c | |||
@@ -51,7 +51,7 @@ static struct platform_device *m5249_devices[] __initdata = { | |||
51 | 51 | ||
52 | /***************************************************************************/ | 52 | /***************************************************************************/ |
53 | 53 | ||
54 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 54 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
55 | 55 | ||
56 | static void __init m5249_qspi_init(void) | 56 | static void __init m5249_qspi_init(void) |
57 | { | 57 | { |
@@ -61,7 +61,7 @@ static void __init m5249_qspi_init(void) | |||
61 | mcf_mapirq2imr(MCF_IRQ_QSPI, MCFINTC_QSPI); | 61 | mcf_mapirq2imr(MCF_IRQ_QSPI, MCFINTC_QSPI); |
62 | } | 62 | } |
63 | 63 | ||
64 | #endif /* CONFIG_SPI_COLDFIRE_QSPI */ | 64 | #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ |
65 | 65 | ||
66 | /***************************************************************************/ | 66 | /***************************************************************************/ |
67 | 67 | ||
@@ -90,7 +90,7 @@ void __init config_BSP(char *commandp, int size) | |||
90 | #ifdef CONFIG_M5249C3 | 90 | #ifdef CONFIG_M5249C3 |
91 | m5249_smc91x_init(); | 91 | m5249_smc91x_init(); |
92 | #endif | 92 | #endif |
93 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 93 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
94 | m5249_qspi_init(); | 94 | m5249_qspi_init(); |
95 | #endif | 95 | #endif |
96 | } | 96 | } |
diff --git a/arch/m68k/platform/527x/config.c b/arch/m68k/platform/527x/config.c index f91a53294c35..b3cb378c5e94 100644 --- a/arch/m68k/platform/527x/config.c +++ b/arch/m68k/platform/527x/config.c | |||
@@ -23,7 +23,7 @@ | |||
23 | 23 | ||
24 | /***************************************************************************/ | 24 | /***************************************************************************/ |
25 | 25 | ||
26 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 26 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
27 | 27 | ||
28 | static void __init m527x_qspi_init(void) | 28 | static void __init m527x_qspi_init(void) |
29 | { | 29 | { |
@@ -42,7 +42,7 @@ static void __init m527x_qspi_init(void) | |||
42 | #endif | 42 | #endif |
43 | } | 43 | } |
44 | 44 | ||
45 | #endif /* CONFIG_SPI_COLDFIRE_QSPI */ | 45 | #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ |
46 | 46 | ||
47 | /***************************************************************************/ | 47 | /***************************************************************************/ |
48 | 48 | ||
@@ -90,7 +90,7 @@ void __init config_BSP(char *commandp, int size) | |||
90 | mach_sched_init = hw_timer_init; | 90 | mach_sched_init = hw_timer_init; |
91 | m527x_uarts_init(); | 91 | m527x_uarts_init(); |
92 | m527x_fec_init(); | 92 | m527x_fec_init(); |
93 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 93 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
94 | m527x_qspi_init(); | 94 | m527x_qspi_init(); |
95 | #endif | 95 | #endif |
96 | } | 96 | } |
diff --git a/arch/m68k/platform/528x/config.c b/arch/m68k/platform/528x/config.c index d4492926614c..c5f11ba49be5 100644 --- a/arch/m68k/platform/528x/config.c +++ b/arch/m68k/platform/528x/config.c | |||
@@ -24,7 +24,7 @@ | |||
24 | 24 | ||
25 | /***************************************************************************/ | 25 | /***************************************************************************/ |
26 | 26 | ||
27 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 27 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
28 | 28 | ||
29 | static void __init m528x_qspi_init(void) | 29 | static void __init m528x_qspi_init(void) |
30 | { | 30 | { |
@@ -32,7 +32,7 @@ static void __init m528x_qspi_init(void) | |||
32 | __raw_writeb(0x07, MCFGPIO_PQSPAR); | 32 | __raw_writeb(0x07, MCFGPIO_PQSPAR); |
33 | } | 33 | } |
34 | 34 | ||
35 | #endif /* CONFIG_SPI_COLDFIRE_QSPI */ | 35 | #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ |
36 | 36 | ||
37 | /***************************************************************************/ | 37 | /***************************************************************************/ |
38 | 38 | ||
@@ -98,7 +98,7 @@ void __init config_BSP(char *commandp, int size) | |||
98 | mach_sched_init = hw_timer_init; | 98 | mach_sched_init = hw_timer_init; |
99 | m528x_uarts_init(); | 99 | m528x_uarts_init(); |
100 | m528x_fec_init(); | 100 | m528x_fec_init(); |
101 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 101 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
102 | m528x_qspi_init(); | 102 | m528x_qspi_init(); |
103 | #endif | 103 | #endif |
104 | } | 104 | } |
diff --git a/arch/m68k/platform/532x/config.c b/arch/m68k/platform/532x/config.c index 2bec3477b739..37082d02f2bd 100644 --- a/arch/m68k/platform/532x/config.c +++ b/arch/m68k/platform/532x/config.c | |||
@@ -30,7 +30,7 @@ | |||
30 | 30 | ||
31 | /***************************************************************************/ | 31 | /***************************************************************************/ |
32 | 32 | ||
33 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 33 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
34 | 34 | ||
35 | static void __init m532x_qspi_init(void) | 35 | static void __init m532x_qspi_init(void) |
36 | { | 36 | { |
@@ -38,7 +38,7 @@ static void __init m532x_qspi_init(void) | |||
38 | writew(0x01f0, MCF_GPIO_PAR_QSPI); | 38 | writew(0x01f0, MCF_GPIO_PAR_QSPI); |
39 | } | 39 | } |
40 | 40 | ||
41 | #endif /* CONFIG_SPI_COLDFIRE_QSPI */ | 41 | #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ |
42 | 42 | ||
43 | /***************************************************************************/ | 43 | /***************************************************************************/ |
44 | 44 | ||
@@ -77,7 +77,7 @@ void __init config_BSP(char *commandp, int size) | |||
77 | mach_sched_init = hw_timer_init; | 77 | mach_sched_init = hw_timer_init; |
78 | m532x_uarts_init(); | 78 | m532x_uarts_init(); |
79 | m532x_fec_init(); | 79 | m532x_fec_init(); |
80 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 80 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
81 | m532x_qspi_init(); | 81 | m532x_qspi_init(); |
82 | #endif | 82 | #endif |
83 | 83 | ||
diff --git a/arch/m68k/platform/coldfire/device.c b/arch/m68k/platform/coldfire/device.c index 7af97362b95c..3aa77ddea89d 100644 --- a/arch/m68k/platform/coldfire/device.c +++ b/arch/m68k/platform/coldfire/device.c | |||
@@ -121,7 +121,7 @@ static struct platform_device mcf_fec1 = { | |||
121 | #endif /* MCFFEC_BASE1 */ | 121 | #endif /* MCFFEC_BASE1 */ |
122 | #endif /* CONFIG_FEC */ | 122 | #endif /* CONFIG_FEC */ |
123 | 123 | ||
124 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 124 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
125 | /* | 125 | /* |
126 | * The ColdFire QSPI module is an SPI protocol hardware block used | 126 | * The ColdFire QSPI module is an SPI protocol hardware block used |
127 | * on a number of different ColdFire CPUs. | 127 | * on a number of different ColdFire CPUs. |
@@ -274,7 +274,7 @@ static struct platform_device mcf_qspi = { | |||
274 | .resource = mcf_qspi_resources, | 274 | .resource = mcf_qspi_resources, |
275 | .dev.platform_data = &mcf_qspi_data, | 275 | .dev.platform_data = &mcf_qspi_data, |
276 | }; | 276 | }; |
277 | #endif /* CONFIG_SPI_COLDFIRE_QSPI */ | 277 | #endif /* IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) */ |
278 | 278 | ||
279 | static struct platform_device *mcf_devices[] __initdata = { | 279 | static struct platform_device *mcf_devices[] __initdata = { |
280 | &mcf_uart, | 280 | &mcf_uart, |
@@ -284,7 +284,7 @@ static struct platform_device *mcf_devices[] __initdata = { | |||
284 | &mcf_fec1, | 284 | &mcf_fec1, |
285 | #endif | 285 | #endif |
286 | #endif | 286 | #endif |
287 | #ifdef CONFIG_SPI_COLDFIRE_QSPI | 287 | #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI) |
288 | &mcf_qspi, | 288 | &mcf_qspi, |
289 | #endif | 289 | #endif |
290 | }; | 290 | }; |