summaryrefslogtreecommitdiffstats
path: root/board/ti/am57xx/board.c
diff options
context:
space:
mode:
authorSteve Kipisz <s-kipisz2@ti.com>2016-04-08 17:01:29 -0500
committerTom Rini <trini@konsulko.com>2016-04-18 17:11:32 -0400
commitc020d355c45ed40fe12af72ae5487527167fafd5 (patch)
tree6dbe9735dda9be57ac8e0fc45f0778b6095c4d4e /board/ti/am57xx/board.c
parent5f405e7fa0c4baf4cc57a82d2fcddb86789cfaed (diff)
downloadblackbird-obmc-uboot-c020d355c45ed40fe12af72ae5487527167fafd5.tar.gz
blackbird-obmc-uboot-c020d355c45ed40fe12af72ae5487527167fafd5.zip
board: ti: am57xx: Add support for am572x idk in SPL
The AM572x-IDK board (Industrial Dev Kit) is a board based on TI's AM5728x SOC which has a dual core 1.5GHz A15 processor. This board is a development platform for the Industrial market with: - 2GB of DDR3L - Dual 1Gbps Ethernet - HDMI, - PRU-ICSS - uSD - 16GB eMMC - CAN - RS-485 - PCIe - USB3.0 - Video Input Port - Industrial IO port and expansion connector The link to the data sheet and TRM can be found here: http://www.ti.com/product/AM5728 NOTE: DT support is still pending upstream kernel acceptance but we should be able to get the base system support with this patch. Signed-off-by: Schuyler Patton <spatton@ti.com> Signed-off-by: Steve Kipisz <s-kipisz2@ti.com> Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'board/ti/am57xx/board.c')
-rw-r--r--board/ti/am57xx/board.c32
1 files changed, 29 insertions, 3 deletions
diff --git a/board/ti/am57xx/board.c b/board/ti/am57xx/board.c
index 02925f639f..1762089613 100644
--- a/board/ti/am57xx/board.c
+++ b/board/ti/am57xx/board.c
@@ -35,6 +35,7 @@
#define board_is_x15() board_ti_is("BBRDX15_")
#define board_is_am572x_evm() board_ti_is("AM572PM_")
+#define board_is_am572x_idk() board_ti_is("AM572IDK")
#ifdef CONFIG_DRIVER_TI_CPSW
#include <cpsw.h>
@@ -278,6 +279,8 @@ void do_board_detect(void)
bname = "BeagleBoard X15";
else if (board_is_am572x_evm())
bname = "AM572x EVM";
+ else if (board_is_am572x_idk())
+ bname = "AM572x IDK";
if (bname)
snprintf(sysinfo.board_string, SYSINFO_BOARD_NAME_MAX_LEN,
@@ -296,6 +299,8 @@ static void setup_board_eeprom_env(void)
if (board_is_am572x_evm())
name = "am57xx_evm";
+ else if (board_is_am572x_idk())
+ name = "am572x_idk";
else
printf("Unidentified board claims %s in eeprom header\n",
board_ti_get_name());
@@ -343,9 +348,24 @@ void set_muxconf_regs(void)
#ifdef CONFIG_IODELAY_RECALIBRATION
void recalibrate_iodelay(void)
{
- __recalibrate_iodelay(core_padconf_array_essential,
- ARRAY_SIZE(core_padconf_array_essential),
- iodelay_cfg_array, ARRAY_SIZE(iodelay_cfg_array));
+ const struct pad_conf_entry *pconf;
+ const struct iodelay_cfg_entry *iod;
+ int pconf_sz, iod_sz;
+
+ if (board_is_am572x_idk()) {
+ pconf = core_padconf_array_essential_am572x_idk;
+ pconf_sz = ARRAY_SIZE(core_padconf_array_essential_am572x_idk);
+ iod = iodelay_cfg_array_am572x_idk;
+ iod_sz = ARRAY_SIZE(iodelay_cfg_array_am572x_idk);
+ } else {
+ /* Common for X15/GPEVM */
+ pconf = core_padconf_array_essential_x15;
+ pconf_sz = ARRAY_SIZE(core_padconf_array_essential_x15);
+ iod = iodelay_cfg_array_x15;
+ iod_sz = ARRAY_SIZE(iodelay_cfg_array_x15);
+ }
+
+ __recalibrate_iodelay(pconf, pconf_sz, iod, iod_sz);
}
#endif
@@ -605,6 +625,12 @@ int board_eth_init(bd_t *bis)
ctrl_val |= 0x22;
writel(ctrl_val, (*ctrl)->control_core_control_io1);
+ /* The phy address for the AM572x IDK are different than x15 */
+ if (board_is_am572x_idk()) {
+ cpsw_data.slave_data[0].phy_addr = 0;
+ cpsw_data.slave_data[1].phy_addr = 1;
+ }
+
ret = cpsw_register(&cpsw_data);
if (ret < 0)
printf("Error %d registering CPSW switch\n", ret);
OpenPOWER on IntegriCloud