From: Jean-Christophe PLAGNIOL-VILLARD Date: Sat, 23 May 2009 18:36:00 +0200 Subject: [U-Boot] [PATCH 3/3] net: switch device init to initcall In-Reply-To: References: <20090523150558.GB26561@game.jcrosoft.org> <1243091325-27683-1-git-send-email-plagnioj@jcrosoft.com> <1243091325-27683-2-git-send-email-plagnioj@jcrosoft.com> <1243091325-27683-3-git-send-email-plagnioj@jcrosoft.com> Message-ID: <20090523163600.GD26561@game.jcrosoft.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 08:41 Sat 23 May , Ben Warren wrote: > Jean-Christophe, > > On Sat, May 23, 2009 at 8:08 AM, Jean-Christophe PLAGNIOL-VILLARD > wrote: > > apply to at91sam9263ek > > this will result to reduce the size of 2212 bytes > > Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD > --- > board/atmel/at91sam9263ek/at91sam9263ek.c | 12 ++++++------ > include/netdev.h | 12 ------------ > net/eth.c | 16 ---------------- > 3 files changed, 6 insertions(+), 34 deletions(-) > > > > - /* Try board-specific initialization first. If it fails or > isn't > - * present, try the cpu-specific initialization */ > - if (board_eth_init(bis) < 0) > - cpu_eth_init(bis); > > Good idea, but your implementation is flawed. It's critically important > that the prioritization of board ethernet initialization over CPU ethernet > initialization be preserved. Your idea doesn't handle that (at least that > I can see). with this only patch yes, but I'm preparing a full implementation that will If I understand correctly the board_eth_init is unsed to overwrite the default cpu_eth_init by passing different parameter with a device/driver model this will be handle correctly Best Regards, J.