aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTony Lindgren <tony@atomide.com>2013-05-30 15:53:06 -0400
committerTony Lindgren <tony@atomide.com>2013-05-30 16:09:31 -0400
commit608d19380c67d3a68ef53568a8ea4f82fefa618e (patch)
treefbe0ab9e916821503f3d925dea0366fc834012d6
parentb30e321b6a3ebd019c7be9019946017d73e18989 (diff)
ARM: OMAP2+: Remove omap4 pdata for USB
This is no longer needed as omap4 is now booted using device tree. Signed-off-by: Tony Lindgren <tony@atomide.com>
-rw-r--r--arch/arm/mach-omap2/devices.c45
-rw-r--r--arch/arm/mach-omap2/usb-host.c194
-rw-r--r--arch/arm/mach-omap2/usb-musb.c3
3 files changed, 0 insertions, 242 deletions
diff --git a/arch/arm/mach-omap2/devices.c b/arch/arm/mach-omap2/devices.c
index d428b95bd137..350116906f18 100644
--- a/arch/arm/mach-omap2/devices.c
+++ b/arch/arm/mach-omap2/devices.c
@@ -21,7 +21,6 @@
21#include <linux/pinctrl/machine.h> 21#include <linux/pinctrl/machine.h>
22#include <linux/platform_data/omap4-keypad.h> 22#include <linux/platform_data/omap4-keypad.h>
23#include <linux/platform_data/omap_ocp2scp.h> 23#include <linux/platform_data/omap_ocp2scp.h>
24#include <linux/usb/omap_control_usb.h>
25#include <linux/wl12xx.h> 24#include <linux/wl12xx.h>
26 25
27#include <asm/mach-types.h> 26#include <asm/mach-types.h>
@@ -255,49 +254,6 @@ static inline void omap_init_camera(void)
255#endif 254#endif
256} 255}
257 256
258#if IS_ENABLED(CONFIG_OMAP_CONTROL_USB)
259static struct omap_control_usb_platform_data omap4_control_usb_pdata = {
260 .type = 1,
261};
262
263struct resource omap4_control_usb_res[] = {
264 {
265 .name = "control_dev_conf",
266 .start = 0x4a002300,
267 .end = 0x4a002303,
268 .flags = IORESOURCE_MEM,
269 },
270 {
271 .name = "otghs_control",
272 .start = 0x4a00233c,
273 .end = 0x4a00233f,
274 .flags = IORESOURCE_MEM,
275 },
276};
277
278static struct platform_device omap4_control_usb = {
279 .name = "omap-control-usb",
280 .id = -1,
281 .dev = {
282 .platform_data = &omap4_control_usb_pdata,
283 },
284 .num_resources = 2,
285 .resource = omap4_control_usb_res,
286};
287
288static inline void __init omap_init_control_usb(void)
289{
290 if (!cpu_is_omap44xx())
291 return;
292
293 if (platform_device_register(&omap4_control_usb))
294 pr_err("Error registering omap_control_usb device\n");
295}
296
297#else
298static inline void omap_init_control_usb(void) { }
299#endif /* CONFIG_OMAP_CONTROL_USB */
300
301int __init omap4_keyboard_init(struct omap4_keypad_platform_data 257int __init omap4_keyboard_init(struct omap4_keypad_platform_data
302 *sdp4430_keypad_data, struct omap_board_data *bdata) 258 *sdp4430_keypad_data, struct omap_board_data *bdata)
303{ 259{
@@ -687,7 +643,6 @@ static int __init omap2_init_devices(void)
687 omap_init_mbox(); 643 omap_init_mbox();
688 /* If dtb is there, the devices will be created dynamically */ 644 /* If dtb is there, the devices will be created dynamically */
689 if (!of_have_populated_dt()) { 645 if (!of_have_populated_dt()) {
690 omap_init_control_usb();
691 omap_init_dmic(); 646 omap_init_dmic();
692 omap_init_mcpdm(); 647 omap_init_mcpdm();
693 omap_init_mcspi(); 648 omap_init_mcspi();
diff --git a/arch/arm/mach-omap2/usb-host.c b/arch/arm/mach-omap2/usb-host.c
index aa27d7f5cbb7..544c92bf60cc 100644
--- a/arch/arm/mach-omap2/usb-host.c
+++ b/arch/arm/mach-omap2/usb-host.c
@@ -188,125 +188,6 @@ static void __init setup_ehci_io_mux(const enum usbhs_omap_port_mode *port_mode)
188 return; 188 return;
189} 189}
190 190
191static
192void __init setup_4430ehci_io_mux(const enum usbhs_omap_port_mode *port_mode)
193{
194 switch (port_mode[0]) {
195 case OMAP_EHCI_PORT_MODE_PHY:
196 omap_mux_init_signal("usbb1_ulpiphy_stp",
197 OMAP_PIN_OUTPUT);
198 omap_mux_init_signal("usbb1_ulpiphy_clk",
199 OMAP_PIN_INPUT_PULLDOWN);
200 omap_mux_init_signal("usbb1_ulpiphy_dir",
201 OMAP_PIN_INPUT_PULLDOWN);
202 omap_mux_init_signal("usbb1_ulpiphy_nxt",
203 OMAP_PIN_INPUT_PULLDOWN);
204 omap_mux_init_signal("usbb1_ulpiphy_dat0",
205 OMAP_PIN_INPUT_PULLDOWN);
206 omap_mux_init_signal("usbb1_ulpiphy_dat1",
207 OMAP_PIN_INPUT_PULLDOWN);
208 omap_mux_init_signal("usbb1_ulpiphy_dat2",
209 OMAP_PIN_INPUT_PULLDOWN);
210 omap_mux_init_signal("usbb1_ulpiphy_dat3",
211 OMAP_PIN_INPUT_PULLDOWN);
212 omap_mux_init_signal("usbb1_ulpiphy_dat4",
213 OMAP_PIN_INPUT_PULLDOWN);
214 omap_mux_init_signal("usbb1_ulpiphy_dat5",
215 OMAP_PIN_INPUT_PULLDOWN);
216 omap_mux_init_signal("usbb1_ulpiphy_dat6",
217 OMAP_PIN_INPUT_PULLDOWN);
218 omap_mux_init_signal("usbb1_ulpiphy_dat7",
219 OMAP_PIN_INPUT_PULLDOWN);
220 break;
221 case OMAP_EHCI_PORT_MODE_TLL:
222 omap_mux_init_signal("usbb1_ulpitll_stp",
223 OMAP_PIN_INPUT_PULLUP);
224 omap_mux_init_signal("usbb1_ulpitll_clk",
225 OMAP_PIN_INPUT_PULLDOWN);
226 omap_mux_init_signal("usbb1_ulpitll_dir",
227 OMAP_PIN_INPUT_PULLDOWN);
228 omap_mux_init_signal("usbb1_ulpitll_nxt",
229 OMAP_PIN_INPUT_PULLDOWN);
230 omap_mux_init_signal("usbb1_ulpitll_dat0",
231 OMAP_PIN_INPUT_PULLDOWN);
232 omap_mux_init_signal("usbb1_ulpitll_dat1",
233 OMAP_PIN_INPUT_PULLDOWN);
234 omap_mux_init_signal("usbb1_ulpitll_dat2",
235 OMAP_PIN_INPUT_PULLDOWN);
236 omap_mux_init_signal("usbb1_ulpitll_dat3",
237 OMAP_PIN_INPUT_PULLDOWN);
238 omap_mux_init_signal("usbb1_ulpitll_dat4",
239 OMAP_PIN_INPUT_PULLDOWN);
240 omap_mux_init_signal("usbb1_ulpitll_dat5",
241 OMAP_PIN_INPUT_PULLDOWN);
242 omap_mux_init_signal("usbb1_ulpitll_dat6",
243 OMAP_PIN_INPUT_PULLDOWN);
244 omap_mux_init_signal("usbb1_ulpitll_dat7",
245 OMAP_PIN_INPUT_PULLDOWN);
246 break;
247 case OMAP_USBHS_PORT_MODE_UNUSED:
248 default:
249 break;
250 }
251 switch (port_mode[1]) {
252 case OMAP_EHCI_PORT_MODE_PHY:
253 omap_mux_init_signal("usbb2_ulpiphy_stp",
254 OMAP_PIN_OUTPUT);
255 omap_mux_init_signal("usbb2_ulpiphy_clk",
256 OMAP_PIN_INPUT_PULLDOWN);
257 omap_mux_init_signal("usbb2_ulpiphy_dir",
258 OMAP_PIN_INPUT_PULLDOWN);
259 omap_mux_init_signal("usbb2_ulpiphy_nxt",
260 OMAP_PIN_INPUT_PULLDOWN);
261 omap_mux_init_signal("usbb2_ulpiphy_dat0",
262 OMAP_PIN_INPUT_PULLDOWN);
263 omap_mux_init_signal("usbb2_ulpiphy_dat1",
264 OMAP_PIN_INPUT_PULLDOWN);
265 omap_mux_init_signal("usbb2_ulpiphy_dat2",
266 OMAP_PIN_INPUT_PULLDOWN);
267 omap_mux_init_signal("usbb2_ulpiphy_dat3",
268 OMAP_PIN_INPUT_PULLDOWN);
269 omap_mux_init_signal("usbb2_ulpiphy_dat4",
270 OMAP_PIN_INPUT_PULLDOWN);
271 omap_mux_init_signal("usbb2_ulpiphy_dat5",
272 OMAP_PIN_INPUT_PULLDOWN);
273 omap_mux_init_signal("usbb2_ulpiphy_dat6",
274 OMAP_PIN_INPUT_PULLDOWN);
275 omap_mux_init_signal("usbb2_ulpiphy_dat7",
276 OMAP_PIN_INPUT_PULLDOWN);
277 break;
278 case OMAP_EHCI_PORT_MODE_TLL:
279 omap_mux_init_signal("usbb2_ulpitll_stp",
280 OMAP_PIN_INPUT_PULLUP);
281 omap_mux_init_signal("usbb2_ulpitll_clk",
282 OMAP_PIN_INPUT_PULLDOWN);
283 omap_mux_init_signal("usbb2_ulpitll_dir",
284 OMAP_PIN_INPUT_PULLDOWN);
285 omap_mux_init_signal("usbb2_ulpitll_nxt",
286 OMAP_PIN_INPUT_PULLDOWN);
287 omap_mux_init_signal("usbb2_ulpitll_dat0",
288 OMAP_PIN_INPUT_PULLDOWN);
289 omap_mux_init_signal("usbb2_ulpitll_dat1",
290 OMAP_PIN_INPUT_PULLDOWN);
291 omap_mux_init_signal("usbb2_ulpitll_dat2",
292 OMAP_PIN_INPUT_PULLDOWN);
293 omap_mux_init_signal("usbb2_ulpitll_dat3",
294 OMAP_PIN_INPUT_PULLDOWN);
295 omap_mux_init_signal("usbb2_ulpitll_dat4",
296 OMAP_PIN_INPUT_PULLDOWN);
297 omap_mux_init_signal("usbb2_ulpitll_dat5",
298 OMAP_PIN_INPUT_PULLDOWN);
299 omap_mux_init_signal("usbb2_ulpitll_dat6",
300 OMAP_PIN_INPUT_PULLDOWN);
301 omap_mux_init_signal("usbb2_ulpitll_dat7",
302 OMAP_PIN_INPUT_PULLDOWN);
303 break;
304 case OMAP_USBHS_PORT_MODE_UNUSED:
305 default:
306 break;
307 }
308}
309
310static void __init setup_ohci_io_mux(const enum usbhs_omap_port_mode *port_mode) 191static void __init setup_ohci_io_mux(const enum usbhs_omap_port_mode *port_mode)
311{ 192{
312 switch (port_mode[0]) { 193 switch (port_mode[0]) {
@@ -404,78 +285,6 @@ static void __init setup_ohci_io_mux(const enum usbhs_omap_port_mode *port_mode)
404 } 285 }
405} 286}
406 287
407static
408void __init setup_4430ohci_io_mux(const enum usbhs_omap_port_mode *port_mode)
409{
410 switch (port_mode[0]) {
411 case OMAP_OHCI_PORT_MODE_PHY_6PIN_DATSE0:
412 case OMAP_OHCI_PORT_MODE_PHY_6PIN_DPDM:
413 case OMAP_OHCI_PORT_MODE_TLL_6PIN_DATSE0:
414 case OMAP_OHCI_PORT_MODE_TLL_6PIN_DPDM:
415 omap_mux_init_signal("usbb1_mm_rxdp",
416 OMAP_PIN_INPUT_PULLDOWN);
417 omap_mux_init_signal("usbb1_mm_rxdm",
418 OMAP_PIN_INPUT_PULLDOWN);
419
420 case OMAP_OHCI_PORT_MODE_PHY_4PIN_DPDM:
421 case OMAP_OHCI_PORT_MODE_TLL_4PIN_DPDM:
422 omap_mux_init_signal("usbb1_mm_rxrcv",
423 OMAP_PIN_INPUT_PULLDOWN);
424
425 case OMAP_OHCI_PORT_MODE_PHY_3PIN_DATSE0:
426 case OMAP_OHCI_PORT_MODE_TLL_3PIN_DATSE0:
427 omap_mux_init_signal("usbb1_mm_txen",
428 OMAP_PIN_INPUT_PULLDOWN);
429
430
431 case OMAP_OHCI_PORT_MODE_TLL_2PIN_DATSE0:
432 case OMAP_OHCI_PORT_MODE_TLL_2PIN_DPDM:
433 omap_mux_init_signal("usbb1_mm_txdat",
434 OMAP_PIN_INPUT_PULLDOWN);
435 omap_mux_init_signal("usbb1_mm_txse0",
436 OMAP_PIN_INPUT_PULLDOWN);
437 break;
438
439 case OMAP_USBHS_PORT_MODE_UNUSED:
440 default:
441 break;
442 }
443
444 switch (port_mode[1]) {
445 case OMAP_OHCI_PORT_MODE_PHY_6PIN_DATSE0:
446 case OMAP_OHCI_PORT_MODE_PHY_6PIN_DPDM:
447 case OMAP_OHCI_PORT_MODE_TLL_6PIN_DATSE0:
448 case OMAP_OHCI_PORT_MODE_TLL_6PIN_DPDM:
449 omap_mux_init_signal("usbb2_mm_rxdp",
450 OMAP_PIN_INPUT_PULLDOWN);
451 omap_mux_init_signal("usbb2_mm_rxdm",
452 OMAP_PIN_INPUT_PULLDOWN);
453
454 case OMAP_OHCI_PORT_MODE_PHY_4PIN_DPDM:
455 case OMAP_OHCI_PORT_MODE_TLL_4PIN_DPDM:
456 omap_mux_init_signal("usbb2_mm_rxrcv",
457 OMAP_PIN_INPUT_PULLDOWN);
458
459 case OMAP_OHCI_PORT_MODE_PHY_3PIN_DATSE0:
460 case OMAP_OHCI_PORT_MODE_TLL_3PIN_DATSE0:
461 omap_mux_init_signal("usbb2_mm_txen",
462 OMAP_PIN_INPUT_PULLDOWN);
463
464
465 case OMAP_OHCI_PORT_MODE_TLL_2PIN_DATSE0:
466 case OMAP_OHCI_PORT_MODE_TLL_2PIN_DPDM:
467 omap_mux_init_signal("usbb2_mm_txdat",
468 OMAP_PIN_INPUT_PULLDOWN);
469 omap_mux_init_signal("usbb2_mm_txse0",
470 OMAP_PIN_INPUT_PULLDOWN);
471 break;
472
473 case OMAP_USBHS_PORT_MODE_UNUSED:
474 default:
475 break;
476 }
477}
478
479void __init usbhs_init(struct usbhs_omap_platform_data *pdata) 288void __init usbhs_init(struct usbhs_omap_platform_data *pdata)
480{ 289{
481 struct omap_hwmod *uhh_hwm, *tll_hwm; 290 struct omap_hwmod *uhh_hwm, *tll_hwm;
@@ -489,9 +298,6 @@ void __init usbhs_init(struct usbhs_omap_platform_data *pdata)
489 if (omap_rev() <= OMAP3430_REV_ES2_1) 298 if (omap_rev() <= OMAP3430_REV_ES2_1)
490 pdata->single_ulpi_bypass = true; 299 pdata->single_ulpi_bypass = true;
491 300
492 } else if (cpu_is_omap44xx()) {
493 setup_4430ehci_io_mux(pdata->port_mode);
494 setup_4430ohci_io_mux(pdata->port_mode);
495 } 301 }
496 302
497 uhh_hwm = omap_hwmod_lookup(USBHS_UHH_HWMODNAME); 303 uhh_hwm = omap_hwmod_lookup(USBHS_UHH_HWMODNAME);
diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index 3242a554ad6b..8c4de2708cf2 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -85,9 +85,6 @@ void __init usb_musb_init(struct omap_musb_board_data *musb_board_data)
85 musb_plat.mode = board_data->mode; 85 musb_plat.mode = board_data->mode;
86 musb_plat.extvbus = board_data->extvbus; 86 musb_plat.extvbus = board_data->extvbus;
87 87
88 if (cpu_is_omap44xx())
89 musb_plat.has_mailbox = true;
90
91 if (soc_is_am35xx()) { 88 if (soc_is_am35xx()) {
92 oh_name = "am35x_otg_hs"; 89 oh_name = "am35x_otg_hs";
93 name = "musb-am35x"; 90 name = "musb-am35x";