Re: [U-Boot] [PATCH v2] powerpc: Move cpu specific lmb reserve to arch_lmb_reserve

2011-02-09 Thread Kumar Gala

On Jan 31, 2011, at 4:15 PM, Kumar Gala wrote:

 We've been utilizing board_lmb_reserve to reserve the boot page for MP
 systems.  We can just move this into arch_lmb_reserve for 85xx  86xx
 systems rather than duplicating in each board port.
 
 Signed-off-by: Kumar Gala ga...@kernel.crashing.org
 ---
 * Fix compiler warning for not including asm/mp.h in bootm.c
 
 arch/powerpc/lib/bootm.c  |5 +
 board/freescale/corenet_ds/corenet_ds.c   |   11 +--
 board/freescale/mpc8572ds/mpc8572ds.c |   11 +--
 board/freescale/mpc8641hpcn/mpc8641hpcn.c |   11 +--
 board/freescale/p1022ds/p1022ds.c |   10 +-
 board/freescale/p1_p2_rdb/p1_p2_rdb.c |9 -
 board/freescale/p2020ds/p2020ds.c |   10 +-
 board/sbc8641d/sbc8641d.c |9 -
 board/xes/xpedite517x/xpedite517x.c   |9 -
 board/xes/xpedite537x/xpedite537x.c   |9 -
 board/xes/xpedite550x/xpedite550x.c   |9 -
 11 files changed, 10 insertions(+), 93 deletions(-)

applied to 85xx next

- k
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v2] powerpc: Move cpu specific lmb reserve to arch_lmb_reserve

2011-01-31 Thread Kumar Gala
We've been utilizing board_lmb_reserve to reserve the boot page for MP
systems.  We can just move this into arch_lmb_reserve for 85xx  86xx
systems rather than duplicating in each board port.

Signed-off-by: Kumar Gala ga...@kernel.crashing.org
---
* Fix compiler warning for not including asm/mp.h in bootm.c

 arch/powerpc/lib/bootm.c  |5 +
 board/freescale/corenet_ds/corenet_ds.c   |   11 +--
 board/freescale/mpc8572ds/mpc8572ds.c |   11 +--
 board/freescale/mpc8641hpcn/mpc8641hpcn.c |   11 +--
 board/freescale/p1022ds/p1022ds.c |   10 +-
 board/freescale/p1_p2_rdb/p1_p2_rdb.c |9 -
 board/freescale/p2020ds/p2020ds.c |   10 +-
 board/sbc8641d/sbc8641d.c |9 -
 board/xes/xpedite517x/xpedite517x.c   |9 -
 board/xes/xpedite537x/xpedite537x.c   |9 -
 board/xes/xpedite550x/xpedite550x.c   |9 -
 11 files changed, 10 insertions(+), 93 deletions(-)

diff --git a/arch/powerpc/lib/bootm.c b/arch/powerpc/lib/bootm.c
index 116d81b..c7f3d08 100644
--- a/arch/powerpc/lib/bootm.c
+++ b/arch/powerpc/lib/bootm.c
@@ -33,6 +33,7 @@
 #include bzlib.h
 #include environment.h
 #include asm/byteorder.h
+#include asm/mp.h
 
 #if defined(CONFIG_OF_LIBFDT)
 #include fdt.h
@@ -166,6 +167,10 @@ void arch_lmb_reserve(struct lmb *lmb)
sp -= 4096;
lmb_reserve(lmb, sp, (CONFIG_SYS_SDRAM_BASE + get_effective_memsize() - 
sp));
 
+#ifdef CONFIG_MP
+   cpu_mp_lmb_reserve(lmb);
+#endif
+
return ;
 }
 
