Remove non-CONFIG_NET_MULTI option for PPC4xx EMAC
Subsystems (2)
cover Remove non-CONFIG_NET_MULTI option for PPC4xx EMAC
Hello,
This patch set switches all remaining PPC4xx boards to use CONFIG_NET_MULTI. I haven't been able to test any of the boards, but MAKEALL 4xx ran OK. I remember that some of the 4xx linker scripts specified 'ppc_4xx_eth_initialize', so maybe that's necessary in some cases?
regards,
Ben
PATCH 1/2 Enable CONFIG_NET_MULTI on all remaining PPC4xx boards
All in-tree PPC4xx boards now use CONFIG_NET_MULTI
--- include/configs/AR405.h | 1 + include/configs/CPCIISER4.h | 1 + include/configs/CRAYL1.h | 1 + include/configs/DP405.h | 1 + include/configs/ERIC.h | 1 + include/configs/EXBITGEN.h | 1 + include/configs/HUB405.h | 1 + include/configs/JSE.h | 1 + include/configs/MIP405.h | 1 + include/configs/OCRTC.h | 1 + include/configs/ORSG.h | 1 + include/configs/PIP405.h | 1 + include/configs/W7OLMC.h | 1 + include/configs/W7OLMG.h | 1 + include/configs/WUH405.h | 1 + include/configs/csb272.h | 1 + include/configs/csb472.h | 1 + include/configs/netstal-common.h | 2 +- include/configs/sbc405.h | 1 + 19 files changed, 19 insertions(+), 1 deletions(-)
include/configs/AR405.h +1 -0
@@ -71,6 +71,7 @@#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 */ +#define CONFIG_NET_MULTI /*
include/configs/CPCIISER4.h +1 -0
@@ -54,6 +54,7 @@#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 */ +#define CONFIG_NET_MULTI /*
include/configs/CRAYL1.h +1 -0
@@ -45,6 +45,7 @@#define CONFIG_PHY_ADDR 1/* PHY address; handling of ENET */ #define CONFIG_BOARD_EARLY_INIT_F 1/* early setup for 405gp */ #define CONFIG_MISC_INIT_R 1/* so that a misc_init_r() is called */ +#define CONFIG_NET_MULTI /* set PRAM to keep U-Boot out, mem= to keep linux out, and initrd_hi to * keep possible initrd ramdisk decompression out. This is in k (1024 bytes)
include/configs/DP405.h +1 -0
@@ -55,6 +55,7 @@#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ +#define CONFIG_NET_MULTI /*
include/configs/ERIC.h +1 -0
@@ -96,6 +96,7 @@#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */ +#define CONFIG_NET_MULTI /*
include/configs/EXBITGEN.h +1 -0
@@ -81,6 +81,7 @@#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ +#define CONFIG_NET_MULTI /*
include/configs/HUB405.h +1 -0
@@ -60,6 +60,7 @@#define CONFIG_LXT971_NO_SLEEP 1/* disable sleep mode in LXT971 */ #define CONFIG_PHY_CLK_FREQ EMAC_STACR_CLK_66MHZ/* 66 MHz OPB clock*/ +#define CONFIG_NET_MULTI /*
include/configs/JSE.h +1 -0
@@ -135,6 +135,7 @@#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */ +#define CONFIG_NET_MULTI /*
include/configs/MIP405.h +1 -0
@@ -341,6 +341,7 @@#define CONFIG_PHY_ADDR 1/* PHY address */ #define CONFIG_PHY_RESET_DELAY 300/* Intel LXT971A needs this */ #define CONFIG_PHY_CMD_DELAY 40/* Intel LXT971A needs this */ +#define CONFIG_NET_MULTI /************************************************************ * RTC ***********************************************************/
include/configs/OCRTC.h +1 -0
@@ -54,6 +54,7 @@#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 */ +#define CONFIG_NET_MULTI /*
include/configs/ORSG.h +1 -0
@@ -54,6 +54,7 @@#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 */ +#define CONFIG_NET_MULTI /*
include/configs/PIP405.h +1 -0
@@ -281,6 +281,7 @@#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */ +#define CONFIG_NET_MULTI /************************************************************ * RTC ***********************************************************/
include/configs/W7OLMC.h +1 -0
@@ -68,6 +68,7 @@#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ +#define CONFIG_NET_MULTI #define CONFIG_RTC_M48T35A 1/* ST Electronics M48 timekeeper */
include/configs/W7OLMG.h +1 -0
@@ -68,6 +68,7 @@#define CONFIG_PPC4xx_EMAC#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ +#define CONFIG_NET_MULTI #define CONFIG_RTC_M48T35A 1/* ST Electronics M48 timekeeper */ #define CONFIG_DTT_LM75 1/* ON Semi's LM75 */
include/configs/WUH405.h +1 -0
@@ -58,6 +58,7 @@#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 */ +#define CONFIG_NET_MULTI #define CONFIG_PHY_CLK_FREQ EMAC_STACR_CLK_66MHZ/* 66 MHz OPB clock*/
include/configs/csb272.h +1 -0
@@ -184,6 +184,7 @@#define CONFIG_PHY_CMD_DELAY 40/* PHY COMMAND delay */ /* 32usec min. for LXT971A */ #define CONFIG_PHY_RESET_DELAY 300/* PHY RESET recovery delay */ +#define CONFIG_NET_MULTI /* * RTC configuration
include/configs/csb472.h +1 -0
@@ -183,6 +183,7 @@#define CONFIG_PHY_CMD_DELAY 40/* PHY COMMAND delay */ /* 32usec min. for LXT971A */ #define CONFIG_PHY_RESET_DELAY 300/* PHY RESET recovery delay */ +#define CONFIG_NET_MULTI /* * RTC configuration
include/configs/netstal-common.h +1 -1
@@ -61,8 +61,8 @@#define CONFIG_PPC4xx_EMAC#define CONFIG_MII /* MII PHY management */ #define CONFIG_PHY_ADDR 1/* PHY address */ -#if defined(CONFIG_440 )#define CONFIG_NET_MULTI 1 +#if defined(CONFIG_440 )#define CONFIG_NETCONSOLE /* include NetConsole support */ #define CONFIG_SYS_RX_ETH_BUFFER 32/* number of eth rx buffers */ #else
include/configs/sbc405.h +1 -0
@@ -62,6 +62,7 @@#define CONFIG_MII 1/* MII PHY management */ #define CONFIG_PHY_ADDR 0/* PHY address */ #define CONFIG_PHY_RESET_DELAY 300/* Intel LXT971A needs this */ +#define CONFIG_NET_MULTI #define CONFIG_EXTRA_ENV_SETTINGS \ "bootargs=emac(0,0)host:/T221ppc/target/config/sbc405/vxWorks.st " \
Signature · 1 line
1.5.6.3
PATCH 2/2 Remove support for non-CONFIG_NET_MULTI on PPC4xx EMAC
--- drivers/net/4xx_enet.c | 54 ------------------------------------------------ net/eth.c | 4 --- 2 files changed, 0 insertions(+), 58 deletions(-)
drivers/net/4xx_enet.c +0 -54
@@ -259,9 +259,6 @@ static const struct fixed_phy_port fixed_phy_port[] = {/*-----------------------------------------------------------------------------+ * Global variables. TX and RX descriptors and buffers. *-----------------------------------------------------------------------------*/ -#if !defined(CONFIG_NET_MULTI ) -struct eth_device *emac0_dev =NULL ; -#endif /* * Get count of EMAC devices (doesn't have to be the max. possible number
@@ -1641,11 +1638,7 @@ int enetInt (struct eth_device *dev)* Because the mal is generic, we need to get the current * eth device */ -#if defined(CONFIG_NET_MULTI ) dev =eth_get_dev (); -#else - dev = emac0_dev; -#endif hw_p = dev->priv;
@@ -2064,60 +2057,13 @@ int ppc_4xx_eth_initialize (bd_t * bis) virgin =1 ; } -#if defined(CONFIG_NET_MULTI )eth_register (dev); -#else - emac0_dev = dev; -#endif -#if defined(CONFIG_NET_MULTI )#if defined(CONFIG_MII ) || defined(CONFIG_CMD_MII )miiphy_register (dev->name, emac4xx_miiphy_read, emac4xx_miiphy_write);#endif -#endif }/* end for each supported device */ return 0 ; } - -#if !defined(CONFIG_NET_MULTI ) -void eth_halt (void ) { -if (emac0_dev) { -ppc_4xx_eth_halt (emac0_dev); -free (emac0_dev); - emac0_dev =NULL ; - } -} - -int eth_init (bd_t *bis) -{ -ppc_4xx_eth_initialize (bis); -if (emac0_dev) { -return ppc_4xx_eth_init (emac0_dev, bis); - }else { -printf ("ERROR: ethaddr not set!\n" ); -return -1 ; - } -} - -int eth_send (volatile void *packet,int length) -{ -return (ppc_4xx_eth_send (emac0_dev, packet, length)); -} - -int eth_rx (void ) -{ -return (ppc_4xx_eth_rx (emac0_dev)); -} - -int emac4xx_miiphy_initialize (bd_t * bis) -{ -#if defined(CONFIG_MII ) || defined(CONFIG_CMD_MII ) -miiphy_register ("ppc_4xx_eth0" , - emac4xx_miiphy_read, emac4xx_miiphy_write); -#endif - -return 0 ; -} -#endif /* !defined(CONFIG_NET_MULTI) */
net/eth.c +0 -4
@@ -502,7 +502,6 @@ char *eth_get_name (void)#elif defined(CONFIG_CMD_NET ) && !defined(CONFIG_NET_MULTI )extern int at91rm9200_miiphy_initialize (bd_t *bis); -extern int emac4xx_miiphy_initialize (bd_t *bis);extern int mcf52x2_miiphy_initialize (bd_t *bis);extern int ns7520_miiphy_initialize (bd_t *bis);
@@ -516,9 +515,6 @@ int eth_initialize(bd_t *bis)#if defined(CONFIG_AT91RM9200 )at91rm9200_miiphy_initialize (bis);#endif -#if defined(CONFIG_PPC4xx_EMAC) -emac4xx_miiphy_initialize (bis); -#endif #if defined(CONFIG_MCF52x2)mcf52x2_miiphy_initialize (bis);#endif
Signature · 1 line
1.5.6.3
PATCH 2/2 Remove support for non-CONFIG_NET_MULTI on PPC4xx EMAC
Quoted 6 lines · Ben Warren
Signed-off-by Ben Warren <[email protected]>--- drivers/net/4xx_enet.c | 54 ------------------------------------------------ net/eth.c | 4 --- 2 files changed, 0 insertions(+), 58 deletions(-)
Ben, this doesn't apply against mainline. I suppose you already based this against your "next"? Best would be if you would apply this patch directly and I'll apply the other one [[PATCH 1/2][Net][ppc4xx] Enable CONFIG_NET_MULTI on all remaining PPC4xx boards].
OK? If yes, I'll send a pull request for my "next" to Wolfgang tomorrow.
Thanks.
BTW: Please add my Signed-off-by to this patch [2/2].
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 2/2 Remove support for non-CONFIG_NET_MULTI on PPC4xx EMAC
Quoted 6 lines · Stefan Roese
Ben, this doesn't apply against mainline. I suppose you already based this against your "next"? Best would be if you would apply this patch directly and I'll apply the other one [[PATCH 1/2][Net][ppc4xx] Enable
CONFIG_NET_MULTIon all remaining PPC4xx boards].OK? If yes, I'll send a pull request for my "next" to Wolfgang tomorrow.
Ben?
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 2/2 Remove support for non-CONFIG_NET_MULTI on PPC4xx EMAC
Hi Stefan,
Quoted 7 lines · Stefan Roese
Quoted 5 lines · Stefan Roese
Ben, this doesn't apply against mainline. I suppose you already based this against your "next"? Best would be if you would apply this patch directly and I'll apply the other one [[PATCH 1/2][Net][ppc4xx] Enable
CONFIG_NET_MULTIon all remaining PPC4xx boards].
Quoted 6 lines
Quoted 2 lines
OK? If yes, I'll send a pull request for my "next" to Wolfgang tomorrow.
Ben?
Sorry for the delay. Yeah, please go ahead and apply 1/2 to your tree and ask Wolfgang to pull. The second part can be applied at any time - I'll take care of it. Thanks for your help.
Quoted 3 lines
Best regards,
Stefan
regards,
Ben
PATCH 2/2 Remove support for non-CONFIG_NET_MULTI on PPC4xx EMAC
Hi Stefan,
Quoted 16 lines · Ben Warren
Hi Stefan,
Quoted 13 lines · Stefan Roese
Quoted 10 lines · Stefan Roese
Ben, this doesn't apply against mainline. I suppose you already based this
against your "next"? Best would be if you would apply this patch directly
and I'll apply the other one [[PATCH 1/2][Net][ppc4xx] EnableCONFIG_NET_MULTIon all remaining PPC4xx boards].OK? If yes, I'll send a pull request for my "next" to Wolfgang tomorrow.
Quoted 6 lines
Quoted 3 lines
Ben?
Sorry for the delay. Yeah, please go ahead and apply 1/2 to your tree and ask Wolfgang to pull. The second part can be applied at any time
- I'll take care of it. Thanks for your help.
I've gone ahead and applied the second part to the net tree. Hope that's OK.
regards,
Ben
PATCH 2/2 Remove support for non-CONFIG_NET_MULTI on PPC4xx EMAC
Quoted 6 lines · On Tuesday 26 May 2009 10:05:12 Ben Warren wrote:
Quoted 3 lines
Sorry for the delay. Yeah, please go ahead and apply 1/2 to your tree and ask Wolfgang to pull. The second part can be applied at any time
- I'll take care of it. Thanks for your help.I've gone ahead and applied the second part to the net tree. Hope that's OK.
Yes, thanks.
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
=====================================================================
Stefan Roese
AppliedPATCH 1/2 Enable CONFIG_NET_MULTI on all remaining PPC4xx boards
In reply to Ben WarrenQuoted 3 lines · Ben Warren
All in-tree PPC4xx boards now use
CONFIG_NET_MULTISigned-off-by Ben Warren <[email protected]>
Applied to ppc4xx/next. Thanks.
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
=====================================================================