diff options
-rw-r--r-- | board/freescale/mx6qsabreauto/mx6qsabreauto.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/board/freescale/mx6qsabreauto/mx6qsabreauto.c b/board/freescale/mx6qsabreauto/mx6qsabreauto.c index f34c796..e12c5bc 100644 --- a/board/freescale/mx6qsabreauto/mx6qsabreauto.c +++ b/board/freescale/mx6qsabreauto/mx6qsabreauto.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2012-2014 Freescale Semiconductor, Inc. + * Copyright (C) 2012-2015 Freescale Semiconductor, Inc. * * Author: Fabio Estevam <fabio.estevam@freescale.com> * @@ -111,6 +111,7 @@ iomux_v3_cfg_t const enet_pads[] = { MX6_PAD_RGMII_RD2__RGMII_RD2 | MUX_PAD_CTRL(ENET_PAD_CTRL), MX6_PAD_RGMII_RD3__RGMII_RD3 | MUX_PAD_CTRL(ENET_PAD_CTRL), MX6_PAD_RGMII_RX_CTL__RGMII_RX_CTL | MUX_PAD_CTRL(ENET_PAD_CTRL), + MX6_PAD_GPIO_16__ENET_REF_CLK | MUX_PAD_CTRL(ENET_PAD_CTRL), }; /* I2C2 PMIC, iPod, Tuner, Codec, Touch, HDMI EDID, MIPI CSI2 card */ @@ -857,6 +858,7 @@ int overwrite_console(void) return 1; } +#ifdef CONFIG_FEC_MXC int board_eth_init(bd_t *bis) { setup_iomux_enet(); @@ -864,6 +866,19 @@ int board_eth_init(bd_t *bis) return cpu_eth_init(bis); } +static int setup_fec(void) +{ + int ret; + + mxc_iomux_set_gpr_register(1, 21, 1, 1); + ret = enable_fec_anatop_clock(0, ENET_125MHz); + if (ret) + return ret; + + return 0; +} +#endif + #define BOARD_REV_B 0x200 #define BOARD_REV_A 0x100 @@ -970,6 +985,10 @@ int board_late_init(void) board_late_mmc_env_init(); #endif +#ifdef CONFIG_FEC_MXC + setup_fec(); +#endif + return 0; } |