From: Teh Kok How Date: Fri, 12 Feb 2010 17:26:22 +0800 Subject: [U-Boot] [PATCH] net/eth.c: bug-fix In-Reply-To: <07A6D2B84CB942DD8FC96FB7E3CD9CC2@smartbridges.com> References: <07A6D2B84CB942DD8FC96FB7E3CD9CC2@smartbridges.com> Message-ID: <3270DCAC1B1540C7B13D9BC718F543BF@smartbridges.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Fixes: Board_eth_init() calls pci_eth_init() (include/netdev.h) and if ethernet is soc, CONFIG_PCI is not defined, pci_eth_init() returns 0. This patch allows cpu_eth_init() to be called. Signed-off-by: Kok How, Teh --- u-boot-2009.11.1.orig/net/eth.c 2010-01-25 16:35:12.000000000 +0800 +++ u-boot-2009.11.1.new/net/eth.c 2010-02-12 17:20:32.864273873 +0800 @@ -199,7 +199,7 @@ #endif /* Try board-specific initialization first. If it fails or isn't * present, try the cpu-specific initialization */ - if (board_eth_init(bis) < 0) + if (board_eth_init(bis) <= 0) cpu_eth_init(bis); #if defined(CONFIG_DB64360) || defined(CONFIG_CPCI750)