]> git.ipfire.org Git - people/ms/u-boot.git/commitdiff
SPL: NAND: Move arch/arm/cpu/armv7/omap-common/spl_nand.c to common/spl
authorTom Rini <trini@ti.com>
Tue, 14 Aug 2012 21:33:02 +0000 (14:33 -0700)
committerTom Rini <trini@ti.com>
Thu, 27 Sep 2012 16:50:00 +0000 (09:50 -0700)
We move the spl_nand_load_image function to common/spl.  This will allow
for easier integration of SPL-boots-Linux code on other arches.

Signed-off-by: Tom Rini <trini@ti.com>
arch/arm/cpu/armv7/omap-common/Makefile
common/spl/Makefile
common/spl/spl_nand.c [moved from arch/arm/cpu/armv7/omap-common/spl_nand.c with 94% similarity]

index 6e815c674d9442fc3808f4c816eaffb32707c6c6..1f2fa027c8f84198ab90e2afeb3ff9aa1e5d494b 100644 (file)
@@ -42,12 +42,6 @@ COBJS        += boot-common.o
 SOBJS  += lowlevel_init.o
 endif
 
-ifdef CONFIG_SPL_BUILD
-ifdef CONFIG_SPL_NAND_SUPPORT
-COBJS  += spl_nand.o
-endif
-endif
-
 ifndef CONFIG_SPL_BUILD
 ifneq ($(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX),)
 COBJS  += mem-common.o
index b61b4382823c236c16e0716384344e53a522ebb4..b9c9fd85212de94e2a1354f2d1279162f9e316c8 100644 (file)
@@ -16,6 +16,7 @@ LIB   = $(obj)libspl.o
 ifdef CONFIG_SPL_BUILD
 COBJS-$(CONFIG_SPL_FRAMEWORK) += spl.o
 COBJS-$(CONFIG_SPL_YMODEM_SUPPORT) += spl_ymodem.o
+COBJS-$(CONFIG_SPL_NAND_SUPPORT) += spl_nand.o
 endif
 
 COBJS  := $(sort $(COBJS-y))
similarity index 94%
rename from arch/arm/cpu/armv7/omap-common/spl_nand.c
rename to common/spl/spl_nand.c
index 9e9206ce3b62092973e28508d764de3968ca3f0b..61de5a4f05fe3a67562bb35c595c03cd2f4c509f 100644 (file)
  * MA 02111-1307 USA
  */
 #include <common.h>
+#include <config.h>
 #include <spl.h>
-#include <asm/u-boot.h>
-#include <asm/utils.h>
 #include <asm/io.h>
 #include <nand.h>
-#include <version.h>
 
 void spl_nand_load_image(void)
 {
@@ -71,10 +69,10 @@ void spl_nand_load_image(void)
                        nand_deselect();
                        return;
                } else {
-                       printf("The Expected Linux image was not"
-                               "found. Please check your NAND"
+                       puts("The Expected Linux image was not "
+                               "found. Please check your NAND "
                                "configuration.\n");
-                       printf("Trying to start u-boot now...\n");
+                       puts("Trying to start u-boot now...\n");
                }
        }
 #endif