]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
ti: AM43xx: board: Detect AM43xx HS EVM
authorMadan Srinivas <madans@ti.com>
Fri, 20 May 2016 00:10:48 +0000 (19:10 -0500)
committerTom Rini <trini@konsulko.com>
Fri, 27 May 2016 19:41:35 +0000 (15:41 -0400)
Adds code to detect AM43xx HS EVMS - the string in the
I2C EEPROM for HS EVMs differs from GP EVMs. Adds code to
for evm detection, regardless of whether the evm is for
GP or HS parts, and updates board init to use that.

Modifies findfdt command to pick up am437x-gp-evm.dtb for
the HS EVMs also, as the boards are similar except for
some security specific changes around power supply and
enclosure protection.

Signed-off-by: Madan Srinivas <madans@ti.com>
Signed-off-by: Daniel Allred <d-allred@ti.com>
Signed-off-by: Andreas Dannenberg <dannenberg@ti.com>
Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
board/ti/am43xx/board.c
board/ti/am43xx/board.h
board/ti/am43xx/mux.c
include/configs/am43xx_evm.h

index d208d2fa89181ea8600e466e30db82cbceb21a39..724710763d6c6fe82f12261d80bd4118ca81571c 100644 (file)
@@ -341,7 +341,7 @@ const struct dpll_params *get_dpll_ddr_params(void)
 
        if (board_is_eposevm())
                return &epos_evm_dpll_ddr[ind];
-       else if (board_is_gpevm() || board_is_sk())
+       else if (board_is_evm() || board_is_sk())
                return &gp_evm_dpll_ddr;
        else if (board_is_idk())
                return &idk_dpll_ddr;
@@ -553,7 +553,7 @@ void sdram_init(void)
                enable_vtt_regulator();
                config_ddr(0, &ioregs_ddr3, NULL, NULL,
                           &ddr3_emif_regs_400Mhz_beta, 0);
-       } else if (board_is_gpevm()) {
+       } else if (board_is_evm()) {
                enable_vtt_regulator();
                config_ddr(0, &ioregs_ddr3, NULL, NULL,
                           &ddr3_emif_regs_400Mhz, 0);
index 2cf7a7751d414e53855ebfdb7e73bc4c0fdb4c03..3f93d1372702625970f0cdc1881cff525d99f653 100644 (file)
@@ -37,14 +37,24 @@ static inline int board_is_idk(void)
        return board_ti_is("AM43_IDK");
 }
 
+static inline int board_is_hsevm(void)
+{
+       return board_ti_is("AM43XXHS");
+}
+
+static inline int board_is_evm(void)
+{
+       return board_is_gpevm() || board_is_hsevm();
+}
+
 static inline int board_is_evm_14_or_later(void)
 {
-       return (board_is_gpevm() && strncmp("1.4", board_ti_get_rev(), 3) <= 0);
+       return board_is_evm() && strncmp("1.4", board_ti_get_rev(), 3) <= 0;
 }
 
 static inline int board_is_evm_12_or_later(void)
 {
-       return (board_is_gpevm() && strncmp("1.2", board_ti_get_rev(), 3) <= 0);
+       return board_is_evm() && strncmp("1.2", board_ti_get_rev(), 3) <= 0;
 }
 
 void enable_uart0_pin_mux(void);
index e03b1bcfaaa8b420371c7987b19db23b3430f26a..f26b21e8695e36b70173bb5b92d337c21e27fb23 100644 (file)
@@ -126,7 +126,7 @@ void enable_board_pin_mux(void)
        configure_module_pin_mux(i2c0_pin_mux);
        configure_module_pin_mux(mdio_pin_mux);
 
-       if (board_is_gpevm()) {
+       if (board_is_evm()) {
                configure_module_pin_mux(gpio5_7_pin_mux);
                configure_module_pin_mux(rgmii1_pin_mux);
 #if defined(CONFIG_NAND)
index 8a48a9aa37b4a8d280637d7c63dee12b9fa07df3..a54303df5c82b2921460199f135e6d2ff03ae0fb 100644 (file)
                        "setenv fdtfile am43x-epos-evm.dtb; fi; " \
                "if test $board_name = AM43__GP; then " \
                        "setenv fdtfile am437x-gp-evm.dtb; fi; " \
+               "if test $board_name = AM43XXHS; then " \
+                       "setenv fdtfile am437x-gp-evm.dtb; fi; " \
                "if test $board_name = AM43__SK; then " \
                        "setenv fdtfile am437x-sk-evm.dtb; fi; " \
                "if test $board_name = AM43_IDK; then " \