From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kumar Gala Date: Mon, 31 Jan 2011 16:05:27 -0600 Subject: [U-Boot] [PATCH 3/6] P1021: add P1021MDS board support In-Reply-To: <1296509955.2049.543.camel@haiying-laptop> References: <1296499317-26616-1-git-send-email-Haiying.Wang@freescale.com> <1296499317-26616-4-git-send-email-Haiying.Wang@freescale.com> <20110131200317.A730ED4D67C@gemini.denx.de> <1296509955.2049.543.camel@haiying-laptop> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Jan 31, 2011, at 3:39 PM, Haiying Wang wrote: > On Mon, 2011-01-31 at 21:03 +0100, Wolfgang Denk wrote: >> Dear Haiying.Wang at freescale.com, >>> diff --git a/board/freescale/p1021mds/config.mk b/board/freescale/p1021mds/config.mk >>> new file mode 100644 >>> index 0000000..3888f61 >>> --- /dev/null >>> +++ b/board/freescale/p1021mds/config.mk >> ... >>> +ifndef NAND_SPL >>> +ifndef IN_TPL >>> +ifeq ($(CONFIG_NAND), y) >>> +LDSCRIPT := $(TOPDIR)/$(CPUDIR)/u-boot-nand.lds >>> +endif >>> +endif >>> +endif >> >> Why is this config.mk needed? Can you not do all this in the board >> config file instead? > Do you mean the board header file or arch/powerpc/config.mk? I did not see any LDSCRIPT defined in Freescale board header file. I think something like: diff --git a/include/configs/MPC8572DS.h b/include/configs/MPC8572DS.h index e6b60cf..f2d6cdb 100644 --- a/include/configs/MPC8572DS.h +++ b/include/configs/MPC8572DS.h @@ -37,6 +37,7 @@ #define CONFIG_NAND_U_BOOT #define CONFIG_RAMBOOT_NAND #ifdef CONFIG_NAND_SPL +#define CONFIG_SYS_LDSCRIPT "arch/powerpc/cpu/mpc85xx/u-boot-nand.lds" #define CONFIG_SYS_TEXT_BASE_SPL 0xfff00000 #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE_SPL /* start of mon - k