diff options
author | Magnus Damm <damm@opensource.se> | 2013-11-06 18:21:38 -0500 |
---|---|---|
committer | Simon Horman <horms+renesas@verge.net.au> | 2013-12-04 01:11:16 -0500 |
commit | 59032702ead9056231f273e0e99655c2f2280491 (patch) | |
tree | 34e00c29e96e7214adda7266a40bfbc6db34258a | |
parent | 786deb29e7b7c356342f9f3566a6eafae2ce0c81 (diff) |
ARM: shmobile: Remove legacy platform devices from EMEV2 SoC code
Now when KZM9D legacy C board support code is
gone then remove emev2_add_standard_devices()
and all the platform devices from setup-emev2.c.
Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
-rw-r--r-- | arch/arm/mach-shmobile/include/mach/emev2.h | 5 | ||||
-rw-r--r-- | arch/arm/mach-shmobile/setup-emev2.c | 148 |
2 files changed, 0 insertions, 153 deletions
diff --git a/arch/arm/mach-shmobile/include/mach/emev2.h b/arch/arm/mach-shmobile/include/mach/emev2.h index c2eb7568d9be..fcb142a14e07 100644 --- a/arch/arm/mach-shmobile/include/mach/emev2.h +++ b/arch/arm/mach-shmobile/include/mach/emev2.h | |||
@@ -3,12 +3,7 @@ | |||
3 | 3 | ||
4 | extern void emev2_map_io(void); | 4 | extern void emev2_map_io(void); |
5 | extern void emev2_init_delay(void); | 5 | extern void emev2_init_delay(void); |
6 | extern void emev2_add_standard_devices(void); | ||
7 | extern void emev2_clock_init(void); | 6 | extern void emev2_clock_init(void); |
8 | |||
9 | #define EMEV2_GPIO_BASE 200 | ||
10 | #define EMEV2_GPIO_IRQ(n) (EMEV2_GPIO_BASE + (n)) | ||
11 | |||
12 | extern struct smp_operations emev2_smp_ops; | 7 | extern struct smp_operations emev2_smp_ops; |
13 | 8 | ||
14 | #endif /* __ASM_EMEV2_H__ */ | 9 | #endif /* __ASM_EMEV2_H__ */ |
diff --git a/arch/arm/mach-shmobile/setup-emev2.c b/arch/arm/mach-shmobile/setup-emev2.c index 4d39bf49aae2..e7031b071274 100644 --- a/arch/arm/mach-shmobile/setup-emev2.c +++ b/arch/arm/mach-shmobile/setup-emev2.c | |||
@@ -19,22 +19,12 @@ | |||
19 | #include <linux/clk-provider.h> | 19 | #include <linux/clk-provider.h> |
20 | #include <linux/kernel.h> | 20 | #include <linux/kernel.h> |
21 | #include <linux/init.h> | 21 | #include <linux/init.h> |
22 | #include <linux/interrupt.h> | ||
23 | #include <linux/irq.h> | ||
24 | #include <linux/platform_device.h> | ||
25 | #include <linux/platform_data/gpio-em.h> | ||
26 | #include <linux/of_platform.h> | 22 | #include <linux/of_platform.h> |
27 | #include <linux/delay.h> | ||
28 | #include <linux/input.h> | ||
29 | #include <linux/io.h> | ||
30 | #include <linux/irqchip/arm-gic.h> | ||
31 | #include <mach/common.h> | 23 | #include <mach/common.h> |
32 | #include <mach/emev2.h> | 24 | #include <mach/emev2.h> |
33 | #include <mach/irqs.h> | ||
34 | #include <asm/mach-types.h> | 25 | #include <asm/mach-types.h> |
35 | #include <asm/mach/arch.h> | 26 | #include <asm/mach/arch.h> |
36 | #include <asm/mach/map.h> | 27 | #include <asm/mach/map.h> |
37 | #include <asm/mach/time.h> | ||
38 | 28 | ||
39 | static struct map_desc emev2_io_desc[] __initdata = { | 29 | static struct map_desc emev2_io_desc[] __initdata = { |
40 | #ifdef CONFIG_SMP | 30 | #ifdef CONFIG_SMP |
@@ -53,144 +43,6 @@ void __init emev2_map_io(void) | |||
53 | iotable_init(emev2_io_desc, ARRAY_SIZE(emev2_io_desc)); | 43 | iotable_init(emev2_io_desc, ARRAY_SIZE(emev2_io_desc)); |
54 | } | 44 | } |
55 | 45 | ||
56 | /* UART */ | ||
57 | static struct resource uart0_resources[] = { | ||
58 | DEFINE_RES_MEM(0xe1020000, 0x38), | ||
59 | DEFINE_RES_IRQ(40), | ||
60 | }; | ||
61 | |||
62 | static struct resource uart1_resources[] = { | ||
63 | DEFINE_RES_MEM(0xe1030000, 0x38), | ||
64 | DEFINE_RES_IRQ(41), | ||
65 | }; | ||
66 | |||
67 | static struct resource uart2_resources[] = { | ||
68 | DEFINE_RES_MEM(0xe1040000, 0x38), | ||
69 | DEFINE_RES_IRQ(42), | ||
70 | }; | ||
71 | |||
72 | static struct resource uart3_resources[] = { | ||
73 | DEFINE_RES_MEM(0xe1050000, 0x38), | ||
74 | DEFINE_RES_IRQ(43), | ||
75 | }; | ||
76 | |||
77 | #define emev2_register_uart(idx) \ | ||
78 | platform_device_register_simple("serial8250-em", idx, \ | ||
79 | uart##idx##_resources, \ | ||
80 | ARRAY_SIZE(uart##idx##_resources)) | ||
81 | |||
82 | /* STI */ | ||
83 | static struct resource sti_resources[] = { | ||
84 | DEFINE_RES_MEM(0xe0180000, 0x54), | ||
85 | DEFINE_RES_IRQ(157), | ||
86 | }; | ||
87 | |||
88 | #define emev2_register_sti() \ | ||
89 | platform_device_register_simple("em_sti", 0, \ | ||
90 | sti_resources, \ | ||
91 | ARRAY_SIZE(sti_resources)) | ||
92 | |||
93 | /* GIO */ | ||
94 | static struct gpio_em_config gio0_config = { | ||
95 | .gpio_base = 0, | ||
96 | .irq_base = EMEV2_GPIO_IRQ(0), | ||
97 | .number_of_pins = 32, | ||
98 | }; | ||
99 | |||
100 | static struct resource gio0_resources[] = { | ||
101 | DEFINE_RES_MEM(0xe0050000, 0x2c), | ||
102 | DEFINE_RES_MEM(0xe0050040, 0x20), | ||
103 | DEFINE_RES_IRQ(99), | ||
104 | DEFINE_RES_IRQ(100), | ||
105 | }; | ||
106 | |||
107 | static struct gpio_em_config gio1_config = { | ||
108 | .gpio_base = 32, | ||
109 | .irq_base = EMEV2_GPIO_IRQ(32), | ||
110 | .number_of_pins = 32, | ||
111 | }; | ||
112 | |||
113 | static struct resource gio1_resources[] = { | ||
114 | DEFINE_RES_MEM(0xe0050080, 0x2c), | ||
115 | DEFINE_RES_MEM(0xe00500c0, 0x20), | ||
116 | DEFINE_RES_IRQ(101), | ||
117 | DEFINE_RES_IRQ(102), | ||
118 | }; | ||
119 | |||
120 | static struct gpio_em_config gio2_config = { | ||
121 | .gpio_base = 64, | ||
122 | .irq_base = EMEV2_GPIO_IRQ(64), | ||
123 | .number_of_pins = 32, | ||
124 | }; | ||
125 | |||
126 | static struct resource gio2_resources[] = { | ||
127 | DEFINE_RES_MEM(0xe0050100, 0x2c), | ||
128 | DEFINE_RES_MEM(0xe0050140, 0x20), | ||
129 | DEFINE_RES_IRQ(103), | ||
130 | DEFINE_RES_IRQ(104), | ||
131 | }; | ||
132 | |||
133 | static struct gpio_em_config gio3_config = { | ||
134 | .gpio_base = 96, | ||
135 | .irq_base = EMEV2_GPIO_IRQ(96), | ||
136 | .number_of_pins = 32, | ||
137 | }; | ||
138 | |||
139 | static struct resource gio3_resources[] = { | ||
140 | DEFINE_RES_MEM(0xe0050180, 0x2c), | ||
141 | DEFINE_RES_MEM(0xe00501c0, 0x20), | ||
142 | DEFINE_RES_IRQ(105), | ||
143 | DEFINE_RES_IRQ(106), | ||
144 | }; | ||
145 | |||
146 | static struct gpio_em_config gio4_config = { | ||
147 | .gpio_base = 128, | ||
148 | .irq_base = EMEV2_GPIO_IRQ(128), | ||
149 | .number_of_pins = 31, | ||
150 | }; | ||
151 | |||
152 | static struct resource gio4_resources[] = { | ||
153 | DEFINE_RES_MEM(0xe0050200, 0x2c), | ||
154 | DEFINE_RES_MEM(0xe0050240, 0x20), | ||
155 | DEFINE_RES_IRQ(107), | ||
156 | DEFINE_RES_IRQ(108), | ||
157 | }; | ||
158 | |||
159 | #define emev2_register_gio(idx) \ | ||
160 | platform_device_register_resndata(&platform_bus, "em_gio", \ | ||
161 | idx, gio##idx##_resources, \ | ||
162 | ARRAY_SIZE(gio##idx##_resources), \ | ||
163 | &gio##idx##_config, \ | ||
164 | sizeof(struct gpio_em_config)) | ||
165 | |||
166 | static struct resource pmu_resources[] = { | ||
167 | DEFINE_RES_IRQ(152), | ||
168 | DEFINE_RES_IRQ(153), | ||
169 | }; | ||
170 | |||
171 | #define emev2_register_pmu() \ | ||
172 | platform_device_register_simple("arm-pmu", -1, \ | ||
173 | pmu_resources, \ | ||
174 | ARRAY_SIZE(pmu_resources)) | ||
175 | |||
176 | void __init emev2_add_standard_devices(void) | ||
177 | { | ||
178 | if (!IS_ENABLED(CONFIG_COMMON_CLK)) | ||
179 | emev2_clock_init(); | ||
180 | |||
181 | emev2_register_uart(0); | ||
182 | emev2_register_uart(1); | ||
183 | emev2_register_uart(2); | ||
184 | emev2_register_uart(3); | ||
185 | emev2_register_sti(); | ||
186 | emev2_register_gio(0); | ||
187 | emev2_register_gio(1); | ||
188 | emev2_register_gio(2); | ||
189 | emev2_register_gio(3); | ||
190 | emev2_register_gio(4); | ||
191 | emev2_register_pmu(); | ||
192 | } | ||
193 | |||
194 | void __init emev2_init_delay(void) | 46 | void __init emev2_init_delay(void) |
195 | { | 47 | { |
196 | shmobile_setup_delay(533, 1, 3); /* Cortex-A9 @ 533MHz */ | 48 | shmobile_setup_delay(533, 1, 3); /* Cortex-A9 @ 533MHz */ |