Changed PPC4xx EMAC driver to require CONFIG_PPC4xx_EMAC
Subsystems (2)
PATCH 1/3 Changed PPC4xx EMAC driver to require CONFIG_PPC4xx_EMAC
All in-tree IBM/AMCC PPC4xx boards using the EMAC get this new CONFIG
--- cpu/ppc4xx/4xx_enet.c | 9 --------- cpu/ppc4xx/Makefile | 1 + include/configs/AR405.h | 1 + include/configs/ASH405.h | 1 + include/configs/CMS700.h | 1 + include/configs/CPCI405.h | 1 + include/configs/CPCI4052.h | 1 + include/configs/CPCI405AB.h | 1 + include/configs/CPCI405DT.h | 1 + include/configs/CPCIISER4.h | 1 + include/configs/CRAYL1.h | 2 ++ include/configs/DP405.h | 1 + include/configs/DU405.h | 1 + include/configs/DU440.h | 1 + include/configs/ERIC.h | 1 + include/configs/EXBITGEN.h | 1 + include/configs/G2000.h | 1 + include/configs/HH405.h | 1 + include/configs/HUB405.h | 1 + include/configs/JSE.h | 1 + include/configs/KAREF.h | 1 + include/configs/METROBOX.h | 1 + include/configs/MIP405.h | 1 + include/configs/OCRTC.h | 1 + include/configs/ORSG.h | 1 + include/configs/PCI405.h | 1 + include/configs/PIP405.h | 1 + include/configs/PLU405.h | 1 + include/configs/PMC405.h | 1 + include/configs/PMC440.h | 1 + include/configs/PPChameleonEVB.h | 1 + include/configs/VOH405.h | 1 + include/configs/VOM405.h | 1 + include/configs/W7OLMC.h | 1 + include/configs/W7OLMG.h | 1 + include/configs/WUH405.h | 1 + include/configs/XPEDITE1K.h | 1 + include/configs/alpr.h | 1 + include/configs/amcc-common.h | 1 + include/configs/csb272.h | 1 + include/configs/csb472.h | 1 + include/configs/korat.h | 1 + include/configs/lwmon5.h | 1 + include/configs/netstal-common.h | 1 + include/configs/p3p440.h | 1 + include/configs/pcs440ep.h | 1 + include/configs/quad100hd.h | 1 + include/configs/sbc405.h | 1 + include/configs/sc3.h | 2 ++ include/configs/zeus.h | 1 + net/eth.c | 5 ++--- 51 files changed, 53 insertions(+), 12 deletions(-)
cpu/ppc4xx/4xx_enet.c +0 -9
@@ -91,13 +91,6 @@#include <miiphy.h> #include <malloc.h> -/* -* Only compile for platform with AMCC EMAC ethernet controller and -* network support enabled. -* Remark: CONFIG_405 describes Xilinx PPC405 FPGA without EMAC controller! -*/ -#if defined(CONFIG_CMD_NET ) && !defined(CONFIG_405 ) && !defined(CONFIG_IOP480 ) -#if !(defined(CONFIG_MII ) || defined(CONFIG_CMD_MII ))#error "CONFIG_MII has to be defined!"#endif
@@ -2131,5 +2124,3 @@ int emac4xx_miiphy_initialize (bd_t * bis) return 0; }#endif /* !defined(CONFIG_NET_MULTI) */ - -#endif
cpu/ppc4xx/Makefile +1 -0
@@ -38,6 +38,7 @@ COBJS += 44x_spd_ddr2.o ifdef CONFIG_PPC4xx_DDR_AUTOCALIBRATION COBJS += 4xx_ibm_ddr2_autocalib.o endif +COBJS-$(CONFIG_PPC4xx_EMAC) += 4xx_enet.o COBJS += 4xx_pci.o COBJS += 4xx_pcie.o COBJS += bedbug_405.o
include/configs/AR405.h +1 -0
@@ -67,6 +67,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/ASH405.h +1 -0
@@ -56,6 +56,7 @@#define CONFIG_NET_MULTI 1#undef CONFIG_HAS_ETH1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/CMS700.h +1 -0
@@ -52,6 +52,7 @@#define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_NET_MULTI 1#undef CONFIG_HAS_ETH1
include/configs/CPCI405.h +1 -0
@@ -52,6 +52,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/CPCI4052.h +1 -0
@@ -54,6 +54,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/CPCI405AB.h +1 -0
@@ -54,6 +54,7 @@#undef CONFIG_LOADS_ECHO/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/CPCI405DT.h +1 -0
@@ -53,6 +53,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/CPCIISER4.h +1 -0
@@ -50,6 +50,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/CRAYL1.h +2 -0
@@ -39,6 +39,8 @@#define CONFIG_SYS_CLK_FREQ 25000000#define CONFIG_BAUDRATE 9600#define CONFIG_BOOTDELAY 5/* autoboot after 5 seconds */ + +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address; handling of ENET */ #define CONFIG_BOARD_EARLY_INIT_F 1/* early setup for 405gp */
include/configs/DP405.h +1 -0
@@ -52,6 +52,7 @@#define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */
include/configs/DU405.h +1 -0
@@ -54,6 +54,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/DU440.h +1 -0
@@ -253,6 +253,7 @@int du440_phy_addr (int devnum);#endif +#define CONFIG_PPC4xx_EMAC#define CONFIG_IBM_EMAC4_V4 1#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR du440_phy_addr(0)/* PHY address */
include/configs/ERIC.h +1 -0
@@ -93,6 +93,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */
include/configs/EXBITGEN.h +1 -0
@@ -88,6 +88,7 @@*/ #define CONFIG_BOOTP_BOOTFILESIZE #define CONFIG_BOOTP_BOOTPATH +#define CONFIG_PPC4xx_EMAC#define CONFIG_BOOTP_GATEWAY #define CONFIG_BOOTP_HOSTNAME
include/configs/G2000.h +1 -0
@@ -80,6 +80,7 @@#define CONFIG_NET_MULTI 1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_PHY1_ADDR 1/* PHY address */
include/configs/HH405.h +1 -0
@@ -64,6 +64,7 @@#define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_NET_MULTI 1#undef CONFIG_HAS_ETH1
include/configs/HUB405.h +1 -0
@@ -54,6 +54,7 @@#define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/JSE.h +1 -0
@@ -132,6 +132,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */
include/configs/KAREF.h +1 -0
@@ -157,6 +157,7 @@/*----------------------------------------------------------------------- * Networking *----------------------------------------------------------------------*/ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_NET_MULTI 1#define CONFIG_PHY_ADDR 0xff/* no phy on EMAC0 */
include/configs/METROBOX.h +1 -0
@@ -221,6 +221,7 @@/*----------------------------------------------------------------------- * Networking *----------------------------------------------------------------------*/ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_NET_MULTI 1#define CONFIG_PHY_ADDR 0xff/* no phy on EMAC0 */
include/configs/MIP405.h +1 -0
@@ -336,6 +336,7 @@/************************************************************ * Ethernet Stuff ***********************************************************/ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */ #define CONFIG_PHY_RESET_DELAY 300/* Intel LXT971A needs this */
include/configs/OCRTC.h +1 -0
@@ -50,6 +50,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/ORSG.h +1 -0
@@ -50,6 +50,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/PCI405.h +1 -0
@@ -63,6 +63,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */
include/configs/PIP405.h +1 -0
@@ -278,6 +278,7 @@/************************************************************ * Ethernet Stuff ***********************************************************/ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */ /************************************************************
include/configs/PLU405.h +1 -0
@@ -54,6 +54,7 @@#define CONFIG_NET_MULTI 1#undef CONFIG_HAS_ETH1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/PMC405.h +1 -0
@@ -56,6 +56,7 @@#define CONFIG_NET_MULTI 1#undef CONFIG_HAS_ETH1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/PMC440.h +1 -0
@@ -299,6 +299,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_IBM_EMAC4_V4 1#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address, See schematics */
include/configs/PPChameleonEVB.h +1 -0
@@ -104,6 +104,7 @@#undef CONFIG_EXT_PHY#define CONFIG_NET_MULTI 1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #ifndef CONFIG_EXT_PHY #define CONFIG_PHY_ADDR 1/* EMAC0 PHY address */
include/configs/VOH405.h +1 -0
@@ -55,6 +55,7 @@#define CONFIG_NET_MULTI 1#undef CONFIG_HAS_ETH1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/VOM405.h +1 -0
@@ -53,6 +53,7 @@#define CONFIG_NET_MULTI 1#undef CONFIG_HAS_ETH1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/W7OLMC.h +1 -0
@@ -65,6 +65,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #undef CONFIG_SYS_LOADS_BAUD_CHANGE/* disallow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */
include/configs/W7OLMG.h +1 -0
@@ -65,6 +65,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #undef CONFIG_SYS_LOADS_BAUD_CHANGE/* disallow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */
include/configs/WUH405.h +1 -0
@@ -54,6 +54,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */
include/configs/XPEDITE1K.h +1 -0
@@ -167,6 +167,7 @@ extern void out32(unsigned int, unsigned long);#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address phy0 not populated */ #define CONFIG_PHY1_ADDR 1/* PHY address phy1 not populated */
include/configs/alpr.h +1 -0
@@ -198,6 +198,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_NET_MULTI 1#define CONFIG_PHY_ADDR 0x02/* dummy setting, no EMAC0 used */
include/configs/amcc-common.h +1 -0
@@ -45,6 +45,7 @@/* * Ethernet/EMAC/PHY */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII /* MII PHY management */ #define CONFIG_NET_MULTI #define CONFIG_NETCONSOLE /* include NetConsole support */
include/configs/csb272.h +1 -0
@@ -180,6 +180,7 @@* MII PHY configuration * */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_PHY_CMD_DELAY 40/* PHY COMMAND delay */
include/configs/csb472.h +1 -0
@@ -179,6 +179,7 @@* MII PHY configuration * */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_PHY_CMD_DELAY 40/* PHY COMMAND delay */
include/configs/korat.h +1 -0
@@ -215,6 +215,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_IBM_EMAC4_V4 1#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 2/* PHY address, See schematics */
include/configs/lwmon5.h +1 -0
@@ -326,6 +326,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_IBM_EMAC4_V4 1#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 3/* PHY address, See schematics */
include/configs/netstal-common.h +1 -0
@@ -58,6 +58,7 @@/* * Ethernet/EMAC/PHY */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII /* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */ #if defined(CONFIG_440 )
include/configs/p3p440.h +1 -0
@@ -158,6 +158,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0x1c/* PHY address */ #define CONFIG_HAS_ETH1
include/configs/pcs440ep.h +1 -0
@@ -218,6 +218,7 @@#define CONFIG_LOADS_ECHO 1/* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE 1/* allow baudrate change */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_NET_MULTI 1/* required for netconsole */ #define CONFIG_HAS_ETH1 1/* add support for "eth1addr" */
include/configs/quad100hd.h +1 -0
@@ -45,6 +45,7 @@#define CONFIG_ENV_IS_IN_EEPROM #undef CONFIG_ENV_IS_IN_FLASH +#define CONFIG_PPC4xx_EMAC#define CONFIG_NET_MULTI 1#define CONFIG_HAS_ETH1 1#define CONFIG_MII 1/* MII PHY management */
include/configs/sbc405.h +1 -0
@@ -58,6 +58,7 @@#define CONFIG_BOOTCOMMAND "version;echo;tftpboot ${loadaddr} ${loadfile};bootvx"/* autoboot command */ +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_PHY_RESET_DELAY 300/* Intel LXT971A needs this */
include/configs/sc3.h +2 -0
@@ -166,6 +166,8 @@/* #define CONFIG_EEPRO100_SROM_WRITE */ /* #define CONFIG_SHOW_MAC */ #define CONFIG_EEPRO100 + +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* add 405GP MII PHY management */ #define CONFIG_PHY_ADDR 1/* the connected Phy defaults to address 1 */
include/configs/zeus.h +1 -0
@@ -46,6 +46,7 @@#define CONFIG_OVERWRITE_ETHADDR_ONCE 1 +#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0x01/* PHY address */ #define CONFIG_HAS_ETH1 1
net/eth.c +2 -3
@@ -153,7 +153,7 @@ int eth_initialize(bd_t *bis)#if defined(CONFIG_DB64460 ) || defined(CONFIG_P3Mx)mv6446x_eth_initialize (bis);#endif -#if defined(CONFIG_4xx) && !defined(CONFIG_IOP480 ) && !defined(CONFIG_AP1000 ) +#if defined(CONFIG_PPC4xx_EMAC)ppc_4xx_eth_initialize (bis);#endif if (!eth_devices) {
@@ -485,8 +485,7 @@ int eth_initialize(bd_t *bis)#if defined(CONFIG_AT91RM9200 )at91rm9200_miiphy_initialize (bis);#endif -#if defined(CONFIG_4xx) && !defined(CONFIG_IOP480 ) \ - && !defined(CONFIG_AP1000 ) && !defined(CONFIG_405 ) +#if defined(CONFIG_PPC4xx_EMAC)emac4xx_miiphy_initialize (bis);#endif #if defined(CONFIG_MCF52x2)
Signature · 1 line
1.5.4.3
PATCH 2/3 Moved PPC4xx EMAC driver to drivers/net
---
cpu/ppc4xx/Makefile | 1 -
{cpu/ppc4xx => drivers/net}/4xx_enet.c | 0
drivers/net/Makefile | 1 +
3 files changed, 1 insertions(+), 1 deletions(-)
rename {cpu/ppc4xx => drivers/net}/4xx_enet.c (100%)cpu/ppc4xx/Makefile +0 -1
@@ -38,7 +38,6 @@ COBJS += 44x_spd_ddr2.o ifdef CONFIG_PPC4xx_DDR_AUTOCALIBRATION COBJS += 4xx_ibm_ddr2_autocalib.o endif -COBJS-$(CONFIG_PPC4xx_EMAC) += 4xx_enet.o COBJS += 4xx_pci.o COBJS += 4xx_pcie.o COBJS += bedbug_405.o
drivers/net/4xx_enet.c renamed from cpu/ppc4xx/4xx_enet.c +0 -0
drivers/net/Makefile +1 -0
@@ -54,6 +54,7 @@ COBJS-$(CONFIG_NS8382X) += ns8382x.o COBJS-$(CONFIG_DRIVER_NS9750_ETHERNET) += ns9750_eth.o COBJS-$(CONFIG_PCNET) += pcnet.o COBJS-$(CONFIG_PLB2800_ETHER) += plb2800_eth.o +COBJS-$(CONFIG_PPC4xx_EMAC) += 4xx_enet.o COBJS-$(CONFIG_DRIVER_RTL8019) += rtl8019.o COBJS-$(CONFIG_RTL8139) += rtl8139.o COBJS-$(CONFIG_RTL8169) += rtl8169.o
Signature · 1 line
1.5.4.3
PATCH 3/3 Moved initialization of PPC4xx EMAC to cpu_eth_init()
Removed initialization of the driver from net/eth.c
--- cpu/ppc4xx/cpu.c | 14 ++++++++++++++ include/netdev.h | 1 + net/eth.c | 4 ---- 3 files changed, 15 insertions(+), 4 deletions(-)
cpu/ppc4xx/cpu.c +14 -0
@@ -36,6 +36,7 @@#include <command.h> #include <asm/cache.h> #include <ppc4xx.h> +#include <netdev.h> DECLARE_GLOBAL_DATA_PTR ;
@@ -693,3 +694,16 @@ void reset_4xx_watchdog(void) mtspr(tsr, 0x40000000); }#endif /* CONFIG_WATCHDOG */ + +/* +* Initializes on-chip ethernet controllers. +* to override, implement board_eth_init() +*/ +int cpu_eth_init (bd_t *bis) +{ +#if defined(CONFIG_PPC4xx_EMAC) +ppc_4xx_eth_initialize (bis); +#endif +return 0 ; +} +
include/netdev.h +1 -0
@@ -62,6 +62,7 @@ int npe_initialize(bd_t *bis);int ns8382x_initialize (bd_t *bis);int pcnet_initialize (bd_t *bis);int plb2800_eth_initialize (bd_t *bis); +int ppc_4xx_eth_initialize (bd_t *bis);int rtl8139_initialize (bd_t *bis);int rtl8169_initialize (bd_t *bis);int scc_initialize (bd_t *bis);
net/eth.c +0 -4
@@ -41,7 +41,6 @@ int board_eth_init(bd_t *bis) __attribute((weak, alias("__def_eth_init")));extern int mv6436x_eth_initialize (bd_t *);extern int mv6446x_eth_initialize (bd_t *); -extern int ppc_4xx_eth_initialize (bd_t *);#ifdef CONFIG_API extern void (*push_packet)(volatile void *,int );
@@ -153,9 +152,6 @@ int eth_initialize(bd_t *bis)#if defined(CONFIG_DB64460 ) || defined(CONFIG_P3Mx)mv6446x_eth_initialize (bis);#endif -#if defined(CONFIG_PPC4xx_EMAC) -ppc_4xx_eth_initialize (bis); -#endif if (!eth_devices) {puts ("No ethernet found.\n" );show_boot_progress (-64 );
Signature · 1 line
1.5.4.3
PATCH 1/3 Changed PPC4xx EMAC driver to require CONFIG_PPC4xx_EMAC
In reply to Ben WarrenHi Ben,
Quoted 1 line · Ben Warren
All in-tree IBM/AMCC PPC4xx boards using the EMAC get this new CONFIG
Looks good, thanks for all this work.
Unfortunately it doesn't apply to my current u-boot-ppc4xx/master branch:
[stefan at kubuntu u-boot-ppc4xx (master)]$ git am -3 -s patches_ben/\[PATCH\
1_3\]\ Changed\ PPC4xx\ EMAC\ driver\ to\ require\ CONFIG_PPC4xx_EMAC.mbox
Applying: Changed PPC4xx EMAC driver to require CONFIG_PPC4xx_EMAC
error: patch failed: net/eth.c:153
error: net/eth.c: patch does not apply
fatal: sha1 information is lacking or useless (net/eth.c). Repository lacks necessary blobs to fall back on 3-way merge. Cannot fall back to three-way merge.
Patch failed at 0001.
When you have resolved this problem run "git am -3 --resolved". If you would prefer to skip this patch, instead run "git am -3 --skip". To restore the original branch and stop patching run "git am -3 --abort".
Could you please rebase it for me?
And how should we handle these patches? Should they go in via my repository?
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/3 Changed PPC4xx EMAC driver to require CONFIG_PPC4xx_EMAC
Hi Stefan,
Quoted 11 lines · Stefan Roese
Hi Ben,
Quoted 2 lines · Ben Warren
All in-tree IBM/AMCC PPC4xx boards using the EMAC get this new CONFIG
Looks good, thanks for all this work.
Unfortunately it doesn't apply to my current u-boot-ppc4xx/master branch:
Quoted 14 lines
[stefan at kubuntu u-boot-ppc4xx (master)]$ git am -3 -s patches_ben/\[PATCH\
1_3\]\ Changed\ PPC4xx\ EMAC\ driver\ to\ require\ CONFIG_PPC4xx_EMAC.mbox
Applying: Changed PPC4xx EMAC driver to requireCONFIG_PPC4xx_EMAC
error: patch failed:net/eth.c:153
error:net/eth.c: patch does not apply
fatal: sha1 information is lacking or useless (net/eth.c). Repository lacks necessary blobs to fall back on 3-way merge. Cannot fall back to three-way merge.
Patch failed at 0001.
When you have resolved this problem run "git am -3 --resolved". If you would prefer to skip this patch, instead run "git am -3 --skip". To restore the original branch and stop patching run "git am -3 --abort".
Yeah, I probably should have grouped all the net/eth.c patches together. If you install the other ones sent at the same time I expect it will apply. I'll re-base this one for you so you can test it.
Quoted 5 lines
Could you please rebase it for me?
And how should we handle these patches? Should they go in via my repository?
I was hoping you'd ACK them and I'd apply to -net, since it's but one of many controllers I'm messing with.
Quoted 9 lines
Best regards,
Stefan=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/3 Changed PPC4xx EMAC driver to require CONFIG_PPC4xx_EMAC
Hi Ben,
Quoted 8 lines · Ben Warren
Quoted 4 lines
Patch failed at 0001.
When you have resolved this problem run "git am -3 --resolved". If you would prefer to skip this patch, instead run "git am -3 --skip". To restore the original branch and stop patching run "git am -3 --abort".Yeah, I probably should have grouped all the
net/eth.cpatches together. If you install the other ones sent at the same time I expect it will apply. I'll re-base this one for you so you can test it.
Thanks.
Quoted 7 lines
Quoted 4 lines
Could you please rebase it for me?
And how should we handle these patches? Should they go in via my repository?
I was hoping you'd ACK them and I'd apply to -net, since it's but one of many controllers I'm messing with.
Sure. After I had a chance to test them, I'll send the ACK and you can apply them to your -net repository.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================