]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - board/bachmann/ot1200/ot1200.c
ot1200: add sata support
[karo-tx-uboot.git] / board / bachmann / ot1200 / ot1200.c
index 0d5ede5ca89fc0aa8698086b0a0040185e049482..acf95cb372ac2a48c574bce6005c3bce4575f4c4 100644 (file)
@@ -12,6 +12,7 @@
 #include <malloc.h>
 #include <asm/arch/mx6-pins.h>
 #include <asm/imx-common/iomux-v3.h>
+#include <asm/imx-common/sata.h>
 #include <asm/imx-common/mxc_i2c.h>
 #include <asm/imx-common/boot_mode.h>
 #include <asm/arch/crm_regs.h>
@@ -98,6 +99,11 @@ static void setup_iomux_spi(void)
        imx_iomux_v3_setup_multiple_pads(ecspi1_pads, ARRAY_SIZE(ecspi1_pads));
 }
 
+int board_spi_cs_gpio(unsigned bus, unsigned cs)
+{
+       return (bus == 2 && cs == 0) ? (IMX_GPIO_NR(1, 3)) : -1;
+}
+
 int board_early_init_f(void)
 {
        setup_iomux_uart();
@@ -225,6 +231,10 @@ int board_init(void)
        /* enable ecspi3 clocks */
        enable_cspi_clock(1, 2);
 
+#ifdef CONFIG_CMD_SATA
+       setup_sata();
+#endif
+
        return 0;
 }