]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
board: ti: dra7-evm: remove USB platform code
authorJean-Jacques Hiblot <jjhiblot@ti.com>
Thu, 29 Nov 2018 09:57:46 +0000 (10:57 +0100)
committerMarek Vasut <marex@denx.de>
Fri, 7 Dec 2018 15:31:46 +0000 (16:31 +0100)
Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
board/ti/dra7xx/evm.c

index 0ddca29ae607f4569148326d682bdcba16e643d2..d69641e3a055ed80e4de6dfda022a06a05d33a52 100644 (file)
@@ -915,110 +915,6 @@ const struct mmc_platform_fixups *platform_fixups_mmc(uint32_t addr)
 }
 #endif
 
-#if defined(CONFIG_USB_DWC3) && !CONFIG_IS_ENABLED(DM_USB)
-static struct dwc3_device usb_otg_ss1 = {
-       .maximum_speed = USB_SPEED_SUPER,
-       .base = DRA7_USB_OTG_SS1_BASE,
-       .tx_fifo_resize = false,
-       .index = 0,
-};
-
-static struct dwc3_omap_device usb_otg_ss1_glue = {
-       .base = (void *)DRA7_USB_OTG_SS1_GLUE_BASE,
-       .utmi_mode = DWC3_OMAP_UTMI_MODE_SW,
-       .index = 0,
-};
-
-static struct ti_usb_phy_device usb_phy1_device = {
-       .pll_ctrl_base = (void *)DRA7_USB3_PHY1_PLL_CTRL,
-       .usb2_phy_power = (void *)DRA7_USB2_PHY1_POWER,
-       .usb3_phy_power = (void *)DRA7_USB3_PHY1_POWER,
-       .index = 0,
-};
-
-static struct dwc3_device usb_otg_ss2 = {
-       .maximum_speed = USB_SPEED_SUPER,
-       .base = DRA7_USB_OTG_SS2_BASE,
-       .tx_fifo_resize = false,
-       .index = 1,
-};
-
-static struct dwc3_omap_device usb_otg_ss2_glue = {
-       .base = (void *)DRA7_USB_OTG_SS2_GLUE_BASE,
-       .utmi_mode = DWC3_OMAP_UTMI_MODE_SW,
-       .index = 1,
-};
-
-static struct ti_usb_phy_device usb_phy2_device = {
-       .usb2_phy_power = (void *)DRA7_USB2_PHY2_POWER,
-       .index = 1,
-};
-
-int board_usb_init(int index, enum usb_init_type init)
-{
-       enable_usb_clocks(index);
-       switch (index) {
-       case 0:
-               if (init == USB_INIT_DEVICE) {
-                       usb_otg_ss1.dr_mode = USB_DR_MODE_PERIPHERAL;
-                       usb_otg_ss1_glue.vbus_id_status = OMAP_DWC3_VBUS_VALID;
-               } else {
-                       usb_otg_ss1.dr_mode = USB_DR_MODE_HOST;
-                       usb_otg_ss1_glue.vbus_id_status = OMAP_DWC3_ID_GROUND;
-               }
-
-               ti_usb_phy_uboot_init(&usb_phy1_device);
-               dwc3_omap_uboot_init(&usb_otg_ss1_glue);
-               dwc3_uboot_init(&usb_otg_ss1);
-               break;
-       case 1:
-               if (init == USB_INIT_DEVICE) {
-                       usb_otg_ss2.dr_mode = USB_DR_MODE_PERIPHERAL;
-                       usb_otg_ss2_glue.vbus_id_status = OMAP_DWC3_VBUS_VALID;
-               } else {
-                       usb_otg_ss2.dr_mode = USB_DR_MODE_HOST;
-                       usb_otg_ss2_glue.vbus_id_status = OMAP_DWC3_ID_GROUND;
-               }
-
-               ti_usb_phy_uboot_init(&usb_phy2_device);
-               dwc3_omap_uboot_init(&usb_otg_ss2_glue);
-               dwc3_uboot_init(&usb_otg_ss2);
-               break;
-       default:
-               printf("Invalid Controller Index\n");
-       }
-
-       return 0;
-}
-
-int board_usb_cleanup(int index, enum usb_init_type init)
-{
-       switch (index) {
-       case 0:
-       case 1:
-               ti_usb_phy_uboot_exit(index);
-               dwc3_uboot_exit(index);
-               dwc3_omap_uboot_exit(index);
-               break;
-       default:
-               printf("Invalid Controller Index\n");
-       }
-       disable_usb_clocks(index);
-       return 0;
-}
-
-int usb_gadget_handle_interrupts(int index)
-{
-       u32 status;
-
-       status = dwc3_omap_uboot_interrupt_status(index);
-       if (status)
-               dwc3_uboot_handle_interrupt(index);
-
-       return 0;
-}
-#endif
-
 #if defined(CONFIG_SPL_BUILD) && defined(CONFIG_SPL_OS_BOOT)
 int spl_start_uboot(void)
 {