Re: [U-Boot] Issues coupling am335x with VSC8601 PHY
On 11/05/2016 12:07 AM, Alex wrote: Hi, I'm trying to enable ethernet on a custom board with an am335x soc, and a VSC8601 connected through RGMII. The plan is to use u-boot as a first stage loader to load a proprietary application (called "the app"). The app already has its own ethernet stack and drivers, and can successfully do network talk. Okay, we solved it -- sort of. I learned the hard way that the EEPROM-based config mechanism in SPL chose to not configure anything -- no clocks, no PMIC. Once we got that hacked out[1], the ethernet started graciously working. There isn't an EEPROM on these boards. Other than hacking a bunch of if statements, is there another mechanism to get the proper DDR, pinmux, PMIC, and clock configuration in SPL Alex [1] diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c index fc1353a..159def3 100644 --- a/board/ti/am335x/board.c +++ b/board/ti/am335x/board.c @@ -254,7 +254,7 @@ void am33xx_spl_board_init(void) /* Get the frequency */ dpll_mpu_opp100.m = am335x_get_efuse_mpu_max_freq(cdev); - if (board_is_bone() || board_is_bone_lt()) { + if (1 || board_is_bone() || board_is_bone_lt()) { /* BeagleBone PMIC Code */ int usb_cur_lim; @@ -262,7 +262,7 @@ void am33xx_spl_board_init(void) * Only perform PMIC configurations if board rev > A1 * on Beaglebone White */ - if (board_is_bone() && !strncmp(board_ti_get_rev(), "00A1", 4)) + if (0 &&( board_is_bone() && !strncmp(board_ti_get_rev(), "00A1", 4))) return; if (i2c_probe(TPS65217_CHIP_PM)) @@ -328,7 +328,7 @@ void am33xx_spl_board_init(void) * Set LDO3, LDO4 output voltage to 3.3V for Beaglebone. * Set LDO3 to 1.8V and LDO4 to 3.3V for Beaglebone Black. */ - if (board_is_bone()) { + if (1 || board_is_bone()) { if (tps65217_reg_write(TPS65217_PROT_LEVEL_2, TPS65217_DEFLS1, TPS65217_LDO_VOLTAGE_OUT_3_3, diff --git a/board/ti/am335x/mux.c b/board/ti/am335x/mux.c index 27979bd..e758429 100644 --- a/board/ti/am335x/mux.c +++ b/board/ti/am335x/mux.c @@ -352,7 +352,7 @@ void enable_board_pin_mux(void) #else configure_module_pin_mux(mmc1_pin_mux); #endif - } else if (board_is_gp_evm()) { + } else if (1 || board_is_gp_evm()) { /* General Purpose EVM */ unsigned short profile = detect_daughter_board_profile(); configure_module_pin_mux(rgmii1_pin_mux); ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] Issues coupling am335x with VSC8601 PHY
Hi, I'm trying to enable ethernet on a custom board with an am335x soc, and a VSC8601 connected through RGMII. The plan is to use u-boot as a first stage loader to load a proprietary application (called "the app"). The app already has its own ethernet stack and drivers, and can successfully do network talk. I started with the am3355x config, and with a few trivial hacks, [1], [2], and [3], I was able to get the PHY recognized in u-boot. Auto-negotiation works correctly on 100Mbit link. The issue is that while packets seem to get transmitted when doing DHCP queries (light on the switch blinks), they aren't legible. I tried hooking up the board to an ethernet port with static IPs, and watching traffic with wireshark, but did not observe any packets. I also probed the RGMII link and it seems the TX clock is running at 10 MHz, instead of 25MHz, when the app is running. At this point I suspect either a gross misconfiguration on my part, or a bug in the cpsw code. I was hoping someone here might have an idea what to do to get ethernet working. Thanks, Alex [1] diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h index ec70b72..63a5b29 100644 --- a/include/configs/am335x_evm.h +++ b/include/configs/am335x_evm.h @@ -433,6 +433,7 @@ #define CONFIG_PHY_SMSC /* Enable Atheros phy driver */ #define CONFIG_PHY_ATHEROS +#define CONFIG_PHY_VITESSE /* * NOR Size = 16 MiB [2] diff --git a/arch/arm/dts/am335x-evm.dts b/arch/arm/dts/am335x-evm.dts index c1a53e2..153a06f 100644 --- a/arch/arm/dts/am335x-evm.dts +++ b/arch/arm/dts/am335x-evm.dts @@ -585,8 +585,8 @@ }; _emac0 { - phy_id = <_mdio>, <0>; - phy-mode = "rgmii-txid"; + phy_id = <_mdio>, <8>; + phy-mode = "rgmii"; }; _emac1 { [3] diff --git a/board/ti/am335x/mux.c b/board/ti/am335x/mux.c index 27979bd..e758429 100644 --- a/board/ti/am335x/mux.c +++ b/board/ti/am335x/mux.c @@ -341,7 +341,7 @@ static unsigned short detect_daughter_board_profile(void) void enable_board_pin_mux(void) { /* Do board-specific muxes. */ - if (board_is_bone()) { + if (0 && board_is_bone()) { /* Beaglebone pinmux */ configure_module_pin_mux(mii1_pin_mux); configure_module_pin_mux(mmc0_pin_mux); @@ -352,7 +352,7 @@ void enable_board_pin_mux(void) #else configure_module_pin_mux(mmc1_pin_mux); #endif - } else if (board_is_gp_evm()) { + } else if (1 || board_is_gp_evm()) { /* General Purpose EVM */ unsigned short profile = detect_daughter_board_profile(); configure_module_pin_mux(rgmii1_pin_mux); ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot