From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Roese Date: Tue, 25 Mar 2008 08:04:13 +0100 Subject: [U-Boot-Users] [RFC][PATCH 1/1] Add board_eth_init() function In-Reply-To: References: <200803221114.40956.sr@denx.de> <20080322140107.F088D24A93@gemini.denx.de> Message-ID: <200803250804.13314.sr@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Saturday 22 March 2008, Ben Warren wrote: > > All I'm asking for is to make sure that this can be configured in a > > board specific way. If there is a zensible default setting which > > covers most cases without need for board-specific stuff that's just > > all the better. > > How about something like this: > > #ifdef CONFIG_ETH_INIT_DEFAULT > CFG_ETH_INIT_DEFAULT(bis); > #else > board_eth_init(bis); > #endif Using Markus's idea, why not use a cpu (platform) specific *and* a board specific init function, both with an empty weak alias in the common eth.c code: cpu_eth_init(bis); board_eth_init(bis); 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 =====================================================================