[U-Boot] [PATCH] 85xx: Convert cpu_init_f code to use out_be32 for LBC registers

Kumar Gala galak at kernel.crashing.org
Wed Apr 14 07:03:36 CEST 2010


Signed-off-by: Kumar Gala <galak at kernel.crashing.org>
---
 arch/ppc/cpu/mpc85xx/cpu_init.c |   36 ++++++++++++++++++------------------
 1 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/arch/ppc/cpu/mpc85xx/cpu_init.c b/arch/ppc/cpu/mpc85xx/cpu_init.c
index e0126d3..b517e06 100644
--- a/arch/ppc/cpu/mpc85xx/cpu_init.c
+++ b/arch/ppc/cpu/mpc85xx/cpu_init.c
@@ -180,54 +180,54 @@ void cpu_init_f (void)
 	 * has been determined
 	 */
 #if defined(CONFIG_SYS_OR0_REMAP)
-	memctl->or0 = CONFIG_SYS_OR0_REMAP;
+	out_be32(&memctl->or0, CONFIG_SYS_OR0_REMAP);
 #endif
 #if defined(CONFIG_SYS_OR1_REMAP)
-	memctl->or1 = CONFIG_SYS_OR1_REMAP;
+	out_be32(&memctl->or1, CONFIG_SYS_OR1_REMAP);
 #endif
 
 	/* now restrict to preliminary range */
 	/* if cs1 is already set via debugger, leave cs0/cs1 alone */
 	if (! memctl->br1 & 1) {
 #if defined(CONFIG_SYS_BR0_PRELIM) && defined(CONFIG_SYS_OR0_PRELIM)
-		memctl->br0 = CONFIG_SYS_BR0_PRELIM;
-		memctl->or0 = CONFIG_SYS_OR0_PRELIM;
+		out_be32(&memctl->br0, CONFIG_SYS_BR0_PRELIM);
+		out_be32(&memctl->or0, CONFIG_SYS_OR0_PRELIM);
 #endif
 
 #if defined(CONFIG_SYS_BR1_PRELIM) && defined(CONFIG_SYS_OR1_PRELIM)
-		memctl->or1 = CONFIG_SYS_OR1_PRELIM;
-		memctl->br1 = CONFIG_SYS_BR1_PRELIM;
+		out_be32(&memctl->or1, CONFIG_SYS_OR1_PRELIM);
+		out_be32(&memctl->br1, CONFIG_SYS_BR1_PRELIM);
 #endif
 	}
 
 #if defined(CONFIG_SYS_BR2_PRELIM) && defined(CONFIG_SYS_OR2_PRELIM)
-	memctl->or2 = CONFIG_SYS_OR2_PRELIM;
-	memctl->br2 = CONFIG_SYS_BR2_PRELIM;
+	out_be32(&memctl->or2, CONFIG_SYS_OR2_PRELIM);
+	out_be32(&memctl->br2, CONFIG_SYS_BR2_PRELIM);
 #endif
 
 #if defined(CONFIG_SYS_BR3_PRELIM) && defined(CONFIG_SYS_OR3_PRELIM)
-	memctl->or3 = CONFIG_SYS_OR3_PRELIM;
-	memctl->br3 = CONFIG_SYS_BR3_PRELIM;
+	out_be32(&memctl->or3, CONFIG_SYS_OR3_PRELIM);
+	out_be32(&memctl->br3, CONFIG_SYS_BR3_PRELIM);
 #endif
 
 #if defined(CONFIG_SYS_BR4_PRELIM) && defined(CONFIG_SYS_OR4_PRELIM)
-	memctl->or4 = CONFIG_SYS_OR4_PRELIM;
-	memctl->br4 = CONFIG_SYS_BR4_PRELIM;
+	out_be32(&memctl->or4, CONFIG_SYS_OR4_PRELIM);
+	out_be32(&memctl->br4, CONFIG_SYS_BR4_PRELIM);
 #endif
 
 #if defined(CONFIG_SYS_BR5_PRELIM) && defined(CONFIG_SYS_OR5_PRELIM)
-	memctl->or5 = CONFIG_SYS_OR5_PRELIM;
-	memctl->br5 = CONFIG_SYS_BR5_PRELIM;
+	out_be32(&memctl->or5, CONFIG_SYS_OR5_PRELIM);
+	out_be32(&memctl->br5, CONFIG_SYS_BR5_PRELIM);
 #endif
 
 #if defined(CONFIG_SYS_BR6_PRELIM) && defined(CONFIG_SYS_OR6_PRELIM)
-	memctl->or6 = CONFIG_SYS_OR6_PRELIM;
-	memctl->br6 = CONFIG_SYS_BR6_PRELIM;
+	out_be32(&memctl->or6, CONFIG_SYS_OR6_PRELIM);
+	out_be32(&memctl->br6, CONFIG_SYS_BR6_PRELIM);
 #endif
 
 #if defined(CONFIG_SYS_BR7_PRELIM) && defined(CONFIG_SYS_OR7_PRELIM)
-	memctl->or7 = CONFIG_SYS_OR7_PRELIM;
-	memctl->br7 = CONFIG_SYS_BR7_PRELIM;
+	out_be32(&memctl->or7, CONFIG_SYS_OR7_PRELIM);
+	out_be32(&memctl->br7, CONFIG_SYS_BR7_PRELIM);
 #endif
 
 #if defined(CONFIG_CPM2)
-- 
1.6.0.6



More information about the U-Boot mailing list