dm: video: adjust struct vidconsole_priv description
[oweals/u-boot.git] / board / technexion / tao3530 / tao3530.c
index 814537bd7a899bc140b178583d1d6ef696da7a48..22d26e550e01d5c7693bc601e4093b41464cbb2a 100644 (file)
@@ -1,8 +1,7 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * Maintainer :
  *      Tapani Utriainen <linuxfae@technexion.com>
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 #include <common.h>
 #include <netdev.h>
@@ -75,6 +74,18 @@ out:
  */
 void get_board_mem_timings(struct board_sdrc_timings *timings)
 {
+#if defined(CONFIG_SYS_BOARD_OMAP3_HA)
+       /*
+        * Switch baseboard LED to red upon power-on
+        */
+       MUX_OMAP3_HA();
+
+       /* Request a gpio before using it */
+       gpio_request(111, "");
+       /* Sets the gpio as output and its value to 1, switch LED to red */
+       gpio_direction_output(111, 1);
+#endif
+
        if (tao3530_revision() < 3) {
                /* 256MB / Bank */
                timings->mcfg = MCFG(256 << 20, 14);    /* RAS-width 14 */
@@ -131,7 +142,24 @@ int misc_init_r(void)
        writel(GPIO31 | GPIO30 | GPIO29 | GPIO28 | GPIO22 | GPIO21 |
               GPIO15 | GPIO14 | GPIO13 | GPIO12, &gpio5_base->setdataout);
 
-       dieid_num_r();
+       switch (tao3530_revision()) {
+       case 0:
+               puts("TAO-3530 REV Reserve 1\n");
+               break;
+       case 1:
+               puts("TAO-3530 REV Reserve 2\n");
+               break;
+       case 2:
+               puts("TAO-3530 REV Cx\n");
+               break;
+       case 3:
+               puts("TAO-3530 REV Ax/Bx\n");
+               break;
+       default:
+               puts("Unknown board revision\n");
+       }
+
+       omap_die_id_display();
 
        return 0;
 }
@@ -145,9 +173,12 @@ int misc_init_r(void)
 void set_muxconf_regs(void)
 {
        MUX_TAO3530();
+#if defined(CONFIG_SYS_BOARD_OMAP3_HA)
+       MUX_OMAP3_HA();
+#endif
 }
 
-#if defined(CONFIG_GENERIC_MMC) && !defined(CONFIG_SPL_BUILD)
+#if defined(CONFIG_MMC)
 int board_mmc_init(bd_t *bis)
 {
        omap_mmc_init(0, 0, 0, -1, -1);
@@ -156,7 +187,14 @@ int board_mmc_init(bd_t *bis)
 }
 #endif
 
-#if defined(CONFIG_USB_EHCI) && !defined(CONFIG_SPL_BUILD)
+#if defined(CONFIG_MMC)
+void board_mmc_power_init(void)
+{
+       twl4030_power_mmc_init(0);
+}
+#endif
+
+#if defined(CONFIG_USB_EHCI_HCD) && !defined(CONFIG_SPL_BUILD)
 /* Call usb_stop() before starting the kernel */
 void show_boot_progress(int val)
 {
@@ -180,4 +218,4 @@ int ehci_hcd_stop(int index)
 {
        return omap_ehci_hcd_stop();
 }
-#endif /* CONFIG_USB_EHCI */
+#endif /* CONFIG_USB_EHCI_HCD */