[U-Boot] [PATCH] omap3evm: Move function to identify board revision

Sanjeev Premi premi at ti.com
Tue Oct 19 15:06:48 CEST 2010


Function omap3_evm_get_revision() - to identify the
board revision was called at end of setup_net_chip().

Board revision can be ascertained only by identifying
the Ethernet chipset - but combining setup operations
with revision detection isn;t a good idea.

Moved the function and added detailed comment to set
the context.

Signed-off-by: Sanjeev Premi <premi at ti.com>
---
 board/ti/evm/evm.c |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/board/ti/evm/evm.c b/board/ti/evm/evm.c
index 73330db..6163b12 100644
--- a/board/ti/evm/evm.c
+++ b/board/ti/evm/evm.c
@@ -109,6 +109,12 @@ int misc_init_r(void)
 
 #if defined(CONFIG_CMD_NET)
 	setup_net_chip();
+
+	/*
+	 * Board revision can be ascertained only by identifying
+	 * the Ethernet chipset.
+	 */
+	omap3_evm_get_revision();
 #endif
 
 	dieid_num_r();
@@ -163,9 +169,6 @@ static void setup_net_chip(void)
 	writel(GPIO0, &gpio3_base->cleardataout);
 	udelay(1);
 	writel(GPIO0, &gpio3_base->setdataout);
-
-	/* determine omap3evm revision */
-	omap3_evm_get_revision();
 }
 
 int board_eth_init(bd_t *bis)
-- 
1.7.2.2



More information about the U-Boot mailing list