diff --git a/board/freescale/corenet_ds/corenet_ds.c 
b/board/freescale/corenet_ds/corenet_ds.c
index 232dc72..3db93c3 100644
--- a/board/freescale/corenet_ds/corenet_ds.c
+++ b/board/freescale/corenet_ds/corenet_ds.c
@@ -1,5 +1,5 @@
 /*
- * Copyright 2009-2010 Freescale Semiconductor, Inc.
+ * Copyright 2009-2011 Freescale Semiconductor, Inc.
  *
  * See file CREDITS for list of people who contributed to this
  * project.
@@ -39,8 +39,6 @@ extern void pci_of_setup(void *blob, bd_t *bd);
 
 DECLARE_GLOBAL_DATA_PTR;
 
-void cpu_mp_lmb_reserve(struct lmb *lmb);
-
 int checkboard (void)
 {
u8 sw;
@@ -186,13 +184,6 @@ int misc_init_r(void)
return 0;
 }
 
-#ifdef CONFIG_MP
-void board_lmb_reserve(struct lmb *lmb)
-{
-   cpu_mp_lmb_reserve(lmb);
-}
-#endif
-
 void ft_board_setup(void *blob, bd_t *bd)
 {
phys_addr_t base;
diff --git a/board/freescale/mpc8572ds/mpc8572ds.c 
b/board/freescale/mpc8572ds/mpc8572ds.c
index 4b2ef4e..f444805 100644
--- a/board/freescale/mpc8572ds/mpc8572ds.c
+++ b/board/freescale/mpc8572ds/mpc8572ds.c
@@ -1,5 +1,5 @@
 /*
- * Copyright 2007-2010 Freescale Semiconductor, Inc.
+ * Copyright 2007-2011 Freescale Semiconductor, Inc.
  *
  * See file CREDITS for list of people who contributed to this
  * project.
@@ -259,12 +259,3 @@ void ft_board_setup(void *blob, bd_t *bd)
 #endif
 }
 #endif
-
-#ifdef CONFIG_MP
-extern void cpu_mp_lmb_reserve(struct lmb *lmb);
-
-void board_lmb_reserve(struct lmb *lmb)
-{
-   cpu_mp_lmb_reserve(lmb);
-}
-#endif
diff --git a/board/freescale/mpc8641hpcn/mpc8641hpcn.c 
b/board/freescale/mpc8641hpcn/mpc8641hpcn.c
index 166ff0c..cd2ce4b 100644
--- a/board/freescale/mpc8641hpcn/mpc8641hpcn.c
+++ b/board/freescale/mpc8641hpcn/mpc8641hpcn.c
@@ -1,5 +1,5 @@
 /*
- * Copyright 2006, 2007, 2010 Freescale Semiconductor.
+ * Copyright 2006, 2007, 2010-2011 Freescale Semiconductor.
  *
  * See file CREDITS for list of people who contributed to this
  * project.
@@ -261,12 +261,3 @@ void board_reset(void)
while (1)
;
 }
-
-#ifdef CONFIG_MP
-extern void cpu_mp_lmb_reserve(struct lmb *lmb);
-
-void board_lmb_reserve(struct lmb *lmb)
-{
-   cpu_mp_lmb_reserve(lmb);
-}
-#endif
diff --git a/board/freescale/p1022ds/p1022ds.c 
b/board/freescale/p1022ds/p1022ds.c
index 0ea0bdf..62beafa 100644
--- a/board/freescale/p1022ds/p1022ds.c
+++ b/board/freescale/p1022ds/p1022ds.c
@@ -1,5 +1,5 @@
 /*
- * Copyright 2010 Freescale Semiconductor, Inc.
+ * Copyright 2010-2011 Freescale Semiconductor, Inc.
  * Authors: Srikanth Srinivasan srikanth.sriniva...@freescale.com
  *  Timur Tabi ti...@freescale.com
  *
@@ -24,7 +24,6 @@
 #include fdt_support.h
 #include tsec.h
 #include asm/fsl_law.h
-#include asm/mp.h
 #include netdev.h
 #include i2c.h
 #include hwconfig.h
@@ -302,10 +301,3 @@ void ft_board_setup(void *blob, bd_t *bd)
ft_codec_setup(blob, wlf,wm8776);
 }
 #endif
-
-#ifdef CONFIG_MP
-void board_lmb_reserve(struct lmb *lmb)
-{
-   cpu_mp_lmb_reserve(lmb);
-}
-#endif
diff --git a/board/freescale/p1_p2_rdb/p1_p2_rdb.c 
b/board/freescale/p1_p2_rdb/p1_p2_rdb.c
index 0780942..806d90e 100644
--- a/board/freescale/p1_p2_rdb/p1_p2_rdb.c
+++ b/board/freescale/p1_p2_rdb/p1_p2_rdb.c
@@ -229,12 +229,3 @@ void ft_board_setup(void *blob, bd_t *bd)
fdt_fixup_memory(blob, (u64)base, (u64)size);
 }
 #endif
-
-#ifdef CONFIG_MP
-extern void