]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
OMAP1: OMAP_TAG_USB buildfix (OSK)
authorDavid Brownell <dbrownell@users.sourceforge.net>
Wed, 11 Mar 2009 10:20:05 +0000 (10:20 +0000)
committerTony Lindgren <tony@atomide.com>
Wed, 11 Mar 2009 16:32:09 +0000 (09:32 -0700)
Build fix:

  CC      arch/arm/mach-omap1/board-osk.o
  arch/arm/mach-omap1/board-osk.c: In function 'osk_mistral_init':
  arch/arm/mach-omap1/board-osk.c:512: error: implicit declaration of function 'omap_usb_init'
  make[1]: *** [arch/arm/mach-omap1/board-osk.o] Error 1

The error is twofold.  First, USB is on the mainboard, not the Mistral card;
that's specific to the OSK.  Second, header goofage -- hurts all OMAP1 boards.

I'm puzzled by the notion tha the "OMAP1: get rid of OMAP_TAG_USB" patch could
have been compile-tested.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap1/board-osk.c
arch/arm/plat-omap/include/mach/usb.h

index 99913ac9adf60d612a167eccd9f5b4aad9874788..e5ebc9d63cecf220c81bb65a9e6293bc546cdb8d 100644 (file)
@@ -509,7 +509,6 @@ static void __init osk_mistral_init(void)
        i2c_register_board_info(1, mistral_i2c_board_info,
                        ARRAY_SIZE(mistral_i2c_board_info));
 
-       omap_usb_init(&osk_usb_config);
        platform_add_devices(mistral_devices, ARRAY_SIZE(mistral_devices));
 }
 #else
@@ -541,6 +540,8 @@ static void __init osk_init(void)
        l |= (3 << 1);
        omap_writel(l, USB_TRANSCEIVER_CTRL);
 
+       omap_usb_init(&osk_usb_config);
+
        /* irq for tps65010 chip */
        /* bootloader effectively does:  omap_cfg_reg(U19_1610_MPUIO1); */
        if (gpio_request(OMAP_MPUIO(1), "tps65010") == 0)
index 1a36eaf66b9a5ca3ce9b62241acda06714f48c15..f6d334ffaae85987e6e74b9576463a89a1bde821 100644 (file)
@@ -33,9 +33,7 @@ extern void usb_musb_init(void);
 static inline void usb_musb_init(void)
 {
 }
-#endif
-
-void omap_usb_init(struct omap_usb_config *pdata);
+#endif /* !OMAP1 && !MUSB */
 
 #if defined(CONFIG_USB_EHCI_HCD) || defined(CONFIG_USB_EHCI_HCD_MODULE)
 extern void usb_ehci_init(void);
@@ -43,9 +41,11 @@ extern void usb_ehci_init(void);
 static inline void usb_ehci_init(void)
 {
 }
-#endif
+#endif /* !OMAP1 && !EHCI */
 
-#endif
+#endif /* !OMAP1 */
+
+void omap_usb_init(struct omap_usb_config *pdata);
 
 /*-------------------------------------------------------------------------*/