diff options
author | Magnus Damm <damm@igel.co.jp> | 2007-08-12 02:30:40 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2007-09-20 22:57:50 -0400 |
commit | f8b40d8ce86035b126a27a57ed9139c08ae3ebf1 (patch) | |
tree | 902a6757448f8d80c08b7b5c2456ed400d9fcb5b /arch/sh | |
parent | 2eeec85638cebcb6fbcb2abfe182a32252f3456d (diff) |
sh: replace sh specific CONFIG_VOYAGERGX with CONFIG_MFD_SM501
This patch replaces all instances of CONFIG_VOYAGERGX with
CONFIG_MFD_SM501. While at it we make sure the r2d code compiles
both with and without SM501.
Signed-off-by: Magnus Damm <damm@igel.co.jp>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh')
-rw-r--r-- | arch/sh/Makefile | 2 | ||||
-rw-r--r-- | arch/sh/boards/renesas/rts7751r2d/irq.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/renesas/rts7751r2d/setup.c | 39 | ||||
-rw-r--r-- | arch/sh/cchips/Kconfig | 13 |
4 files changed, 25 insertions, 31 deletions
diff --git a/arch/sh/Makefile b/arch/sh/Makefile index 37cf636fba55..6c73a5b2b014 100644 --- a/arch/sh/Makefile +++ b/arch/sh/Makefile | |||
@@ -136,7 +136,7 @@ endif | |||
136 | 136 | ||
137 | # Companion chips | 137 | # Companion chips |
138 | core-$(CONFIG_HD6446X_SERIES) += arch/sh/cchips/hd6446x/ | 138 | core-$(CONFIG_HD6446X_SERIES) += arch/sh/cchips/hd6446x/ |
139 | core-$(CONFIG_VOYAGERGX) += arch/sh/cchips/voyagergx/ | 139 | core-$(CONFIG_MFD_SM501) += arch/sh/cchips/voyagergx/ |
140 | 140 | ||
141 | cpuincdir-$(CONFIG_CPU_SH2) := cpu-sh2 | 141 | cpuincdir-$(CONFIG_CPU_SH2) := cpu-sh2 |
142 | cpuincdir-$(CONFIG_CPU_SH2A) := cpu-sh2a | 142 | cpuincdir-$(CONFIG_CPU_SH2A) := cpu-sh2a |
diff --git a/arch/sh/boards/renesas/rts7751r2d/irq.c b/arch/sh/boards/renesas/rts7751r2d/irq.c index e89932903caf..878852158b45 100644 --- a/arch/sh/boards/renesas/rts7751r2d/irq.c +++ b/arch/sh/boards/renesas/rts7751r2d/irq.c | |||
@@ -153,5 +153,7 @@ void __init init_rts7751r2d_IRQ(void) | |||
153 | } | 153 | } |
154 | 154 | ||
155 | register_intc_controller(d); | 155 | register_intc_controller(d); |
156 | #ifdef CONFIG_MFD_SM501 | ||
156 | setup_voyagergx_irq(); | 157 | setup_voyagergx_irq(); |
158 | #endif | ||
157 | } | 159 | } |
diff --git a/arch/sh/boards/renesas/rts7751r2d/setup.c b/arch/sh/boards/renesas/rts7751r2d/setup.c index 90703d5d1230..bea9848e5ff8 100644 --- a/arch/sh/boards/renesas/rts7751r2d/setup.c +++ b/arch/sh/boards/renesas/rts7751r2d/setup.c | |||
@@ -73,6 +73,22 @@ static struct platform_device cf_ide_device = { | |||
73 | }, | 73 | }, |
74 | }; | 74 | }; |
75 | 75 | ||
76 | static struct resource heartbeat_resources[] = { | ||
77 | [0] = { | ||
78 | .start = PA_OUTPORT, | ||
79 | .end = PA_OUTPORT + 8 - 1, | ||
80 | .flags = IORESOURCE_MEM, | ||
81 | }, | ||
82 | }; | ||
83 | |||
84 | static struct platform_device heartbeat_device = { | ||
85 | .name = "heartbeat", | ||
86 | .id = -1, | ||
87 | .num_resources = ARRAY_SIZE(heartbeat_resources), | ||
88 | .resource = heartbeat_resources, | ||
89 | }; | ||
90 | |||
91 | #ifdef CONFIG_MFD_SM501 | ||
76 | static struct plat_serial8250_port uart_platform_data[] = { | 92 | static struct plat_serial8250_port uart_platform_data[] = { |
77 | { | 93 | { |
78 | .membase = (void __iomem *)VOYAGER_UART_BASE, | 94 | .membase = (void __iomem *)VOYAGER_UART_BASE, |
@@ -94,21 +110,6 @@ static struct platform_device uart_device = { | |||
94 | }, | 110 | }, |
95 | }; | 111 | }; |
96 | 112 | ||
97 | static struct resource heartbeat_resources[] = { | ||
98 | [0] = { | ||
99 | .start = PA_OUTPORT, | ||
100 | .end = PA_OUTPORT + 8 - 1, | ||
101 | .flags = IORESOURCE_MEM, | ||
102 | }, | ||
103 | }; | ||
104 | |||
105 | static struct platform_device heartbeat_device = { | ||
106 | .name = "heartbeat", | ||
107 | .id = -1, | ||
108 | .num_resources = ARRAY_SIZE(heartbeat_resources), | ||
109 | .resource = heartbeat_resources, | ||
110 | }; | ||
111 | |||
112 | static struct resource sm501_resources[] = { | 113 | static struct resource sm501_resources[] = { |
113 | [0] = { | 114 | [0] = { |
114 | .start = 0x10000000, | 115 | .start = 0x10000000, |
@@ -133,10 +134,14 @@ static struct platform_device sm501_device = { | |||
133 | .resource = sm501_resources, | 134 | .resource = sm501_resources, |
134 | }; | 135 | }; |
135 | 136 | ||
137 | #endif /* CONFIG_MFD_SM501 */ | ||
138 | |||
136 | static struct platform_device *rts7751r2d_devices[] __initdata = { | 139 | static struct platform_device *rts7751r2d_devices[] __initdata = { |
140 | #ifdef CONFIG_MFD_SM501 | ||
137 | &uart_device, | 141 | &uart_device, |
138 | &heartbeat_device, | ||
139 | &sm501_device, | 142 | &sm501_device, |
143 | #endif | ||
144 | &heartbeat_device, | ||
140 | }; | 145 | }; |
141 | 146 | ||
142 | static int __init rts7751r2d_devices_setup(void) | 147 | static int __init rts7751r2d_devices_setup(void) |
@@ -187,7 +192,7 @@ static struct sh_machine_vector mv_rts7751r2d __initmv = { | |||
187 | .mv_init_irq = init_rts7751r2d_IRQ, | 192 | .mv_init_irq = init_rts7751r2d_IRQ, |
188 | .mv_irq_demux = rts7751r2d_irq_demux, | 193 | .mv_irq_demux = rts7751r2d_irq_demux, |
189 | 194 | ||
190 | #ifdef CONFIG_USB_SM501 | 195 | #if defined(CONFIG_MFD_SM501) && defined(CONFIG_USB_OHCI_HCD) |
191 | .mv_consistent_alloc = voyagergx_consistent_alloc, | 196 | .mv_consistent_alloc = voyagergx_consistent_alloc, |
192 | .mv_consistent_free = voyagergx_consistent_free, | 197 | .mv_consistent_free = voyagergx_consistent_free, |
193 | #endif | 198 | #endif |
diff --git a/arch/sh/cchips/Kconfig b/arch/sh/cchips/Kconfig index 2e516e9a6ede..7892361eedc8 100644 --- a/arch/sh/cchips/Kconfig +++ b/arch/sh/cchips/Kconfig | |||
@@ -1,18 +1,5 @@ | |||
1 | menu "Companion Chips" | 1 | menu "Companion Chips" |
2 | 2 | ||
3 | config VOYAGERGX | ||
4 | bool "VoyagerGX chip support" | ||
5 | depends on SH_RTS7751R2D | ||
6 | help | ||
7 | Selecting this option will support Silicon Motion, Inc. SM501. | ||
8 | Designed to complement needs for the embedded industry, it | ||
9 | provides video and 2D capability. To reduce system cost a | ||
10 | wide variety of include I/O is supported, including analog RGB | ||
11 | and digital LCD Panel interface, 8-bit parallel interface, USB, | ||
12 | UART, IrDA, Zoom Video, AC97 or I2S, SSP, PWM, and I2C. There | ||
13 | are additional GPIO bits that can be used to interface to | ||
14 | external as well. | ||
15 | |||
16 | config HD6446X_SERIES | 3 | config HD6446X_SERIES |
17 | bool | 4 | bool |
18 | 5 | ||