From fe18792a0887b5ba1ce8e0c8f9f6f1911395552a Mon Sep 17 00:00:00 2001 From: Hung-Te Lin Date: Fri, 1 Feb 2013 01:09:24 +0800 Subject: armv7: Add 'bootblock' build class. For ARM platform, the bootblock may need more C source files to initialize UART / SPI for loading romstage. To preventing making complex and implicit dependency by using #include inside bootblock.c, we should add a new build class "bootblock". Also #ifdef __BOOT_BLOCK__ can be used to detect if the source is being compiled for boot block. For x86, the bootblock is limited to fewer assembly files so it's not using this class. (Some files shared by x86 and arm in top level or lib are also changed but nothing should be changed in x86 build process.) Change-Id: Ia81bccc366d2082397d133d9245f7ecb33b8bc8b Signed-off-by: Hung-Te Lin Reviewed-on: http://review.coreboot.org/2252 Reviewed-by: Ronald G. Minnich Tested-by: build bot (Jenkins) --- src/lib/Makefile.inc | 10 ++++++++++ src/lib/cbfs.c | 2 ++ 2 files changed, 12 insertions(+) (limited to 'src/lib') diff --git a/src/lib/Makefile.inc b/src/lib/Makefile.inc index 67964482b1..8ff0a4446e 100644 --- a/src/lib/Makefile.inc +++ b/src/lib/Makefile.inc @@ -17,6 +17,16 @@ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # +bootblock-y += cbfs.c +ifneq ($(CONFIG_HAVE_ARCH_MEMSET),y) +bootblock-y += memset.c +endif +bootblock-y += memchr.c +ifneq ($(CONFIG_HAVE_ARCH_MEMCPY),y) +bootblock-y += memcpy.c +endif +bootblock-y += memcmp.c + ifneq ($(CONFIG_HAVE_ARCH_MEMSET),y) romstage-y += memset.c endif diff --git a/src/lib/cbfs.c b/src/lib/cbfs.c index 3e44582f4d..4702f1e0bc 100644 --- a/src/lib/cbfs.c +++ b/src/lib/cbfs.c @@ -27,6 +27,8 @@ # define CBFS_MINI_BUILD #elif defined(__SMM__) # define CBFS_MINI_BUILD +#elif defined(__BOOT_BLOCK__) + /* No LZMA in boot block. */ #else # define CBFS_CORE_WITH_LZMA # include -- cgit v1.2.3