[U-Boot] [PATCH 00/22] A collection of trivial Makefile refactoring

This series does not add any new features but refactor makefiles.
Masahiro Yamada (22): Makefile: abolish COBJS, SOBJS, etc. Makefile: specifiy an explicite object name rather than $(BOARD).o drivers: descend into sub directories only when it is necessary lib: descend into sub directories only when it is necessary drivers: tpm: clean up unused code Makefile: make directories by Makefile.build Makefile: merge $(LIBBOARD) into $(LIBS) powerpc: move mpc8xxx entry under arch/powerpc/cpu/ drivers/qe: move the entry to drivers/Makefile drivers/net/fm: descend only when CONFIG_FMAN_ENET=y drivers/net/npe: descend only when CONFIG_IXP4XX_NPE=y Makefile: rename all libraries to built-in.o Makefile: refactor a little config.mk: delete unnecessary lines tools: Makefile: delete redundant lines Makefile: delete unused lines powerpc: mpc83xx: delete unused rules powerpc: mpc83xx: Do not create a symbolic link to ddr-gen2.c powerpc: mpc824x: Do not create a symbolic link to bedbug_603e.c arm: rmobile: Do not create a symbolic link to sh timer Makefile: move fs/fat/ entry to drivers/Makefile fs: descend into sub directories when it is necessary
Makefile | 149 +++++++++-------------- arch/arm/cpu/armv7/rmobile/Makefile | 8 +- arch/microblaze/cpu/u-boot.lds | 2 +- arch/powerpc/cpu/Makefile | 3 + arch/powerpc/cpu/mpc512x/Makefile | 2 - arch/powerpc/cpu/mpc824x/.gitignore | 1 - arch/powerpc/cpu/mpc824x/Makefile | 10 +- arch/powerpc/cpu/mpc83xx/Makefile | 12 +- arch/powerpc/cpu/mpc8xxx/Makefile | 6 + board/LEOX/elpt860/u-boot.lds | 8 +- board/LaCie/edminiv2/Makefile | 4 - board/LaCie/net2big_v2/Makefile | 4 - board/LaCie/netspace_v2/Makefile | 4 - board/LaCie/wireless_space/Makefile | 4 - board/Marvell/db64360/Makefile | 4 - board/Marvell/db64460/Makefile | 4 - board/actux1/u-boot.lds | 8 +- board/actux2/u-boot.lds | 8 +- board/actux3/u-boot.lds | 8 +- board/altera/nios2-generic/Makefile | 4 - board/avionic-design/medcom-wide/Makefile | 2 - board/avionic-design/plutux/Makefile | 2 - board/avionic-design/tec/Makefile | 2 - board/compal/paz00/Makefile | 2 - board/compulab/trimslice/Makefile | 2 - board/davinci/da8xxevm/u-boot-spl-hawk.lds | 4 +- board/dvlhost/u-boot.lds | 8 +- board/emk/top5200/Makefile | 4 - board/emk/top860/Makefile | 3 - board/esd/adciop/Makefile | 4 - board/esd/apc405/Makefile | 4 - board/esd/ar405/Makefile | 4 - board/esd/ash405/Makefile | 4 - board/esd/cms700/Makefile | 4 - board/esd/cpci2dp/Makefile | 4 - board/esd/cpci405/Makefile | 4 - board/esd/cpci5200/Makefile | 4 - board/esd/cpci750/Makefile | 4 - board/esd/cpciiser4/Makefile | 4 - board/esd/dasa_sim/Makefile | 4 - board/esd/dp405/Makefile | 4 - board/esd/du405/Makefile | 4 - board/esd/hh405/Makefile | 4 - board/esd/hub405/Makefile | 4 - board/esd/ocrtc/Makefile | 4 - board/esd/pci405/Makefile | 4 - board/esd/pf5200/Makefile | 4 - board/esd/plu405/Makefile | 4 - board/esd/pmc405/Makefile | 4 - board/esd/pmc405de/Makefile | 4 - board/esd/pmc440/Makefile | 4 - board/esd/voh405/Makefile | 4 - board/esd/vom405/Makefile | 4 - board/esd/wuh405/Makefile | 4 - board/esteem192e/u-boot.lds | 4 +- board/freescale/m52277evb/u-boot.lds | 4 +- board/freescale/m53017evb/u-boot.lds | 6 +- board/freescale/mx31ads/u-boot.lds | 10 +- board/freescale/t1040qds/Makefile | 2 +- board/genietv/u-boot.lds | 10 +- board/hermes/u-boot.lds | 2 +- board/keymile/km82xx/Makefile | 3 - board/keymile/km83xx/Makefile | 4 - board/keymile/km_arm/Makefile | 4 - board/keymile/kmp204x/Makefile | 6 +- board/kup/kup4k/Makefile | 4 - board/kup/kup4x/Makefile | 4 - board/matrix_vision/mvsmr/u-boot.lds | 2 +- board/mpl/mip405/Makefile | 4 - board/mpl/pati/Makefile | 4 - board/mpl/pip405/Makefile | 4 - board/mpl/vcma9/Makefile | 4 - board/mvblue/u-boot.lds | 12 +- board/nvidia/beaver/Makefile | 2 - board/nvidia/ventana/Makefile | 2 - board/prodrive/p3mx/Makefile | 4 - board/psyent/pci5441/Makefile | 4 - board/psyent/pk1c20/Makefile | 4 - board/rbc823/u-boot.lds | 8 +- board/sandburst/karef/Makefile | 4 - board/sandburst/metrobox/Makefile | 4 - board/siemens/dxr2/Makefile | 4 - board/siemens/pxm2/Makefile | 4 - board/siemens/rut/Makefile | 4 - board/spd8xx/u-boot.lds | 4 +- board/svm_sc8xx/u-boot.lds | 10 +- board/ti/am335x/u-boot.lds | 2 +- board/ti/beagle/Makefile | 2 +- board/toradex/colibri_t20_iris/Makefile | 3 - board/tqc/tqm8260/Makefile | 4 - board/tqc/tqm8272/Makefile | 4 - board/tqc/tqm8xx/u-boot.lds | 14 +-- board/vpac270/u-boot-spl.lds | 4 +- board/xilinx/ppc405-generic/Makefile | 4 - board/xilinx/ppc440-generic/Makefile | 4 - config.mk | 6 - drivers/Makefile | 5 +- drivers/bios_emulator/Makefile | 4 +- drivers/fpga/Makefile | 2 - drivers/net/fm/Makefile | 2 - drivers/net/npe/Makefile | 2 +- drivers/qe/Makefile | 4 +- drivers/tpm/Makefile | 2 - drivers/tpm/tis_i2c.c | 185 ----------------------------- fs/Makefile | 25 ++-- fs/cbfs/Makefile | 2 +- fs/cramfs/Makefile | 4 +- fs/ext4/Makefile | 2 +- fs/fdos/Makefile | 2 +- fs/jffs2/Makefile | 2 - fs/reiserfs/Makefile | 2 +- fs/sandbox/Makefile | 2 +- fs/ubifs/Makefile | 8 +- fs/yaffs2/Makefile | 2 +- fs/zfs/Makefile | 2 +- include/configs/bct-brettl2.h | 4 +- include/configs/bf533-stamp.h | 4 +- include/configs/bf537-pnav.h | 4 +- include/configs/bf537-stamp.h | 4 +- include/configs/bf538f-ezkit.h | 4 +- include/configs/cm-bf537e.h | 4 +- include/configs/cm-bf537u.h | 4 +- include/configs/dnp5370.h | 4 +- include/configs/ibf-dsp561.h | 4 +- include/configs/tcm-bf537.h | 4 +- lib/lzma/Makefile | 2 +- lib/lzo/Makefile | 2 +- lib/rsa/Makefile | 4 +- lib/zlib/Makefile | 2 +- scripts/Makefile.build | 19 +-- spl/Makefile | 87 ++++++-------- tools/gdb/Makefile | 2 - 132 files changed, 251 insertions(+), 746 deletions(-) create mode 100644 arch/powerpc/cpu/Makefile delete mode 100644 arch/powerpc/cpu/mpc824x/.gitignore delete mode 100644 drivers/tpm/tis_i2c.c

The support for COBJS, COBJS-y, SOBJS, SOBJS-y, GLCOBJS, GLSOBJS from scripts/Makefile.build. Going forward we need to use Kbuild style consistently.
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- scripts/Makefile.build | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 2ef7341..805c3c3 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@ -10,10 +10,6 @@ SRCS :=
include Makefile
-# Backward compatible: obj-y is preferable -COBJS := $(sort $(COBJS) $(COBJS-y)) -SOBJS := $(sort $(SOBJS) $(SOBJS-y)) - # Going forward use the following obj-y := $(sort $(obj-y)) extra-y := $(sort $(extra-y)) @@ -24,11 +20,11 @@ obj-y := $(patsubst %/, %/built-in.o, $(obj-y)) subdir-obj-y := $(filter %/built-in.o, $(obj-y)) subdir-obj-y := $(addprefix $(obj),$(subdir-obj-y))
-SRCS += $(COBJS:.o=.c) $(SOBJS:.o=.S) \ - $(wildcard $(obj-y:.o=.c) $(obj-y:.o=.S) $(lib-y:.o=.c) $(lib-y:.o=.S) $(extra-y:.o=.c) $(extra-y:.o=.S)) -OBJS := $(addprefix $(obj),$(COBJS) $(SOBJS) $(obj-y)) +SRCS += $(wildcard $(obj-y:.o=.c) $(obj-y:.o=.S) $(lib-y:.o=.c) \ + $(lib-y:.o=.S) $(extra-y:.o=.c) $(extra-y:.o=.S)) +OBJS := $(addprefix $(obj),$(obj-y))
-LGOBJS := $(addprefix $(obj),$(sort $(GLSOBJS) $(GLCOBJS)) $(lib-y)) +LGOBJS := $(addprefix $(obj),$(sort $(lib-y)))
all: $(LIB) $(addprefix $(obj),$(extra-y))

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- board/freescale/t1040qds/Makefile | 2 +- board/keymile/kmp204x/Makefile | 2 +- board/ti/beagle/Makefile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/board/freescale/t1040qds/Makefile b/board/freescale/t1040qds/Makefile index a2dba6f..93af9eb 100644 --- a/board/freescale/t1040qds/Makefile +++ b/board/freescale/t1040qds/Makefile @@ -4,7 +4,7 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-y += $(BOARD).o +obj-y += t1040qds.o obj-y += ddr.o obj-$(CONFIG_PCI) += pci.o obj-y += law.o diff --git a/board/keymile/kmp204x/Makefile b/board/keymile/kmp204x/Makefile index 64eb37c..c318e08 100644 --- a/board/keymile/kmp204x/Makefile +++ b/board/keymile/kmp204x/Makefile @@ -12,5 +12,5 @@ ifneq ($(OBJTREE),$(SRCTREE)) $(shell mkdir -p $(obj)../common) endif
-obj-y := $(BOARD).o ddr.o eth.o tlb.o pci.o law.o \ +obj-y := kmp204x.o ddr.o eth.o tlb.o pci.o law.o \ ../common/common.o ../common/ivm.o diff --git a/board/ti/beagle/Makefile b/board/ti/beagle/Makefile index 9f55e8f..7a858be 100644 --- a/board/ti/beagle/Makefile +++ b/board/ti/beagle/Makefile @@ -5,5 +5,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-y := $(BOARD).o +obj-y := beagle.o obj-$(CONFIG_STATUS_LED) += led.o

- Descend into drivers/fpga/ only when CONFIG_FPGA=y - Descend into drivers/bios_emulator only when CONFIG_BIOSEMU=y
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- drivers/Makefile | 4 ++-- drivers/bios_emulator/Makefile | 2 +- drivers/fpga/Makefile | 2 -- 3 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/Makefile b/drivers/Makefile index 9cec2ba..95a4b80 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -1,8 +1,8 @@ -obj-y += bios_emulator/ +obj-$(CONFIG_BIOSEMU) += bios_emulator/ obj-y += block/ obj-$(CONFIG_BOOTCOUNT_LIMIT) += bootcount/ obj-y += crypto/ -obj-y += fpga/ +obj-$(CONFIG_FPGA) += fpga/ obj-y += hwmon/ obj-y += misc/ obj-y += pcmcia/ diff --git a/drivers/bios_emulator/Makefile b/drivers/bios_emulator/Makefile index dd42e0f..9aa8ea9 100644 --- a/drivers/bios_emulator/Makefile +++ b/drivers/bios_emulator/Makefile @@ -2,7 +2,7 @@ X86DIR = x86emu
$(shell mkdir -p $(obj)$(X86DIR))
-obj-$(CONFIG_BIOSEMU) = atibios.o biosemu.o besys.o bios.o \ +obj-y = atibios.o biosemu.o besys.o bios.o \ $(X86DIR)/decode.o \ $(X86DIR)/ops2.o \ $(X86DIR)/ops.o \ diff --git a/drivers/fpga/Makefile b/drivers/fpga/Makefile index 4fcdf40..dfb2e7f 100644 --- a/drivers/fpga/Makefile +++ b/drivers/fpga/Makefile @@ -5,7 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifdef CONFIG_FPGA obj-y += fpga.o obj-$(CONFIG_FPGA_SPARTAN2) += spartan2.o obj-$(CONFIG_FPGA_SPARTAN3) += spartan3.o @@ -19,4 +18,3 @@ obj-$(CONFIG_FPGA_ACEX1K) += ACEX1K.o obj-$(CONFIG_FPGA_CYCLON2) += cyclon2.o obj-$(CONFIG_FPGA_STRATIX_II) += stratixII.o endif -endif

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 8 ++++---- lib/lzma/Makefile | 2 +- lib/lzo/Makefile | 2 +- lib/rsa/Makefile | 4 +--- lib/zlib/Makefile | 2 +- 5 files changed, 8 insertions(+), 10 deletions(-)
diff --git a/Makefile b/Makefile index 1f499c5..e12f180 100644 --- a/Makefile +++ b/Makefile @@ -232,10 +232,10 @@ OBJS := $(addprefix $(obj),$(OBJS)) HAVE_VENDOR_COMMON_LIB = $(if $(wildcard board/$(VENDOR)/common/Makefile),y,n)
LIBS-y += lib/libgeneric.o -LIBS-y += lib/rsa/librsa.o -LIBS-y += lib/lzma/liblzma.o -LIBS-y += lib/lzo/liblzo.o -LIBS-y += lib/zlib/libz.o +LIBS-$(CONFIG_RSA) += lib/rsa/librsa.o +LIBS-$(CONFIG_LZMA) += lib/lzma/liblzma.o +LIBS-$(CONFIG_LZO) += lib/lzo/liblzo.o +LIBS-$(CONFIG_ZLIB) += lib/zlib/libz.o LIBS-$(CONFIG_TIZEN) += lib/tizen/libtizen.o LIBS-$(HAVE_VENDOR_COMMON_LIB) += board/$(VENDOR)/common/lib$(VENDOR).o LIBS-y += $(CPUDIR)/lib$(CPU).o diff --git a/lib/lzma/Makefile b/lib/lzma/Makefile index 25c6797..f8eda06 100644 --- a/lib/lzma/Makefile +++ b/lib/lzma/Makefile @@ -10,4 +10,4 @@
CFLAGS += -D_LZMA_PROB32
-obj-$(CONFIG_LZMA) += LzmaDec.o LzmaTools.o +obj-y += LzmaDec.o LzmaTools.o diff --git a/lib/lzo/Makefile b/lib/lzo/Makefile index dd853ea..2936544 100644 --- a/lib/lzo/Makefile +++ b/lib/lzo/Makefile @@ -5,4 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_LZO) += lzo1x_decompress.o +obj-y += lzo1x_decompress.o diff --git a/lib/rsa/Makefile b/lib/rsa/Makefile index 693c745..164ab39 100644 --- a/lib/rsa/Makefile +++ b/lib/rsa/Makefile @@ -7,6 +7,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifdef CONFIG_FIT_SIGNATURE -obj-$(CONFIG_RSA) += rsa-verify.o -endif +obj-$(CONFIG_FIT_SIGNATURE) += rsa-verify.o diff --git a/lib/zlib/Makefile b/lib/zlib/Makefile index 1e9e04d..2fba95f 100644 --- a/lib/zlib/Makefile +++ b/lib/zlib/Makefile @@ -5,4 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_ZLIB) += zlib.o +obj-y += zlib.o

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- drivers/tpm/Makefile | 2 - drivers/tpm/tis_i2c.c | 185 -------------------------------------------------- 2 files changed, 187 deletions(-) delete mode 100644 drivers/tpm/tis_i2c.c
diff --git a/drivers/tpm/Makefile b/drivers/tpm/Makefile index 4b8cbec..2f2353f 100644 --- a/drivers/tpm/Makefile +++ b/drivers/tpm/Makefile @@ -3,8 +3,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(obj)slb9635_i2c) - # TODO: Merge tpm_tis_lpc.c with tpm.c obj-$(CONFIG_TPM_ATMEL_TWI) += tpm_atmel_twi.o obj-$(CONFIG_TPM_TIS_I2C) += tpm.o diff --git a/drivers/tpm/tis_i2c.c b/drivers/tpm/tis_i2c.c deleted file mode 100644 index 22554e1..0000000 --- a/drivers/tpm/tis_i2c.c +++ /dev/null @@ -1,185 +0,0 @@ -/* - * Copyright (c) 2012 The Chromium OS Authors. All rights reserved. - * Use of this source code is governed by a BSD-style license that can be - * found in the LICENSE file. - */ - -#include <config.h> -#include <common.h> -#include <fdtdec.h> -#include <i2c.h> -#include "slb9635_i2c/tpm.h" - -DECLARE_GLOBAL_DATA_PTR; - -/* TPM configuration */ -struct tpm { - int i2c_bus; - int slave_addr; - char inited; - int old_bus; -} tpm; - - -static int tpm_select(void) -{ - int ret; - - tpm.old_bus = i2c_get_bus_num(); - if (tpm.old_bus != tpm.i2c_bus) { - ret = i2c_set_bus_num(tpm.i2c_bus); - if (ret) { - debug("%s: Fail to set i2c bus %d\n", __func__, - tpm.i2c_bus); - return -1; - } - } - return 0; -} - -static int tpm_deselect(void) -{ - int ret; - - if (tpm.old_bus != i2c_get_bus_num()) { - ret = i2c_set_bus_num(tpm.old_bus); - if (ret) { - debug("%s: Fail to restore i2c bus %d\n", - __func__, tpm.old_bus); - return -1; - } - } - tpm.old_bus = -1; - return 0; -} - -/** - * Decode TPM configuration. - * - * @param dev Returns a configuration of TPM device - * @return 0 if ok, -1 on error - */ -static int tpm_decode_config(struct tpm *dev) -{ -#ifdef CONFIG_OF_CONTROL - const void *blob = gd->fdt_blob; - int node, parent; - int i2c_bus; - - node = fdtdec_next_compatible(blob, 0, COMPAT_INFINEON_SLB9635_TPM); - if (node < 0) { - node = fdtdec_next_compatible(blob, 0, - COMPAT_INFINEON_SLB9645_TPM); - } - if (node < 0) { - debug("%s: Node not found\n", __func__); - return -1; - } - parent = fdt_parent_offset(blob, node); - if (parent < 0) { - debug("%s: Cannot find node parent\n", __func__); - return -1; - } - i2c_bus = i2c_get_bus_num_fdt(parent); - if (i2c_bus < 0) - return -1; - dev->i2c_bus = i2c_bus; - dev->slave_addr = fdtdec_get_addr(blob, node, "reg"); -#else - dev->i2c_bus = CONFIG_INFINEON_TPM_I2C_BUS; - dev->slave_addr = CONFIG_INFINEON_TPM_I2C_ADDR; -#endif - return 0; -} - -int tis_init(void) -{ - if (tpm.inited) - return 0; - - if (tpm_decode_config(&tpm)) - return -1; - - if (tpm_select()) - return -1; - - /* - * Probe TPM twice; the first probing might fail because TPM is asleep, - * and the probing can wake up TPM. - */ - if (i2c_probe(tpm.slave_addr) && i2c_probe(tpm.slave_addr)) { - debug("%s: fail to probe i2c addr 0x%x\n", __func__, - tpm.slave_addr); - return -1; - } - - tpm_deselect(); - - tpm.inited = 1; - - return 0; -} - -int tis_open(void) -{ - int rc; - - if (!tpm.inited) - return -1; - - if (tpm_select()) - return -1; - - rc = tpm_open(tpm.slave_addr); - - tpm_deselect(); - - return rc; -} - -int tis_close(void) -{ - if (!tpm.inited) - return -1; - - if (tpm_select()) - return -1; - - tpm_close(); - - tpm_deselect(); - - return 0; -} - -int tis_sendrecv(const uint8_t *sendbuf, size_t sbuf_size, - uint8_t *recvbuf, size_t *rbuf_len) -{ - int len; - uint8_t buf[4096]; - - if (!tpm.inited) - return -1; - - if (sizeof(buf) < sbuf_size) - return -1; - - memcpy(buf, sendbuf, sbuf_size); - - if (tpm_select()) - return -1; - - len = tpm_transmit(buf, sbuf_size); - - tpm_deselect(); - - if (len < 10) { - *rbuf_len = 0; - return -1; - } - - memcpy(recvbuf, buf, len); - *rbuf_len = len; - - return 0; -}

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- arch/powerpc/cpu/mpc512x/Makefile | 2 -- arch/powerpc/cpu/mpc824x/Makefile | 4 ---- board/LaCie/edminiv2/Makefile | 4 ---- board/LaCie/net2big_v2/Makefile | 4 ---- board/LaCie/netspace_v2/Makefile | 4 ---- board/LaCie/wireless_space/Makefile | 4 ---- board/Marvell/db64360/Makefile | 4 ---- board/Marvell/db64460/Makefile | 4 ---- board/altera/nios2-generic/Makefile | 4 ---- board/avionic-design/medcom-wide/Makefile | 2 -- board/avionic-design/plutux/Makefile | 2 -- board/avionic-design/tec/Makefile | 2 -- board/compal/paz00/Makefile | 2 -- board/compulab/trimslice/Makefile | 2 -- board/emk/top5200/Makefile | 4 ---- board/emk/top860/Makefile | 3 --- board/esd/adciop/Makefile | 4 ---- board/esd/apc405/Makefile | 4 ---- board/esd/ar405/Makefile | 4 ---- board/esd/ash405/Makefile | 4 ---- board/esd/cms700/Makefile | 4 ---- board/esd/cpci2dp/Makefile | 4 ---- board/esd/cpci405/Makefile | 4 ---- board/esd/cpci5200/Makefile | 4 ---- board/esd/cpci750/Makefile | 4 ---- board/esd/cpciiser4/Makefile | 4 ---- board/esd/dasa_sim/Makefile | 4 ---- board/esd/dp405/Makefile | 4 ---- board/esd/du405/Makefile | 4 ---- board/esd/hh405/Makefile | 4 ---- board/esd/hub405/Makefile | 4 ---- board/esd/ocrtc/Makefile | 4 ---- board/esd/pci405/Makefile | 4 ---- board/esd/pf5200/Makefile | 4 ---- board/esd/plu405/Makefile | 4 ---- board/esd/pmc405/Makefile | 4 ---- board/esd/pmc405de/Makefile | 4 ---- board/esd/pmc440/Makefile | 4 ---- board/esd/voh405/Makefile | 4 ---- board/esd/vom405/Makefile | 4 ---- board/esd/wuh405/Makefile | 4 ---- board/keymile/km82xx/Makefile | 3 --- board/keymile/km83xx/Makefile | 4 ---- board/keymile/km_arm/Makefile | 4 ---- board/keymile/kmp204x/Makefile | 4 ---- board/kup/kup4k/Makefile | 4 ---- board/kup/kup4x/Makefile | 4 ---- board/mpl/mip405/Makefile | 4 ---- board/mpl/pati/Makefile | 4 ---- board/mpl/pip405/Makefile | 4 ---- board/mpl/vcma9/Makefile | 4 ---- board/nvidia/beaver/Makefile | 2 -- board/nvidia/ventana/Makefile | 2 -- board/prodrive/p3mx/Makefile | 4 ---- board/psyent/pci5441/Makefile | 4 ---- board/psyent/pk1c20/Makefile | 4 ---- board/sandburst/karef/Makefile | 4 ---- board/sandburst/metrobox/Makefile | 4 ---- board/siemens/dxr2/Makefile | 4 ---- board/siemens/pxm2/Makefile | 4 ---- board/siemens/rut/Makefile | 4 ---- board/toradex/colibri_t20_iris/Makefile | 3 --- board/tqc/tqm8260/Makefile | 4 ---- board/tqc/tqm8272/Makefile | 4 ---- board/xilinx/ppc405-generic/Makefile | 4 ---- board/xilinx/ppc440-generic/Makefile | 4 ---- drivers/bios_emulator/Makefile | 2 -- scripts/Makefile.build | 7 +++++++ 68 files changed, 7 insertions(+), 247 deletions(-)
diff --git a/arch/powerpc/cpu/mpc512x/Makefile b/arch/powerpc/cpu/mpc512x/Makefile index f770350..a4934ef 100644 --- a/arch/powerpc/cpu/mpc512x/Makefile +++ b/arch/powerpc/cpu/mpc512x/Makefile @@ -4,8 +4,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(OBJTREE)/board/freescale/common) - extra-y = start.o obj-y := cpu.o obj-y += traps.o diff --git a/arch/powerpc/cpu/mpc824x/Makefile b/arch/powerpc/cpu/mpc824x/Makefile index 67b0d17..194fadd 100644 --- a/arch/powerpc/cpu/mpc824x/Makefile +++ b/arch/powerpc/cpu/mpc824x/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)drivers/epic $(obj)drivers/i2c) -endif - extra-y = start.o obj-y = traps.o cpu.o cpu_init.o interrupts.o speed.o \ drivers/epic/epic1.o drivers/i2c/i2c.o pci.o diff --git a/board/LaCie/edminiv2/Makefile b/board/LaCie/edminiv2/Makefile index 7ca06f5..035f686 100644 --- a/board/LaCie/edminiv2/Makefile +++ b/board/LaCie/edminiv2/Makefile @@ -9,8 +9,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := edminiv2.o ../common/common.o diff --git a/board/LaCie/net2big_v2/Makefile b/board/LaCie/net2big_v2/Makefile index 4fa08c5..f3074af 100644 --- a/board/LaCie/net2big_v2/Makefile +++ b/board/LaCie/net2big_v2/Makefile @@ -9,10 +9,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := net2big_v2.o ../common/common.o ifneq ($(and $(CONFIG_KIRKWOOD_GPIO),$(CONFIG_NET2BIG_V2)),) obj-y += ../common/cpld-gpio-bus.o diff --git a/board/LaCie/netspace_v2/Makefile b/board/LaCie/netspace_v2/Makefile index e5357e4..47778d8 100644 --- a/board/LaCie/netspace_v2/Makefile +++ b/board/LaCie/netspace_v2/Makefile @@ -9,8 +9,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := netspace_v2.o ../common/common.o diff --git a/board/LaCie/wireless_space/Makefile b/board/LaCie/wireless_space/Makefile index 11c535e..90a84f4 100644 --- a/board/LaCie/wireless_space/Makefile +++ b/board/LaCie/wireless_space/Makefile @@ -9,8 +9,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := wireless_space.o ../common/common.o diff --git a/board/Marvell/db64360/Makefile b/board/Marvell/db64360/Makefile index aad4776..aefe0a7 100644 --- a/board/Marvell/db64360/Makefile +++ b/board/Marvell/db64360/Makefile @@ -8,10 +8,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = db64360.o ../common/flash.o ../common/serial.o ../common/memory.o pci.o \ mv_eth.o ../common/ns16550.o mpsc.o ../common/i2c.o \ sdram_init.o ../common/intel_flash.o ../common/misc.o diff --git a/board/Marvell/db64460/Makefile b/board/Marvell/db64460/Makefile index ea9e570..a970f9a 100644 --- a/board/Marvell/db64460/Makefile +++ b/board/Marvell/db64460/Makefile @@ -8,10 +8,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y += db64460.o ../common/flash.o ../common/serial.o ../common/memory.o pci.o \ mv_eth.o ../common/ns16550.o mpsc.o ../common/i2c.o \ sdram_init.o ../common/intel_flash.o ../common/misc.o diff --git a/board/altera/nios2-generic/Makefile b/board/altera/nios2-generic/Makefile index 84c7bff..84690fe 100644 --- a/board/altera/nios2-generic/Makefile +++ b/board/altera/nios2-generic/Makefile @@ -6,10 +6,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := nios2-generic.o obj-$(CONFIG_CMD_IDE) += ../common/cfide.o obj-$(CONFIG_EPLED) += ../common/epled.o diff --git a/board/avionic-design/medcom-wide/Makefile b/board/avionic-design/medcom-wide/Makefile index 6c4ab64..87e1912 100644 --- a/board/avionic-design/medcom-wide/Makefile +++ b/board/avionic-design/medcom-wide/Makefile @@ -7,8 +7,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(obj)../common $(obj)../../nvidia/common) - obj-y := ../common/tamonten.o
include ../../nvidia/common/common.mk diff --git a/board/avionic-design/plutux/Makefile b/board/avionic-design/plutux/Makefile index 6c4ab64..87e1912 100644 --- a/board/avionic-design/plutux/Makefile +++ b/board/avionic-design/plutux/Makefile @@ -7,8 +7,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(obj)../common $(obj)../../nvidia/common) - obj-y := ../common/tamonten.o
include ../../nvidia/common/common.mk diff --git a/board/avionic-design/tec/Makefile b/board/avionic-design/tec/Makefile index 6c4ab64..87e1912 100644 --- a/board/avionic-design/tec/Makefile +++ b/board/avionic-design/tec/Makefile @@ -7,8 +7,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(obj)../common $(obj)../../nvidia/common) - obj-y := ../common/tamonten.o
include ../../nvidia/common/common.mk diff --git a/board/compal/paz00/Makefile b/board/compal/paz00/Makefile index 824cd2e..b2d3b6b 100644 --- a/board/compal/paz00/Makefile +++ b/board/compal/paz00/Makefile @@ -14,8 +14,6 @@ # more details. #
-$(shell mkdir -p $(obj)../../nvidia/common) - obj-y := paz00.o
include ../../nvidia/common/common.mk diff --git a/board/compulab/trimslice/Makefile b/board/compulab/trimslice/Makefile index 0818673..f3bd00d 100644 --- a/board/compulab/trimslice/Makefile +++ b/board/compulab/trimslice/Makefile @@ -5,8 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(obj)../../nvidia/common) - obj-y := trimslice.o
include ../../nvidia/common/common.mk diff --git a/board/emk/top5200/Makefile b/board/emk/top5200/Makefile index 0930d48..b455c26 100644 --- a/board/emk/top5200/Makefile +++ b/board/emk/top5200/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := top5200.o ../common/flash.o ../common/vpd.o ../common/am79c874.o diff --git a/board/emk/top860/Makefile b/board/emk/top860/Makefile index b2645f6..0401639 100644 --- a/board/emk/top860/Makefile +++ b/board/emk/top860/Makefile @@ -5,7 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif obj-y = top860.o ../common/flash.o ../common/vpd.o ../common/am79c874.o diff --git a/board/esd/adciop/Makefile b/board/esd/adciop/Makefile index a096e44..d0e264d 100644 --- a/board/esd/adciop/Makefile +++ b/board/esd/adciop/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = adciop.o flash.o ../common/misc.o ../common/pci.o diff --git a/board/esd/apc405/Makefile b/board/esd/apc405/Makefile index c6ab1a5..ada8bfd 100644 --- a/board/esd/apc405/Makefile +++ b/board/esd/apc405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = apc405.o \ ../common/misc.o \ ../common/auto_update.o diff --git a/board/esd/ar405/Makefile b/board/esd/ar405/Makefile index 2d16313..dd54f54 100644 --- a/board/esd/ar405/Makefile +++ b/board/esd/ar405/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = ar405.o flash.o ../common/misc.o diff --git a/board/esd/ash405/Makefile b/board/esd/ash405/Makefile index 4c866ee..aab8de4 100644 --- a/board/esd/ash405/Makefile +++ b/board/esd/ash405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = ash405.o flash.o \ ../common/misc.o \ ../common/esd405ep_nand.o \ diff --git a/board/esd/cms700/Makefile b/board/esd/cms700/Makefile index 8cfe3ba..2bf5006 100644 --- a/board/esd/cms700/Makefile +++ b/board/esd/cms700/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common/xilinx_jtag) -endif - # Objects for Xilinx JTAG programming (CPLD) CPLD = ../common/xilinx_jtag/lenval.o \ ../common/xilinx_jtag/micro.o \ diff --git a/board/esd/cpci2dp/Makefile b/board/esd/cpci2dp/Makefile index 1d15020..ce2c6dd 100644 --- a/board/esd/cpci2dp/Makefile +++ b/board/esd/cpci2dp/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = cpci2dp.o flash.o ../common/misc.o ../common/cmd_loadpci.o diff --git a/board/esd/cpci405/Makefile b/board/esd/cpci405/Makefile index 1af7e94..b140571 100644 --- a/board/esd/cpci405/Makefile +++ b/board/esd/cpci405/Makefile @@ -5,9 +5,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = cpci405.o flash.o ../common/misc.o ../common/auto_update.o obj-y += ../common/cmd_loadpci.o diff --git a/board/esd/cpci5200/Makefile b/board/esd/cpci5200/Makefile index fb6c0e2..8421f54 100644 --- a/board/esd/cpci5200/Makefile +++ b/board/esd/cpci5200/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-# ifneq ($(OBJTREE),$(SRCTREE)) -# $(shell mkdir -p $(obj)../common/xilinx_jtag) -# endif - # Objects for Xilinx JTAG programming (CPLD) # CPLD = ../common/xilinx_jtag/lenval.o \ # ../common/xilinx_jtag/micro.o \ diff --git a/board/esd/cpci750/Makefile b/board/esd/cpci750/Makefile index 8b3dc33..a3300c9 100644 --- a/board/esd/cpci750/Makefile +++ b/board/esd/cpci750/Makefile @@ -8,10 +8,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../../Marvell/common) -endif - obj-y = misc.o obj-y += cpci750.o serial.o ../../Marvell/common/memory.o pci.o \ mv_eth.o mpsc.o i2c.o \ diff --git a/board/esd/cpciiser4/Makefile b/board/esd/cpciiser4/Makefile index 4d3c34a..b8d6bea 100644 --- a/board/esd/cpciiser4/Makefile +++ b/board/esd/cpciiser4/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = cpciiser4.o flash.o ../common/misc.o diff --git a/board/esd/dasa_sim/Makefile b/board/esd/dasa_sim/Makefile index f0a5a8f..eb9f5f8 100644 --- a/board/esd/dasa_sim/Makefile +++ b/board/esd/dasa_sim/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = dasa_sim.o flash.o cmd_dasa_sim.o eeprom.o ../common/pci.o diff --git a/board/esd/dp405/Makefile b/board/esd/dp405/Makefile index 6809c67..cfcfb66 100644 --- a/board/esd/dp405/Makefile +++ b/board/esd/dp405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common/xilinx_jtag) -endif - # Objects for Xilinx JTAG programming (CPLD) CPLD = ../common/xilinx_jtag/lenval.o \ ../common/xilinx_jtag/micro.o \ diff --git a/board/esd/du405/Makefile b/board/esd/du405/Makefile index 12ce41a..7914eab 100644 --- a/board/esd/du405/Makefile +++ b/board/esd/du405/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = du405.o flash.o ../common/misc.o diff --git a/board/esd/hh405/Makefile b/board/esd/hh405/Makefile index 0507f1b..fba21a3 100644 --- a/board/esd/hh405/Makefile +++ b/board/esd/hh405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = hh405.o flash.o \ ../common/misc.o \ ../common/esd405ep_nand.o \ diff --git a/board/esd/hub405/Makefile b/board/esd/hub405/Makefile index 5447a95..99e18b5 100644 --- a/board/esd/hub405/Makefile +++ b/board/esd/hub405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = hub405.o flash.o \ ../common/misc.o \ ../common/esd405ep_nand.o \ diff --git a/board/esd/ocrtc/Makefile b/board/esd/ocrtc/Makefile index 0d9a6fd..44b7d5d 100644 --- a/board/esd/ocrtc/Makefile +++ b/board/esd/ocrtc/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = ocrtc.o flash.o ../common/misc.o cmd_ocrtc.o diff --git a/board/esd/pci405/Makefile b/board/esd/pci405/Makefile index 2f8706b..9e659c7 100644 --- a/board/esd/pci405/Makefile +++ b/board/esd/pci405/Makefile @@ -5,9 +5,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = pci405.o flash.o ../common/misc.o cmd_pci405.o obj-y += writeibm.o diff --git a/board/esd/pf5200/Makefile b/board/esd/pf5200/Makefile index a9d20c9..a54289c 100644 --- a/board/esd/pf5200/Makefile +++ b/board/esd/pf5200/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-# ifneq ($(OBJTREE),$(SRCTREE)) -# $(shell mkdir -p $(obj)../common/xilinx_jtag) -# endif - # Objects for Xilinx JTAG programming (CPLD) # CPLD = ../common/xilinx_jtag/lenval.o \ # ../common/xilinx_jtag/micro.o \ diff --git a/board/esd/plu405/Makefile b/board/esd/plu405/Makefile index 45b962f..6ffae67 100644 --- a/board/esd/plu405/Makefile +++ b/board/esd/plu405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = plu405.o flash.o \ ../common/misc.o \ ../common/esd405ep_nand.o \ diff --git a/board/esd/pmc405/Makefile b/board/esd/pmc405/Makefile index f4aa1c9..ad98207 100644 --- a/board/esd/pmc405/Makefile +++ b/board/esd/pmc405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common/xilinx_jtag) -endif - # Objects for Xilinx JTAG programming (CPLD) CPLD = ../common/xilinx_jtag/lenval.o \ ../common/xilinx_jtag/micro.o \ diff --git a/board/esd/pmc405de/Makefile b/board/esd/pmc405de/Makefile index 7d5b273..b3f6dcd 100644 --- a/board/esd/pmc405de/Makefile +++ b/board/esd/pmc405de/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = pmc405de.o obj-$(CONFIG_CMD_CHIP_CONFIG) += chip_config.o obj-y += ../common/cmd_loadpci.o diff --git a/board/esd/pmc440/Makefile b/board/esd/pmc440/Makefile index b1318c7..708e9d1 100644 --- a/board/esd/pmc440/Makefile +++ b/board/esd/pmc440/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = pmc440.o cmd_pmc440.o sdram.o fpga.o \ ../common/cmd_loadpci.o extra-y += init.o diff --git a/board/esd/voh405/Makefile b/board/esd/voh405/Makefile index 8fcfa37..3d82399 100644 --- a/board/esd/voh405/Makefile +++ b/board/esd/voh405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = voh405.o flash.o \ ../common/misc.o \ ../common/esd405ep_nand.o \ diff --git a/board/esd/vom405/Makefile b/board/esd/vom405/Makefile index c8a4a4e..7cf5c02 100644 --- a/board/esd/vom405/Makefile +++ b/board/esd/vom405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common/xilinx_jtag) -endif - # Objects for Xilinx JTAG programming (CPLD) CPLD = ../common/xilinx_jtag/lenval.o \ ../common/xilinx_jtag/micro.o \ diff --git a/board/esd/wuh405/Makefile b/board/esd/wuh405/Makefile index 046ebad..b9beeff 100644 --- a/board/esd/wuh405/Makefile +++ b/board/esd/wuh405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = wuh405.o flash.o \ ../common/misc.o \ ../common/esd405ep_nand.o \ diff --git a/board/keymile/km82xx/Makefile b/board/keymile/km82xx/Makefile index b44582f..20f193a 100644 --- a/board/keymile/km82xx/Makefile +++ b/board/keymile/km82xx/Makefile @@ -5,7 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif obj-y := km82xx.o ../common/common.o ../common/ivm.o diff --git a/board/keymile/km83xx/Makefile b/board/keymile/km83xx/Makefile index 7bdddf3..6c32688 100644 --- a/board/keymile/km83xx/Makefile +++ b/board/keymile/km83xx/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y += km83xx.o ../common/common.o ../common/ivm.o km83xx_i2c.o diff --git a/board/keymile/km_arm/Makefile b/board/keymile/km_arm/Makefile index 32eaa93..a17d8d9 100644 --- a/board/keymile/km_arm/Makefile +++ b/board/keymile/km_arm/Makefile @@ -6,10 +6,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := km_arm.o ../common/common.o ../common/ivm.o
ifdef CONFIG_KM_FPGA_CONFIG diff --git a/board/keymile/kmp204x/Makefile b/board/keymile/kmp204x/Makefile index c318e08..3e69ee2 100644 --- a/board/keymile/kmp204x/Makefile +++ b/board/keymile/kmp204x/Makefile @@ -8,9 +8,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := kmp204x.o ddr.o eth.o tlb.o pci.o law.o \ ../common/common.o ../common/ivm.o diff --git a/board/kup/kup4k/Makefile b/board/kup/kup4k/Makefile index b3ad86c..c896fcd 100644 --- a/board/kup/kup4k/Makefile +++ b/board/kup/kup4k/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = kup4k.o ../common/flash.o ../common/kup.o ../common/load_sernum_ethaddr.o ../common/pcmcia.o diff --git a/board/kup/kup4x/Makefile b/board/kup/kup4x/Makefile index 05a1afc..6945943 100644 --- a/board/kup/kup4x/Makefile +++ b/board/kup/kup4x/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = kup4x.o ../common/flash.o ../common/kup.o ../common/load_sernum_ethaddr.o ../common/pcmcia.o diff --git a/board/mpl/mip405/Makefile b/board/mpl/mip405/Makefile index 509eb59..5bcf130 100644 --- a/board/mpl/mip405/Makefile +++ b/board/mpl/mip405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = mip405.o cmd_mip405.o \ ../common/pci.o \ ../common/usb_uhci.o \ diff --git a/board/mpl/pati/Makefile b/board/mpl/pati/Makefile index 67381c1..9822082 100644 --- a/board/mpl/pati/Makefile +++ b/board/mpl/pati/Makefile @@ -5,9 +5,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := pati.o cmd_pati.o \ ../common/common_util.o diff --git a/board/mpl/pip405/Makefile b/board/mpl/pip405/Makefile index 3d73cc3..0a3d059 100644 --- a/board/mpl/pip405/Makefile +++ b/board/mpl/pip405/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y = pip405.o cmd_pip405.o \ ../common/pci.o \ ../common/isa.o \ diff --git a/board/mpl/vcma9/Makefile b/board/mpl/vcma9/Makefile index e0e9669..175a19f 100644 --- a/board/mpl/vcma9/Makefile +++ b/board/mpl/vcma9/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := ../common/common_util.o obj-y += vcma9.o cmd_vcma9.o
diff --git a/board/nvidia/beaver/Makefile b/board/nvidia/beaver/Makefile index f828f52..1f7c31d 100644 --- a/board/nvidia/beaver/Makefile +++ b/board/nvidia/beaver/Makefile @@ -14,6 +14,4 @@ # along with this program. If not, see http://www.gnu.org/licenses/. #
-$(shell mkdir -p $(obj)../cardhu) - obj-y = ../cardhu/cardhu.o diff --git a/board/nvidia/ventana/Makefile b/board/nvidia/ventana/Makefile index 7265cfc..f67044f 100644 --- a/board/nvidia/ventana/Makefile +++ b/board/nvidia/ventana/Makefile @@ -5,6 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(obj)../seaboard) - obj-y = ../seaboard/seaboard.o diff --git a/board/prodrive/p3mx/Makefile b/board/prodrive/p3mx/Makefile index 43caffb..6ddda22 100644 --- a/board/prodrive/p3mx/Makefile +++ b/board/prodrive/p3mx/Makefile @@ -5,10 +5,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../../Marvell/common) -endif - obj-y = misc.o obj-y += p3mx.o mpsc.o mv_eth.o pci.o sdram_init.o serial.o \ ../../Marvell/common/i2c.o ../../Marvell/common/memory.o diff --git a/board/psyent/pci5441/Makefile b/board/psyent/pci5441/Makefile index 9a66cfd..364f163 100644 --- a/board/psyent/pci5441/Makefile +++ b/board/psyent/pci5441/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := pci5441.o ../common/AMDLV065D.o diff --git a/board/psyent/pk1c20/Makefile b/board/psyent/pk1c20/Makefile index 286db94..5450f93 100644 --- a/board/psyent/pk1c20/Makefile +++ b/board/psyent/pk1c20/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - obj-y := pk1c20.o led.o ../common/AMDLV065D.o diff --git a/board/sandburst/karef/Makefile b/board/sandburst/karef/Makefile index 05c8187..f890008 100644 --- a/board/sandburst/karef/Makefile +++ b/board/sandburst/karef/Makefile @@ -9,10 +9,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - # TBS: add for debugging purposes BUILDUSER := $(shell whoami) FORCEBUILD := $(shell rm -f karef.o) diff --git a/board/sandburst/metrobox/Makefile b/board/sandburst/metrobox/Makefile index 76dfffc..37d91a5 100644 --- a/board/sandburst/metrobox/Makefile +++ b/board/sandburst/metrobox/Makefile @@ -8,10 +8,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - # TBS: add for debugging purposes BUILDUSER := $(shell whoami) FORCEBUILD := $(shell rm -f metrobox.o) diff --git a/board/siemens/dxr2/Makefile b/board/siemens/dxr2/Makefile index 5129c6e..f159932 100644 --- a/board/siemens/dxr2/Makefile +++ b/board/siemens/dxr2/Makefile @@ -11,10 +11,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - ifdef CONFIG_SPL_BUILD obj-y := mux.o endif diff --git a/board/siemens/pxm2/Makefile b/board/siemens/pxm2/Makefile index 5129c6e..f159932 100644 --- a/board/siemens/pxm2/Makefile +++ b/board/siemens/pxm2/Makefile @@ -11,10 +11,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - ifdef CONFIG_SPL_BUILD obj-y := mux.o endif diff --git a/board/siemens/rut/Makefile b/board/siemens/rut/Makefile index 5129c6e..f159932 100644 --- a/board/siemens/rut/Makefile +++ b/board/siemens/rut/Makefile @@ -11,10 +11,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../common) -endif - ifdef CONFIG_SPL_BUILD obj-y := mux.o endif diff --git a/board/toradex/colibri_t20_iris/Makefile b/board/toradex/colibri_t20_iris/Makefile index 7ca3fe5..ebeac70 100644 --- a/board/toradex/colibri_t20_iris/Makefile +++ b/board/toradex/colibri_t20_iris/Makefile @@ -4,9 +4,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-$(shell mkdir -p $(obj)../../nvidia/common) -$(shell mkdir -p $(obj)../colibri_t20-common) - obj-y := ../../nvidia/common/board.o obj-y += ../colibri_t20-common/colibri_t20-common.o obj-y += colibri_t20_iris.o diff --git a/board/tqc/tqm8260/Makefile b/board/tqc/tqm8260/Makefile index dc4a528..6b8573d 100644 --- a/board/tqc/tqm8260/Makefile +++ b/board/tqc/tqm8260/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../tqm8xx/) -endif - obj-y = tqm8260.o ../tqm8xx/load_sernum_ethaddr.o diff --git a/board/tqc/tqm8272/Makefile b/board/tqc/tqm8272/Makefile index 09af765..8bf0241 100644 --- a/board/tqc/tqm8272/Makefile +++ b/board/tqc/tqm8272/Makefile @@ -5,8 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../tqm8xx/) -endif - obj-y = tqm8272.o ../tqm8xx/load_sernum_ethaddr.o nand.o diff --git a/board/xilinx/ppc405-generic/Makefile b/board/xilinx/ppc405-generic/Makefile index 1562f17..c9da870 100644 --- a/board/xilinx/ppc405-generic/Makefile +++ b/board/xilinx/ppc405-generic/Makefile @@ -9,8 +9,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../../xilinx/ppc405-generic) -endif - obj-y += ../../xilinx/ppc405-generic/xilinx_ppc405_generic.o diff --git a/board/xilinx/ppc440-generic/Makefile b/board/xilinx/ppc440-generic/Makefile index b2227c5..0acd95d 100644 --- a/board/xilinx/ppc440-generic/Makefile +++ b/board/xilinx/ppc440-generic/Makefile @@ -9,9 +9,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifneq ($(OBJTREE),$(SRCTREE)) -$(shell mkdir -p $(obj)../../xilinx/ppc440-generic) -endif - obj-y += ../../xilinx/ppc440-generic/xilinx_ppc440_generic.o extra-y += ../../xilinx/ppc440-generic/init.o diff --git a/drivers/bios_emulator/Makefile b/drivers/bios_emulator/Makefile index 9aa8ea9..6f74fdc 100644 --- a/drivers/bios_emulator/Makefile +++ b/drivers/bios_emulator/Makefile @@ -1,7 +1,5 @@ X86DIR = x86emu
-$(shell mkdir -p $(obj)$(X86DIR)) - obj-y = atibios.o biosemu.o besys.o bios.o \ $(X86DIR)/decode.o \ $(X86DIR)/ops2.o \ diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 805c3c3..e3354aa 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@ -24,6 +24,13 @@ SRCS += $(wildcard $(obj-y:.o=.c) $(obj-y:.o=.S) $(lib-y:.o=.c) \ $(lib-y:.o=.S) $(extra-y:.o=.c) $(extra-y:.o=.S)) OBJS := $(addprefix $(obj),$(obj-y))
+# $(obj-dirs) is a list of directories that contain object files +obj-dirs := $(dir $(OBJS)) + +# Create directories for object files if directory does not exist +# Needed when obj-y := dir/file.o syntax is used +_dummy := $(foreach d,$(obj-dirs), $(shell [ -d $(d) ] || mkdir -p $(d))) + LGOBJS := $(addprefix $(obj),$(sort $(lib-y)))
all: $(LIB) $(addprefix $(obj),$(extra-y))

We do not need to handle $(LIBBOARD) and $(LIBS) separately.
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-)
diff --git a/Makefile b/Makefile index e12f180..419278a 100644 --- a/Makefile +++ b/Makefile @@ -306,12 +306,11 @@ endif
LIBS-$(CONFIG_ARM) += arch/arm/cpu/libcpu.o
+LIBS-y += board/$(BOARDDIR)/lib$(BOARD).o + LIBS := $(addprefix $(obj),$(sort $(LIBS-y))) .PHONY : $(LIBS)
-LIBBOARD = board/$(BOARDDIR)/lib$(BOARD).o -LIBBOARD := $(addprefix $(obj),$(LIBBOARD)) - # Add GCC lib ifdef USE_PRIVATE_LIBGCC ifeq ("$(USE_PRIVATE_LIBGCC)", "yes") @@ -335,7 +334,7 @@ LDPPFLAGS += \ sed -ne 's/GNU ld version ([0-9][0-9]*).([0-9][0-9]*).*/-DLD_MAJOR=\1 -DLD_MINOR=\2/p')
__OBJS := $(subst $(obj),,$(OBJS)) -__LIBS := $(subst $(obj),,$(LIBS)) $(subst $(obj),,$(LIBBOARD)) +__LIBS := $(subst $(obj),,$(LIBS))
######################################################################### ######################################################################### @@ -549,7 +548,7 @@ GEN_UBOOT = \ endif
$(obj)u-boot: depend \ - $(SUBDIR_TOOLS) $(OBJS) $(LIBBOARD) $(LIBS) $(LDSCRIPT) $(obj)u-boot.lds + $(SUBDIR_TOOLS) $(OBJS) $(LIBS) $(LDSCRIPT) $(obj)u-boot.lds $(GEN_UBOOT) ifeq ($(CONFIG_KALLSYMS),y) smap=`$(call SYSTEM_MAP,$(obj)u-boot) | \ @@ -566,10 +565,6 @@ $(LIBS): depend $(SUBDIR_TOOLS) $(MAKE) $(build) $(dir $(subst $(obj),,$@)) mv $(dir $@)built-in.o $@
-$(LIBBOARD): depend $(LIBS) - $(MAKE) $(build) $(dir $(subst $(obj),,$@)) - mv $(dir $@)built-in.o $@ - $(SUBDIRS): depend $(MAKE) -C $@ all

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 9 +-------- arch/powerpc/cpu/Makefile | 3 +++ arch/powerpc/cpu/mpc8xxx/Makefile | 6 ++++++ spl/Makefile | 13 +------------ 4 files changed, 11 insertions(+), 20 deletions(-) create mode 100644 arch/powerpc/cpu/Makefile
diff --git a/Makefile b/Makefile index 419278a..3a8ea67 100644 --- a/Makefile +++ b/Makefile @@ -273,18 +273,10 @@ LIBS-y += drivers/power/libpower.o \ LIBS-y += drivers/spi/libspi.o ifeq ($(CPU),mpc83xx) LIBS-y += drivers/qe/libqe.o -LIBS-y += arch/powerpc/cpu/mpc8xxx/ddr/libddr.o -LIBS-y += arch/powerpc/cpu/mpc8xxx/lib8xxx.o endif ifeq ($(CPU),mpc85xx) LIBS-y += drivers/qe/libqe.o LIBS-y += drivers/net/fm/libfm.o -LIBS-y += arch/powerpc/cpu/mpc8xxx/ddr/libddr.o -LIBS-y += arch/powerpc/cpu/mpc8xxx/lib8xxx.o -endif -ifeq ($(CPU),mpc86xx) -LIBS-y += arch/powerpc/cpu/mpc8xxx/ddr/libddr.o -LIBS-y += arch/powerpc/cpu/mpc8xxx/lib8xxx.o endif LIBS-y += drivers/serial/libserial.o LIBS-y += drivers/usb/eth/libusb_eth.o @@ -305,6 +297,7 @@ LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif
LIBS-$(CONFIG_ARM) += arch/arm/cpu/libcpu.o +LIBS-$(CONFIG_PPC) += arch/powerpc/cpu/libcpu.o
LIBS-y += board/$(BOARDDIR)/lib$(BOARD).o
diff --git a/arch/powerpc/cpu/Makefile b/arch/powerpc/cpu/Makefile new file mode 100644 index 0000000..d630abe --- /dev/null +++ b/arch/powerpc/cpu/Makefile @@ -0,0 +1,3 @@ +ifneq ($(filter mpc83xx mpc85xx mpc86xx,$(CPU)),) +obj-y += mpc8xxx/ +endif diff --git a/arch/powerpc/cpu/mpc8xxx/Makefile b/arch/powerpc/cpu/mpc8xxx/Makefile index 395fed1..1d083bf 100644 --- a/arch/powerpc/cpu/mpc8xxx/Makefile +++ b/arch/powerpc/cpu/mpc8xxx/Makefile @@ -31,3 +31,9 @@ obj-$(CONFIG_SYS_SRIO) += srio.o obj-$(CONFIG_FSL_LAW) += law.o
endif + +ifdef CONFIG_SPL_BUILD +obj-$(CONFIG_SPL_MPC8XXX_INIT_DDR_SUPPORT) += ddr/ +else +obj-y += ddr/ +endif diff --git a/spl/Makefile b/spl/Makefile index cbd3d27..0ac0c3c 100644 --- a/spl/Makefile +++ b/spl/Makefile @@ -57,18 +57,6 @@ endif LIBS-y += arch/$(ARCH)/lib/lib$(ARCH).o
LIBS-y += $(CPUDIR)/lib$(CPU).o -ifeq ($(CPU),mpc83xx) -LIBS-y += arch/powerpc/cpu/mpc8xxx/lib8xxx.o -endif -ifeq ($(CPU),mpc85xx) -LIBS-y += arch/powerpc/cpu/mpc8xxx/lib8xxx.o -ifdef CONFIG_SPL_MPC8XXX_INIT_DDR_SUPPORT -LIBS-y += arch/powerpc/cpu/mpc8xxx/ddr/libddr.o -endif -endif -ifeq ($(CPU),mpc86xx) -LIBS-y += arch/powerpc/cpu/mpc8xxx/lib8xxx.o -endif
ifdef SOC LIBS-y += $(CPUDIR)/$(SOC)/lib$(SOC).o @@ -106,6 +94,7 @@ LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif
LIBS-$(CONFIG_ARM) += arch/arm/cpu/libcpu.o +LIBS-$(CONFIG_PPC) += arch/powerpc/cpu/libcpu.o
ifneq ($(CONFIG_MX23)$(CONFIG_MX35),) LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 4 ---- drivers/Makefile | 1 + drivers/qe/Makefile | 4 ++-- 3 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/Makefile b/Makefile index 3a8ea67..0e9609f 100644 --- a/Makefile +++ b/Makefile @@ -271,11 +271,7 @@ LIBS-y += drivers/power/libpower.o \ drivers/power/pmic/libpmic.o \ drivers/power/battery/libbattery.o LIBS-y += drivers/spi/libspi.o -ifeq ($(CPU),mpc83xx) -LIBS-y += drivers/qe/libqe.o -endif ifeq ($(CPU),mpc85xx) -LIBS-y += drivers/qe/libqe.o LIBS-y += drivers/net/fm/libfm.o endif LIBS-y += drivers/serial/libserial.o diff --git a/drivers/Makefile b/drivers/Makefile index 95a4b80..5d03f37 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -13,3 +13,4 @@ obj-y += tpm/ obj-y += twserial/ obj-y += video/ obj-y += watchdog/ +obj-$(CONFIG_QE) += qe/ diff --git a/drivers/qe/Makefile b/drivers/qe/Makefile index b8c15f8..7f1bd06 100644 --- a/drivers/qe/Makefile +++ b/drivers/qe/Makefile @@ -4,5 +4,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(and $(CONFIG_QE),$(CONFIG_OF_LIBFDT)) += fdt.o -obj-$(CONFIG_QE) += qe.o uccf.o uec.o uec_phy.o +obj-y := qe.o uccf.o uec.o uec_phy.o +obj-$(CONFIG_OF_LIBFDT) += fdt.o

CONFIG_FMAN_ENET is defined only for CPU mpc85xx. We do not need to filter by CPU mpc85xx.
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 4 +--- drivers/net/fm/Makefile | 2 -- 2 files changed, 1 insertion(+), 5 deletions(-)
diff --git a/Makefile b/Makefile index 0e9609f..5cdfc6d 100644 --- a/Makefile +++ b/Makefile @@ -271,9 +271,7 @@ LIBS-y += drivers/power/libpower.o \ drivers/power/pmic/libpmic.o \ drivers/power/battery/libbattery.o LIBS-y += drivers/spi/libspi.o -ifeq ($(CPU),mpc85xx) -LIBS-y += drivers/net/fm/libfm.o -endif +LIBS-$(CONFIG_FMAN_ENET) += drivers/net/fm/libfm.o LIBS-y += drivers/serial/libserial.o LIBS-y += drivers/usb/eth/libusb_eth.o LIBS-y += drivers/usb/gadget/libusb_gadget.o diff --git a/drivers/net/fm/Makefile b/drivers/net/fm/Makefile index bec86c1..eec75fd 100644 --- a/drivers/net/fm/Makefile +++ b/drivers/net/fm/Makefile @@ -4,7 +4,6 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifdef CONFIG_FMAN_ENET obj-y += dtsec.o obj-y += eth.o obj-y += fm.o @@ -30,4 +29,3 @@ obj-$(CONFIG_PPC_T4240) += t4240.o obj-$(CONFIG_PPC_T4160) += t4240.o obj-$(CONFIG_PPC_B4420) += b4860.o obj-$(CONFIG_PPC_B4860) += b4860.o -endif

CONFIG_IXP4XX_NPE is defined only for CPU ixp. It is not necessary to filter by CPU ixp.
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 4 +--- drivers/net/npe/Makefile | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/Makefile b/Makefile index 5cdfc6d..4724f41 100644 --- a/Makefile +++ b/Makefile @@ -242,9 +242,7 @@ LIBS-y += $(CPUDIR)/lib$(CPU).o ifdef SOC LIBS-y += $(CPUDIR)/$(SOC)/lib$(SOC).o endif -ifeq ($(CPU),ixp) -LIBS-y += drivers/net/npe/libnpe.o -endif +LIBS-$(CONFIG_IXP4XX_NPE) += drivers/net/npe/libnpe.o LIBS-$(CONFIG_OF_EMBED) += dts/libdts.o LIBS-y += arch/$(ARCH)/lib/lib$(ARCH).o LIBS-y += fs/libfs.o \ diff --git a/drivers/net/npe/Makefile b/drivers/net/npe/Makefile index 7fa5ea6..e36c0bb 100644 --- a/drivers/net/npe/Makefile +++ b/drivers/net/npe/Makefile @@ -10,7 +10,7 @@ CFLAGS += $(LOCAL_CFLAGS) CPPFLAGS += $(LOCAL_CFLAGS) # needed for depend HOSTCFLAGS += $(LOCAL_CFLAGS)
-obj-$(CONFIG_IXP4XX_NPE) := npe.o \ +obj-y := npe.o \ miiphy.o \ IxOsalBufferMgt.o \ IxOsalIoMem.o \

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 112 ++++++++++++++--------------- arch/microblaze/cpu/u-boot.lds | 2 +- board/LEOX/elpt860/u-boot.lds | 8 +-- board/actux1/u-boot.lds | 8 +-- board/actux2/u-boot.lds | 8 +-- board/actux3/u-boot.lds | 8 +-- board/davinci/da8xxevm/u-boot-spl-hawk.lds | 4 +- board/dvlhost/u-boot.lds | 8 +-- board/esteem192e/u-boot.lds | 4 +- board/freescale/m52277evb/u-boot.lds | 4 +- board/freescale/m53017evb/u-boot.lds | 6 +- board/freescale/mx31ads/u-boot.lds | 10 +-- board/genietv/u-boot.lds | 10 +-- board/hermes/u-boot.lds | 2 +- board/matrix_vision/mvsmr/u-boot.lds | 2 +- board/mvblue/u-boot.lds | 12 ++-- board/rbc823/u-boot.lds | 8 +-- board/spd8xx/u-boot.lds | 4 +- board/svm_sc8xx/u-boot.lds | 10 +-- board/ti/am335x/u-boot.lds | 2 +- board/tqc/tqm8xx/u-boot.lds | 14 ++-- board/vpac270/u-boot-spl.lds | 4 +- include/configs/bct-brettl2.h | 4 +- include/configs/bf533-stamp.h | 4 +- include/configs/bf537-pnav.h | 4 +- include/configs/bf537-stamp.h | 4 +- include/configs/bf538f-ezkit.h | 4 +- include/configs/cm-bf537e.h | 4 +- include/configs/cm-bf537u.h | 4 +- include/configs/dnp5370.h | 4 +- include/configs/ibf-dsp561.h | 4 +- include/configs/tcm-bf537.h | 4 +- spl/Makefile | 73 +++++++++---------- 33 files changed, 182 insertions(+), 181 deletions(-)
diff --git a/Makefile b/Makefile index 4724f41..1389ee7 100644 --- a/Makefile +++ b/Makefile @@ -231,68 +231,69 @@ OBJS := $(addprefix $(obj),$(OBJS))
HAVE_VENDOR_COMMON_LIB = $(if $(wildcard board/$(VENDOR)/common/Makefile),y,n)
-LIBS-y += lib/libgeneric.o -LIBS-$(CONFIG_RSA) += lib/rsa/librsa.o -LIBS-$(CONFIG_LZMA) += lib/lzma/liblzma.o -LIBS-$(CONFIG_LZO) += lib/lzo/liblzo.o -LIBS-$(CONFIG_ZLIB) += lib/zlib/libz.o -LIBS-$(CONFIG_TIZEN) += lib/tizen/libtizen.o -LIBS-$(HAVE_VENDOR_COMMON_LIB) += board/$(VENDOR)/common/lib$(VENDOR).o -LIBS-y += $(CPUDIR)/lib$(CPU).o +LIBS-y += lib/ +LIBS-$(CONFIG_RSA) += lib/rsa/ +LIBS-$(CONFIG_LZMA) += lib/lzma/ +LIBS-$(CONFIG_LZO) += lib/lzo/ +LIBS-$(CONFIG_ZLIB) += lib/zlib/ +LIBS-$(CONFIG_TIZEN) += lib/tizen/ +LIBS-$(HAVE_VENDOR_COMMON_LIB) += board/$(VENDOR)/common/ +LIBS-y += $(CPUDIR)/ ifdef SOC -LIBS-y += $(CPUDIR)/$(SOC)/lib$(SOC).o -endif -LIBS-$(CONFIG_IXP4XX_NPE) += drivers/net/npe/libnpe.o -LIBS-$(CONFIG_OF_EMBED) += dts/libdts.o -LIBS-y += arch/$(ARCH)/lib/lib$(ARCH).o -LIBS-y += fs/libfs.o \ - fs/fat/libfat.o -LIBS-y += net/libnet.o -LIBS-y += disk/libdisk.o -LIBS-y += drivers/libdrivers.o -LIBS-y += drivers/dma/libdma.o -LIBS-y += drivers/gpio/libgpio.o -LIBS-y += drivers/i2c/libi2c.o -LIBS-y += drivers/input/libinput.o -LIBS-y += drivers/mmc/libmmc.o -LIBS-y += drivers/mtd/libmtd.o -LIBS-y += drivers/mtd/nand/libnand.o -LIBS-y += drivers/mtd/onenand/libonenand.o -LIBS-y += drivers/mtd/ubi/libubi.o -LIBS-y += drivers/mtd/spi/libspi_flash.o -LIBS-y += drivers/net/libnet.o -LIBS-y += drivers/net/phy/libphy.o -LIBS-y += drivers/pci/libpci.o -LIBS-y += drivers/power/libpower.o \ - drivers/power/fuel_gauge/libfuel_gauge.o \ - drivers/power/mfd/libmfd.o \ - drivers/power/pmic/libpmic.o \ - drivers/power/battery/libbattery.o -LIBS-y += drivers/spi/libspi.o -LIBS-$(CONFIG_FMAN_ENET) += drivers/net/fm/libfm.o -LIBS-y += drivers/serial/libserial.o -LIBS-y += drivers/usb/eth/libusb_eth.o -LIBS-y += drivers/usb/gadget/libusb_gadget.o -LIBS-y += drivers/usb/host/libusb_host.o -LIBS-y += drivers/usb/musb/libusb_musb.o -LIBS-y += drivers/usb/musb-new/libusb_musb-new.o -LIBS-y += drivers/usb/phy/libusb_phy.o -LIBS-y += drivers/usb/ulpi/libusb_ulpi.o -LIBS-y += common/libcommon.o -LIBS-y += lib/libfdt/libfdt.o -LIBS-y += api/libapi.o -LIBS-y += post/libpost.o -LIBS-y += test/libtest.o +LIBS-y += $(CPUDIR)/$(SOC)/ +endif +LIBS-$(CONFIG_IXP4XX_NPE) += drivers/net/npe/ +LIBS-$(CONFIG_OF_EMBED) += dts/ +LIBS-y += arch/$(ARCH)/lib/ +LIBS-y += fs/ \ + fs/fat/ +LIBS-y += net/ +LIBS-y += disk/ +LIBS-y += drivers/ +LIBS-y += drivers/dma/ +LIBS-y += drivers/gpio/ +LIBS-y += drivers/i2c/ +LIBS-y += drivers/input/ +LIBS-y += drivers/mmc/ +LIBS-y += drivers/mtd/ +LIBS-y += drivers/mtd/nand/ +LIBS-y += drivers/mtd/onenand/ +LIBS-y += drivers/mtd/ubi/ +LIBS-y += drivers/mtd/spi/ +LIBS-y += drivers/net/ +LIBS-y += drivers/net/phy/ +LIBS-y += drivers/pci/ +LIBS-y += drivers/power/ \ + drivers/power/fuel_gauge/ \ + drivers/power/mfd/ \ + drivers/power/pmic/ \ + drivers/power/battery/ +LIBS-y += drivers/spi/ +LIBS-$(CONFIG_FMAN_ENET) += drivers/net/fm/ +LIBS-y += drivers/serial/ +LIBS-y += drivers/usb/eth/ +LIBS-y += drivers/usb/gadget/ +LIBS-y += drivers/usb/host/ +LIBS-y += drivers/usb/musb/ +LIBS-y += drivers/usb/musb-new/ +LIBS-y += drivers/usb/phy/ +LIBS-y += drivers/usb/ulpi/ +LIBS-y += common/ +LIBS-y += lib/libfdt/ +LIBS-y += api/ +LIBS-y += post/ +LIBS-y += test/
ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35 mxs vf610)) -LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o +LIBS-y += arch/$(ARCH)/imx-common/ endif
-LIBS-$(CONFIG_ARM) += arch/arm/cpu/libcpu.o -LIBS-$(CONFIG_PPC) += arch/powerpc/cpu/libcpu.o +LIBS-$(CONFIG_ARM) += arch/arm/cpu/ +LIBS-$(CONFIG_PPC) += arch/powerpc/cpu/
-LIBS-y += board/$(BOARDDIR)/lib$(BOARD).o +LIBS-y += board/$(BOARDDIR)/
+LIBS-y := $(patsubst %/, %/built-in.o, $(LIBS-y)) LIBS := $(addprefix $(obj),$(sort $(LIBS-y))) .PHONY : $(LIBS)
@@ -548,7 +549,6 @@ $(OBJS):
$(LIBS): depend $(SUBDIR_TOOLS) $(MAKE) $(build) $(dir $(subst $(obj),,$@)) - mv $(dir $@)built-in.o $@
$(SUBDIRS): depend $(MAKE) -C $@ all diff --git a/arch/microblaze/cpu/u-boot.lds b/arch/microblaze/cpu/u-boot.lds index 3e6204d..fdad207 100644 --- a/arch/microblaze/cpu/u-boot.lds +++ b/arch/microblaze/cpu/u-boot.lds @@ -30,7 +30,7 @@ SECTIONS { __data_start = .; #ifdef CONFIG_OF_EMBED - dts/libdts.o (.data) + dts/built-in.o (.data) #endif *(.data) __data_end = .; diff --git a/board/LEOX/elpt860/u-boot.lds b/board/LEOX/elpt860/u-boot.lds index b30b667..c5e57ec 100644 --- a/board/LEOX/elpt860/u-boot.lds +++ b/board/LEOX/elpt860/u-boot.lds @@ -30,10 +30,10 @@ SECTIONS
arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*) - common/libcommon.o (.text*) - arch/powerpc/cpu/mpc8xx/libmpc8xx.o (.text*) - board/LEOX/elpt860/libelpt860.o (.text*) - arch/powerpc/lib/libpowerpc.o (.text*) + common/built-in.o (.text*) + arch/powerpc/cpu/mpc8xx/built-in.o (.text*) + board/LEOX/elpt860/built-in.o (.text*) + arch/powerpc/lib/built-in.o (.text*)
. = env_offset; common/env_embedded.o (.text*) diff --git a/board/actux1/u-boot.lds b/board/actux1/u-boot.lds index a656fa9..b0f09f5 100644 --- a/board/actux1/u-boot.lds +++ b/board/actux1/u-boot.lds @@ -16,10 +16,10 @@ SECTIONS .text : { *(.__image_copy_start) arch/arm/cpu/ixp/start.o(.text*) - net/libnet.o(.text*) - board/actux1/libactux1.o(.text*) - arch/arm/cpu/ixp/libixp.o(.text*) - drivers/input/libinput.o(.text*) + net/built-in.o(.text*) + board/actux1/built-in.o(.text*) + arch/arm/cpu/ixp/built-in.o(.text*) + drivers/input/built-in.o(.text*)
. = env_offset; common/env_embedded.o(.ppcenv) diff --git a/board/actux2/u-boot.lds b/board/actux2/u-boot.lds index 7a17176..d84934e 100644 --- a/board/actux2/u-boot.lds +++ b/board/actux2/u-boot.lds @@ -16,10 +16,10 @@ SECTIONS .text : { *(.__image_copy_start) arch/arm/cpu/ixp/start.o(.text*) - net/libnet.o(.text*) - board/actux2/libactux2.o(.text*) - arch/arm/cpu/ixp/libixp.o(.text*) - drivers/input/libinput.o(.text*) + net/built-in.o(.text*) + board/actux2/built-in.o(.text*) + arch/arm/cpu/ixp/built-in.o(.text*) + drivers/input/built-in.o(.text*)
. = env_offset; common/env_embedded.o(.ppcenv) diff --git a/board/actux3/u-boot.lds b/board/actux3/u-boot.lds index aadfdd2..30c204b 100644 --- a/board/actux3/u-boot.lds +++ b/board/actux3/u-boot.lds @@ -16,10 +16,10 @@ SECTIONS .text : { *(.__image_copy_start) arch/arm/cpu/ixp/start.o(.text*) - net/libnet.o(.text*) - board/actux3/libactux3.o(.text*) - arch/arm/cpu/ixp/libixp.o(.text*) - drivers/input/libinput.o(.text*) + net/built-in.o(.text*) + board/actux3/built-in.o(.text*) + arch/arm/cpu/ixp/built-in.o(.text*) + drivers/input/built-in.o(.text*)
. = env_offset; common/env_embedded.o(.ppcenv) diff --git a/board/davinci/da8xxevm/u-boot-spl-hawk.lds b/board/davinci/da8xxevm/u-boot-spl-hawk.lds index e43130a..d49c314 100644 --- a/board/davinci/da8xxevm/u-boot-spl-hawk.lds +++ b/board/davinci/da8xxevm/u-boot-spl-hawk.lds @@ -19,8 +19,8 @@ SECTIONS .text : { arch/arm/cpu/arm926ejs/start.o (.text*) - arch/arm/cpu/arm926ejs/davinci/libdavinci.o (.text*) - drivers/mtd/nand/libnand.o (.text*) + arch/arm/cpu/arm926ejs/davinci/built-in.o (.text*) + drivers/mtd/nand/built-in.o (.text*)
*(.text*) } diff --git a/board/dvlhost/u-boot.lds b/board/dvlhost/u-boot.lds index 40c9c80..0035a0b 100644 --- a/board/dvlhost/u-boot.lds +++ b/board/dvlhost/u-boot.lds @@ -16,10 +16,10 @@ SECTIONS .text : { *(.__image_copy_start) arch/arm/cpu/ixp/start.o(.text*) - net/libnet.o(.text*) - board/dvlhost/libdvlhost.o(.text*) - arch/arm/cpu/ixp/libixp.o(.text*) - drivers/serial/libserial.o(.text*) + net/built-in.o(.text*) + board/dvlhost/built-in.o(.text*) + arch/arm/cpu/ixp/built-in.o(.text*) + drivers/serial/built-in.o(.text*)
. = env_offset; common/env_embedded.o(.ppcenv) diff --git a/board/esteem192e/u-boot.lds b/board/esteem192e/u-boot.lds index 87642d6..59a86bf 100644 --- a/board/esteem192e/u-boot.lds +++ b/board/esteem192e/u-boot.lds @@ -18,8 +18,8 @@ SECTIONS
arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*) - net/libnet.o (.text*) - board/esteem192e/libesteem192e.o (.text*) + net/built-in.o (.text*) + board/esteem192e/built-in.o (.text*)
. = env_offset; common/env_embedded.o (.text*) diff --git a/board/freescale/m52277evb/u-boot.lds b/board/freescale/m52277evb/u-boot.lds index f3337a3..70121d9 100644 --- a/board/freescale/m52277evb/u-boot.lds +++ b/board/freescale/m52277evb/u-boot.lds @@ -13,8 +13,8 @@ SECTIONS .text : { arch/m68k/cpu/mcf5227x/start.o (.text*) - arch/m68k/cpu/mcf5227x/libmcf5227x.o (.text*) - arch/m68k/lib/libm68k.o (.text*) + arch/m68k/cpu/mcf5227x/built-in.o (.text*) + arch/m68k/lib/built-in.o (.text*)
*(.text*) } diff --git a/board/freescale/m53017evb/u-boot.lds b/board/freescale/m53017evb/u-boot.lds index ef21299..de8d09b 100644 --- a/board/freescale/m53017evb/u-boot.lds +++ b/board/freescale/m53017evb/u-boot.lds @@ -12,9 +12,9 @@ SECTIONS /* Read-only sections, merged into text segment: */ .text : { - arch/m68k/cpu/mcf532x/start.o (.text*) - arch/m68k/cpu/mcf532x/libmcf532x.o (.text*) - arch/m68k/lib/libm68k.o (.text*) + arch/m68k/cpu/mcf532x/start.o (.text*) + arch/m68k/cpu/mcf532x/built-in.o (.text*) + arch/m68k/lib/built-in.o (.text*)
. = DEFINED(env_offset) ? env_offset : .; common/env_embedded.o (.text*) diff --git a/board/freescale/mx31ads/u-boot.lds b/board/freescale/mx31ads/u-boot.lds index 3acc4ca..8d5cc91 100644 --- a/board/freescale/mx31ads/u-boot.lds +++ b/board/freescale/mx31ads/u-boot.lds @@ -22,11 +22,11 @@ SECTIONS /* WARNING - the following is hand-optimized to fit within */ /* the sector layout of our flash chips! XXX FIXME XXX */
- arch/arm/cpu/arm1136/start.o (.text*) - board/freescale/mx31ads/libmx31ads.o (.text*) - arch/arm/lib/libarm.o (.text*) - net/libnet.o (.text*) - drivers/mtd/libmtd.o (.text*) + arch/arm/cpu/arm1136/start.o (.text*) + board/freescale/mx31ads/built-in.o (.text*) + arch/arm/lib/built-in.o (.text*) + net/built-in.o (.text*) + drivers/mtd/built-in.o (.text*)
. = DEFINED(env_offset) ? env_offset : .; common/env_embedded.o(.text*) diff --git a/board/genietv/u-boot.lds b/board/genietv/u-boot.lds index e217f06..70ab702 100644 --- a/board/genietv/u-boot.lds +++ b/board/genietv/u-boot.lds @@ -18,11 +18,11 @@ SECTIONS
arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*) - lib/libgeneric.o (.text*) - net/libnet.o (.text*) - arch/powerpc/cpu/mpc8xx/libmpc8xx.o (.text*) - board/genietv/libgenietv.o (.text*) - arch/powerpc/lib/libpowerpc.o (.text*) + lib/built-in.o (.text*) + net/built-in.o (.text*) + arch/powerpc/cpu/mpc8xx/built-in.o (.text*) + board/genietv/built-in.o (.text*) + arch/powerpc/lib/built-in.o (.text*) *(.text.do_load_serial*) *(.text.do_mem_*) *(.text.do_bootm*) diff --git a/board/hermes/u-boot.lds b/board/hermes/u-boot.lds index 9419f83..0309860 100644 --- a/board/hermes/u-boot.lds +++ b/board/hermes/u-boot.lds @@ -17,7 +17,7 @@ SECTIONS /* the sector layout of our flash chips! XXX FIXME XXX */ arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*) - board/hermes/libhermes.o (.text*) + board/hermes/built-in.o (.text*)
. = env_offset; common/env_embedded.o (.text*) diff --git a/board/matrix_vision/mvsmr/u-boot.lds b/board/matrix_vision/mvsmr/u-boot.lds index 08ce014..e885b7c 100644 --- a/board/matrix_vision/mvsmr/u-boot.lds +++ b/board/matrix_vision/mvsmr/u-boot.lds @@ -18,7 +18,7 @@ SECTIONS /* the first two sectors (=8KB) of our S29GL flash chip */ arch/powerpc/cpu/mpc5xxx/start.o (.text*) arch/powerpc/cpu/mpc5xxx/traps.o (.text*) - board/matrix_vision/common/libmatrix_vision.o (.text*) + board/matrix_vision/common/built-in.o (.text*)
/* This is only needed to force failure if size of above code will ever */ /* increase and grow into reserved space. */ diff --git a/board/mvblue/u-boot.lds b/board/mvblue/u-boot.lds index 121354b..5034a96 100644 --- a/board/mvblue/u-boot.lds +++ b/board/mvblue/u-boot.lds @@ -14,12 +14,12 @@ SECTIONS .text : { arch/powerpc/cpu/mpc824x/start.o (.text*) - lib/libgeneric.o (.text*) - net/libnet.o (.text*) - drivers/pci/libpci.o (.text*) - arch/powerpc/cpu/mpc824x/libmpc824x.o (.text*) - board/mvblue/libmvblue.o (.text*) - arch/powerpc/lib/libpowerpc.o (.text*) + lib/built-in.o (.text*) + net/built-in.o (.text*) + drivers/pci/built-in.o (.text*) + arch/powerpc/cpu/mpc824x/built-in.o (.text*) + board/mvblue/built-in.o (.text*) + arch/powerpc/lib/built-in.o (.text*)
. = DEFINED(env_offset) ? env_offset : .; common/env_embedded.o (.ppcenv*) diff --git a/board/rbc823/u-boot.lds b/board/rbc823/u-boot.lds index 191f9eb..7676cf4 100644 --- a/board/rbc823/u-boot.lds +++ b/board/rbc823/u-boot.lds @@ -19,10 +19,10 @@ SECTIONS arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*)
- lib/libgeneric.o (.text*) - net/libnet.o (.text*) - arch/powerpc/cpu/mpc8xx/libmpc8xx.o (.text*) - arch/powerpc/lib/libpowerpc.o (.text*) + lib/built-in.o (.text*) + net/built-in.o (.text*) + arch/powerpc/cpu/mpc8xx/built-in.o (.text*) + arch/powerpc/lib/built-in.o (.text*)
. = env_offset; common/env_embedded.o (.text*) diff --git a/board/spd8xx/u-boot.lds b/board/spd8xx/u-boot.lds index 2a68934..463af7e 100644 --- a/board/spd8xx/u-boot.lds +++ b/board/spd8xx/u-boot.lds @@ -18,8 +18,8 @@ SECTIONS
arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*) - net/libnet.o (.text*) - arch/powerpc/cpu/mpc8xx/libmpc8xx.o (.text*) + net/built-in.o (.text*) + arch/powerpc/cpu/mpc8xx/built-in.o (.text*) *(.text.v*printf)
. = DEFINED(env_offset) ? env_offset : .; diff --git a/board/svm_sc8xx/u-boot.lds b/board/svm_sc8xx/u-boot.lds index 4922625..df564e9 100644 --- a/board/svm_sc8xx/u-boot.lds +++ b/board/svm_sc8xx/u-boot.lds @@ -17,11 +17,11 @@ SECTIONS /* the sector layout of our flash chips! XXX FIXME XXX */ arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*) - lib/libgeneric.o (.text*) - net/libnet.o (.text*) - arch/powerpc/cpu/mpc8xx/libmpc8xx.o (.text*) - arch/powerpc/lib/libpowerpc.o (.text*) - board/svm_sc8xx/libsvm_sc8xx.o (.text*) + lib/built-in.o (.text*) + net/built-in.o (.text*) + arch/powerpc/cpu/mpc8xx/built-in.o (.text*) + arch/powerpc/lib/built-in.o (.text*) + board/svm_sc8xx/built-in.o (.text*) *(.text.*printf) *(.text.do_mem_*) *(.text.flash*) diff --git a/board/ti/am335x/u-boot.lds b/board/ti/am335x/u-boot.lds index a173f62..e77a501 100644 --- a/board/ti/am335x/u-boot.lds +++ b/board/ti/am335x/u-boot.lds @@ -35,7 +35,7 @@ SECTIONS { *(.__image_copy_start) CPUDIR/start.o (.text*) - board/ti/am335x/libam335x.o (.text*) + board/ti/am335x/built-in.o (.text*) *(.text*) }
diff --git a/board/tqc/tqm8xx/u-boot.lds b/board/tqc/tqm8xx/u-boot.lds index cbfc94f..b77ae56 100644 --- a/board/tqc/tqm8xx/u-boot.lds +++ b/board/tqc/tqm8xx/u-boot.lds @@ -18,13 +18,13 @@ SECTIONS
arch/powerpc/cpu/mpc8xx/start.o (.text*) arch/powerpc/cpu/mpc8xx/traps.o (.text*) - arch/powerpc/cpu/mpc8xx/libmpc8xx.o (.text*) - arch/powerpc/lib/libpowerpc.o (.text*) - board/tqc/tqm8xx/libtqm8xx.o (.text*) - disk/libdisk.o (.text*) - drivers/net/libnet.o (.text*) - drivers/libdrivers.o (.text.pcmcia_on) - drivers/libdrivers.o (.text.pcmcia_hardware_enable) + arch/powerpc/cpu/mpc8xx/built-in.o (.text*) + arch/powerpc/lib/built-in.o (.text*) + board/tqc/tqm8xx/built-in.o (.text*) + disk/built-in.o (.text*) + drivers/net/built-in.o (.text*) + drivers/built-in.o (.text.pcmcia_on) + drivers/built-in.o (.text.pcmcia_hardware_enable)
. = DEFINED(env_offset) ? env_offset : .; common/env_embedded.o (.ppcenv*) diff --git a/board/vpac270/u-boot-spl.lds b/board/vpac270/u-boot-spl.lds index 7eac497..c9b50e9 100644 --- a/board/vpac270/u-boot-spl.lds +++ b/board/vpac270/u-boot-spl.lds @@ -20,8 +20,8 @@ SECTIONS .text.0 : { arch/arm/cpu/pxa/start.o (.text*) - board/vpac270/libvpac270.o (.text*) - drivers/mtd/onenand/libonenand.o (.text*) + board/vpac270/built-in.o (.text*) + drivers/mtd/onenand/built-in.o (.text*) }
diff --git a/include/configs/bct-brettl2.h b/include/configs/bct-brettl2.h index ce09c2e..5b09b45 100644 --- a/include/configs/bct-brettl2.h +++ b/include/configs/bct-brettl2.h @@ -111,8 +111,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/bf533-stamp.h b/include/configs/bf533-stamp.h index 7144c63..a22c868 100644 --- a/include/configs/bf533-stamp.h +++ b/include/configs/bf533-stamp.h @@ -155,8 +155,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/bf537-pnav.h b/include/configs/bf537-pnav.h index 62bd3bf..3aa3d50 100644 --- a/include/configs/bf537-pnav.h +++ b/include/configs/bf537-pnav.h @@ -111,8 +111,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/bf537-stamp.h b/include/configs/bf537-stamp.h index 25cebf8..02945be 100644 --- a/include/configs/bf537-stamp.h +++ b/include/configs/bf537-stamp.h @@ -118,8 +118,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/bf538f-ezkit.h b/include/configs/bf538f-ezkit.h index 77822e7..ffb0caf 100644 --- a/include/configs/bf538f-ezkit.h +++ b/include/configs/bf538f-ezkit.h @@ -115,8 +115,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/cm-bf537e.h b/include/configs/cm-bf537e.h index 77f47d9..8f10eba 100644 --- a/include/configs/cm-bf537e.h +++ b/include/configs/cm-bf537e.h @@ -112,8 +112,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/cm-bf537u.h b/include/configs/cm-bf537u.h index 55e61d6..a1c8e8a 100644 --- a/include/configs/cm-bf537u.h +++ b/include/configs/cm-bf537u.h @@ -110,8 +110,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/dnp5370.h b/include/configs/dnp5370.h index f2f4102..d0e72e3 100644 --- a/include/configs/dnp5370.h +++ b/include/configs/dnp5370.h @@ -85,8 +85,8 @@
#define ENV_IS_EMBEDDED #define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*);
diff --git a/include/configs/ibf-dsp561.h b/include/configs/ibf-dsp561.h index 5291755..ac5ca9a 100644 --- a/include/configs/ibf-dsp561.h +++ b/include/configs/ibf-dsp561.h @@ -95,8 +95,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/include/configs/tcm-bf537.h b/include/configs/tcm-bf537.h index 2adb071..627836a 100644 --- a/include/configs/tcm-bf537.h +++ b/include/configs/tcm-bf537.h @@ -112,8 +112,8 @@ * it linked after the configuration sector. */ # define LDS_BOARD_TEXT \ - arch/blackfin/lib/libblackfin.o (.text*); \ - arch/blackfin/cpu/libblackfin.o (.text*); \ + arch/blackfin/lib/built-in.o (.text*); \ + arch/blackfin/cpu/built-in.o (.text*); \ . = DEFINED(env_offset) ? env_offset : .; \ common/env_embedded.o (.text*); #endif diff --git a/spl/Makefile b/spl/Makefile index 0ac0c3c..29354f9 100644 --- a/spl/Makefile +++ b/spl/Makefile @@ -54,52 +54,54 @@ ifeq ($(CPU),mpc85xx) START += $(START_PATH)/resetvec.o endif
-LIBS-y += arch/$(ARCH)/lib/lib$(ARCH).o +LIBS-y += arch/$(ARCH)/lib/
-LIBS-y += $(CPUDIR)/lib$(CPU).o +LIBS-y += $(CPUDIR)/
ifdef SOC -LIBS-y += $(CPUDIR)/$(SOC)/lib$(SOC).o -endif -LIBS-y += board/$(BOARDDIR)/lib$(BOARD).o -LIBS-$(HAVE_VENDOR_COMMON_LIB) += board/$(VENDOR)/common/lib$(VENDOR).o - -LIBS-$(CONFIG_SPL_FRAMEWORK) += common/spl/libspl.o -LIBS-$(CONFIG_SPL_LIBCOMMON_SUPPORT) += common/libcommon.o -LIBS-$(CONFIG_SPL_LIBDISK_SUPPORT) += disk/libdisk.o -LIBS-$(CONFIG_SPL_I2C_SUPPORT) += drivers/i2c/libi2c.o -LIBS-$(CONFIG_SPL_GPIO_SUPPORT) += drivers/gpio/libgpio.o -LIBS-$(CONFIG_SPL_MMC_SUPPORT) += drivers/mmc/libmmc.o -LIBS-$(CONFIG_SPL_SERIAL_SUPPORT) += drivers/serial/libserial.o -LIBS-$(CONFIG_SPL_SPI_FLASH_SUPPORT) += drivers/mtd/spi/libspi_flash.o -LIBS-$(CONFIG_SPL_SPI_SUPPORT) += drivers/spi/libspi.o -LIBS-$(CONFIG_SPL_FAT_SUPPORT) += fs/fat/libfat.o -LIBS-$(CONFIG_SPL_LIBGENERIC_SUPPORT) += lib/libgeneric.o -LIBS-$(CONFIG_SPL_POWER_SUPPORT) += drivers/power/libpower.o \ - drivers/power/pmic/libpmic.o -LIBS-$(CONFIG_SPL_NAND_SUPPORT) += drivers/mtd/nand/libnand.o -LIBS-$(CONFIG_SPL_ONENAND_SUPPORT) += drivers/mtd/onenand/libonenand.o -LIBS-$(CONFIG_SPL_DMA_SUPPORT) += drivers/dma/libdma.o -LIBS-$(CONFIG_SPL_POST_MEM_SUPPORT) += post/drivers/memory.o -LIBS-$(CONFIG_SPL_NET_SUPPORT) += net/libnet.o -LIBS-$(CONFIG_SPL_ETH_SUPPORT) += drivers/net/libnet.o -LIBS-$(CONFIG_SPL_ETH_SUPPORT) += drivers/net/phy/libphy.o -LIBS-$(CONFIG_SPL_USBETH_SUPPORT) += drivers/net/phy/libphy.o -LIBS-$(CONFIG_SPL_MUSB_NEW_SUPPORT) += drivers/usb/musb-new/libusb_musb-new.o -LIBS-$(CONFIG_SPL_USBETH_SUPPORT) += drivers/usb/gadget/libusb_gadget.o -LIBS-$(CONFIG_SPL_WATCHDOG_SUPPORT) += drivers/watchdog/libwatchdog.o +LIBS-y += $(CPUDIR)/$(SOC)/ +endif +LIBS-y += board/$(BOARDDIR)/ +LIBS-$(HAVE_VENDOR_COMMON_LIB) += board/$(VENDOR)/common/ + +LIBS-$(CONFIG_SPL_FRAMEWORK) += common/spl/ +LIBS-$(CONFIG_SPL_LIBCOMMON_SUPPORT) += common/ +LIBS-$(CONFIG_SPL_LIBDISK_SUPPORT) += disk/ +LIBS-$(CONFIG_SPL_I2C_SUPPORT) += drivers/i2c/ +LIBS-$(CONFIG_SPL_GPIO_SUPPORT) += drivers/gpio/ +LIBS-$(CONFIG_SPL_MMC_SUPPORT) += drivers/mmc/ +LIBS-$(CONFIG_SPL_SERIAL_SUPPORT) += drivers/serial/ +LIBS-$(CONFIG_SPL_SPI_FLASH_SUPPORT) += drivers/mtd/spi/ +LIBS-$(CONFIG_SPL_SPI_SUPPORT) += drivers/spi/ +LIBS-$(CONFIG_SPL_FAT_SUPPORT) += fs/fat/ +LIBS-$(CONFIG_SPL_LIBGENERIC_SUPPORT) += lib/ +LIBS-$(CONFIG_SPL_POWER_SUPPORT) += drivers/power/ \ + drivers/power/pmic/ +LIBS-$(CONFIG_SPL_NAND_SUPPORT) += drivers/mtd/nand/ +LIBS-$(CONFIG_SPL_ONENAND_SUPPORT) += drivers/mtd/onenand/ +LIBS-$(CONFIG_SPL_DMA_SUPPORT) += drivers/dma/ +LIBS-$(CONFIG_SPL_POST_MEM_SUPPORT) += post/drivers/ +LIBS-$(CONFIG_SPL_NET_SUPPORT) += net/ +LIBS-$(CONFIG_SPL_ETH_SUPPORT) += drivers/net/ +LIBS-$(CONFIG_SPL_ETH_SUPPORT) += drivers/net/phy/ +LIBS-$(CONFIG_SPL_USBETH_SUPPORT) += drivers/net/phy/ +LIBS-$(CONFIG_SPL_MUSB_NEW_SUPPORT) += drivers/usb/musb-new/ +LIBS-$(CONFIG_SPL_USBETH_SUPPORT) += drivers/usb/gadget/ +LIBS-$(CONFIG_SPL_WATCHDOG_SUPPORT) += drivers/watchdog/
ifneq (,$(CONFIG_MX23)$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) -LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o +LIBS-y += arch/$(ARCH)/imx-common/ endif
-LIBS-$(CONFIG_ARM) += arch/arm/cpu/libcpu.o -LIBS-$(CONFIG_PPC) += arch/powerpc/cpu/libcpu.o +LIBS-$(CONFIG_ARM) += arch/arm/cpu/ +LIBS-$(CONFIG_PPC) += arch/powerpc/cpu/
ifneq ($(CONFIG_MX23)$(CONFIG_MX35),) -LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o +LIBS-y += arch/$(ARCH)/imx-common/ endif
+LIBS-y := $(patsubst %/, %/built-in.o, $(LIBS-y)) + # Add GCC lib ifeq ("$(USE_PRIVATE_LIBGCC)", "yes") PLATFORM_LIBGCC = $(SPLTREE)/arch/$(ARCH)/lib/libgcc.o @@ -184,7 +186,6 @@ $(START):
$(LIBS): depend $(MAKE) $(build) $(SRCTREE)$(dir $(subst $(SPLTREE),,$@)) - mv $(dir $@)built-in.o $@
$(obj)u-boot-spl.lds: $(LDSCRIPT) depend $(CPP) $(CPPFLAGS) $(LDPPFLAGS) -I$(obj). -ansi -D__ASSEMBLY__ -P - < $< > $@

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 4 +--- spl/Makefile | 3 +-- 2 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/Makefile b/Makefile index 1389ee7..e28878b 100644 --- a/Makefile +++ b/Makefile @@ -65,11 +65,9 @@ endif # the object files are placed in the source directory. #
-ifdef O ifeq ("$(origin O)", "command line") BUILD_DIR := $(O) endif -endif
# Call a source code checker (by default, "sparse") as part of the # C compilation. @@ -614,7 +612,7 @@ SYSTEM_MAP = \ grep -v '(compiled)|(.o$$)|( [aUw] )|(..ng$$)|(LASH[RL]DI)' | \ LC_ALL=C sort $(obj)System.map: $(obj)u-boot - @$(call SYSTEM_MAP,$<) > $(obj)System.map + @$(call SYSTEM_MAP,$<) > $@
checkthumb: @if test $(call cc-version) -lt 0404; then \ diff --git a/spl/Makefile b/spl/Makefile index 29354f9..5bc75b4 100644 --- a/spl/Makefile +++ b/spl/Makefile @@ -166,8 +166,7 @@ all: $(ALL-y)
ifdef CONFIG_SAMSUNG $(obj)$(BOARD)-spl.bin: $(obj)u-boot-spl.bin - $(OBJTREE)/tools/mk$(BOARD)spl \ - $(obj)u-boot-spl.bin $(obj)$(BOARD)-spl.bin + $(OBJTREE)/tools/mk$(BOARD)spl $< $@ endif
$(obj)$(SPL_BIN).bin: $(obj)$(SPL_BIN)

SPL_BIN is already defined in spl/Makefile and it is used only in spl/Makefile.
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- config.mk | 6 ------ 1 file changed, 6 deletions(-)
diff --git a/config.mk b/config.mk index 8a82ab4..7c5c82d 100644 --- a/config.mk +++ b/config.mk @@ -13,12 +13,6 @@ SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
export SHELL
-ifeq ($(CONFIG_TPL_BUILD),y) -SPL_BIN := u-boot-tpl -else -SPL_BIN := u-boot-spl -endif - ifeq ($(CURDIR),$(SRCTREE)) dir := else

HOSTOS is defined and exported at the top Makefile.
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- tools/gdb/Makefile | 2 -- 1 file changed, 2 deletions(-)
diff --git a/tools/gdb/Makefile b/tools/gdb/Makefile index dee91fc..dd98fb6 100644 --- a/tools/gdb/Makefile +++ b/tools/gdb/Makefile @@ -23,8 +23,6 @@ BINS := $(addprefix $(obj),$(BINS)) # HOSTCPPFLAGS = -I$(BFD_ROOT_DIR)/include
-HOSTOS := $(shell uname -s | sed -e 's/([Cc][Yy][Gg][Ww][Ii][Nn]).*/cygwin/') - ifeq ($(HOSTOS),cygwin)
all:

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 6 ------ 1 file changed, 6 deletions(-)
diff --git a/Makefile b/Makefile index e28878b..5ad2bd7 100644 --- a/Makefile +++ b/Makefile @@ -784,12 +784,6 @@ sinclude $(obj).boards.depend $(obj).boards.depend: boards.cfg @awk '(NF && $$1 !~ /^#/) { print $$7 ": " $$7 "_config; $$(MAKE)" }' $< > $@
-# -# Functions to generate common board directory names -# -lcname = $(shell echo $(1) | sed -e 's/(.*)_config/\L\1/') -ucname = $(shell echo $(1) | sed -e 's/(.*)_config/\U\1/') - ######################################################################### #########################################################################

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- arch/powerpc/cpu/mpc83xx/Makefile | 6 ------ 1 file changed, 6 deletions(-)
diff --git a/arch/powerpc/cpu/mpc83xx/Makefile b/arch/powerpc/cpu/mpc83xx/Makefile index b7142f0..a501a3b 100644 --- a/arch/powerpc/cpu/mpc83xx/Makefile +++ b/arch/powerpc/cpu/mpc83xx/Makefile @@ -48,11 +48,5 @@ obj-$(CONFIG_FSL_DDR2) += law.o
endif # not minimal
-$(obj)ddr-gen1.c: - ln -sf $(SRCTREE)/arch/powerpc/cpu/mpc85xx/ddr-gen1.c $(obj)ddr-gen1.c - $(obj)ddr-gen2.c: ln -sf $(SRCTREE)/arch/powerpc/cpu/mpc85xx/ddr-gen2.c $(obj)ddr-gen2.c - -$(obj)ddr-gen3.c: - ln -sf $(SRCTREE)/arch/powerpc/cpu/mpc85xx/ddr-gen3.c $(obj)ddr-gen3.c

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 1 - arch/powerpc/cpu/mpc83xx/Makefile | 6 +----- 2 files changed, 1 insertion(+), 6 deletions(-)
diff --git a/Makefile b/Makefile index 5ad2bd7..4f5a1ac 100644 --- a/Makefile +++ b/Makefile @@ -861,7 +861,6 @@ clobber: tidy @rm -f $(obj)SPL @rm -f $(obj)tools/xway-swap-bytes @rm -f $(obj)arch/powerpc/cpu/mpc824x/bedbug_603e.c - @rm -f $(obj)arch/powerpc/cpu/mpc83xx/ddr-gen?.c @rm -fr $(obj)include/asm/proc $(obj)include/asm/arch $(obj)include/asm @rm -fr $(obj)include/generated @[ ! -d $(obj)nand_spl ] || find $(obj)nand_spl -name "*" -type l -print | xargs rm -f diff --git a/arch/powerpc/cpu/mpc83xx/Makefile b/arch/powerpc/cpu/mpc83xx/Makefile index a501a3b..d3f7001 100644 --- a/arch/powerpc/cpu/mpc83xx/Makefile +++ b/arch/powerpc/cpu/mpc83xx/Makefile @@ -39,14 +39,10 @@ obj-$(CONFIG_OF_LIBFDT) += fdt.o obj-y += cache.o
ifdef CONFIG_FSL_DDR2 -obj-$(CONFIG_MPC8349) += ddr-gen2.o -SRCS += $(obj)ddr-gen2.c +obj-$(CONFIG_MPC8349) += ../mpc85xx/ddr-gen2.o else obj-y += spd_sdram.o endif obj-$(CONFIG_FSL_DDR2) += law.o
endif # not minimal - -$(obj)ddr-gen2.c: - ln -sf $(SRCTREE)/arch/powerpc/cpu/mpc85xx/ddr-gen2.c $(obj)ddr-gen2.c

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- Makefile | 1 - arch/powerpc/cpu/mpc824x/.gitignore | 1 - arch/powerpc/cpu/mpc824x/Makefile | 6 +----- 3 files changed, 1 insertion(+), 7 deletions(-) delete mode 100644 arch/powerpc/cpu/mpc824x/.gitignore
diff --git a/Makefile b/Makefile index 4f5a1ac..c04917f 100644 --- a/Makefile +++ b/Makefile @@ -860,7 +860,6 @@ clobber: tidy @rm -f $(obj)MLO MLO.byteswap @rm -f $(obj)SPL @rm -f $(obj)tools/xway-swap-bytes - @rm -f $(obj)arch/powerpc/cpu/mpc824x/bedbug_603e.c @rm -fr $(obj)include/asm/proc $(obj)include/asm/arch $(obj)include/asm @rm -fr $(obj)include/generated @[ ! -d $(obj)nand_spl ] || find $(obj)nand_spl -name "*" -type l -print | xargs rm -f diff --git a/arch/powerpc/cpu/mpc824x/.gitignore b/arch/powerpc/cpu/mpc824x/.gitignore deleted file mode 100644 index 2d79931..0000000 --- a/arch/powerpc/cpu/mpc824x/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/bedbug_603e.c diff --git a/arch/powerpc/cpu/mpc824x/Makefile b/arch/powerpc/cpu/mpc824x/Makefile index 194fadd..2c8be92 100644 --- a/arch/powerpc/cpu/mpc824x/Makefile +++ b/arch/powerpc/cpu/mpc824x/Makefile @@ -8,8 +8,4 @@ extra-y = start.o obj-y = traps.o cpu.o cpu_init.o interrupts.o speed.o \ drivers/epic/epic1.o drivers/i2c/i2c.o pci.o -obj-y += bedbug_603e.o - -SRCS += $(obj)bedbug_603e.c -$(obj)bedbug_603e.c: - ln -sf $(src)../mpc8260/bedbug_603e.c $(obj)bedbug_603e.c +obj-y += ../mpc8260/bedbug_603e.o

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com Cc: Nobuhiro Iwamatsu nobuhiro.iwamatsu.yj@renesas.com --- arch/arm/cpu/armv7/rmobile/Makefile | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/arch/arm/cpu/armv7/rmobile/Makefile b/arch/arm/cpu/armv7/rmobile/Makefile index 8f4cf3a..5e296c4 100644 --- a/arch/arm/cpu/armv7/rmobile/Makefile +++ b/arch/arm/cpu/armv7/rmobile/Makefile @@ -15,10 +15,4 @@ obj-$(CONFIG_R8A7740) += cpu_info-r8a7740.o obj-$(CONFIG_R8A7740) += pfc-r8a7740.o obj-$(CONFIG_SH73A0) += cpu_info-sh73a0.o obj-$(CONFIG_SH73A0) += pfc-sh73a0.o -obj-$(CONFIG_TMU_TIMER) += sh_timer.o - -SRCS += $(obj)sh_timer.c -# from arch/sh/lib/ directory -$(obj)sh_timer.c: - @rm -f $(obj)sh_timer.c - ln -s $(SRCTREE)/arch/sh/lib/time.c $(obj)sh_timer.c +obj-$(CONFIG_TMU_TIMER) += ../../../../sh/lib/time.o

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com Cc: Simon Glass sjg@chromium.org --- Makefile | 3 +-- fs/Makefile | 5 +++++ spl/Makefile | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/Makefile b/Makefile index c04917f..b8713a4 100644 --- a/Makefile +++ b/Makefile @@ -243,8 +243,7 @@ endif LIBS-$(CONFIG_IXP4XX_NPE) += drivers/net/npe/ LIBS-$(CONFIG_OF_EMBED) += dts/ LIBS-y += arch/$(ARCH)/lib/ -LIBS-y += fs/ \ - fs/fat/ +LIBS-y += fs/ LIBS-y += net/ LIBS-y += disk/ LIBS-y += drivers/ diff --git a/fs/Makefile b/fs/Makefile index bdcd746..ee01a7d 100644 --- a/fs/Makefile +++ b/fs/Makefile @@ -6,11 +6,15 @@ # SPDX-License-Identifier: GPL-2.0+ #
+ifdef CONFIG_SPL_BUILD +obj-$(CONFIG_SPL_FAT_SUPPORT) += fat/ +else obj-y += fs.o
obj-y += cbfs/ obj-y += cramfs/ obj-y += ext4/ +obj-y += fat/ obj-y += fdos/ obj-y += jffs2/ obj-y += reiserfs/ @@ -18,3 +22,4 @@ obj-y += sandbox/ obj-y += ubifs/ obj-y += yaffs2/ obj-y += zfs/ +endif diff --git a/spl/Makefile b/spl/Makefile index 5bc75b4..29d7818 100644 --- a/spl/Makefile +++ b/spl/Makefile @@ -73,7 +73,7 @@ LIBS-$(CONFIG_SPL_MMC_SUPPORT) += drivers/mmc/ LIBS-$(CONFIG_SPL_SERIAL_SUPPORT) += drivers/serial/ LIBS-$(CONFIG_SPL_SPI_FLASH_SUPPORT) += drivers/mtd/spi/ LIBS-$(CONFIG_SPL_SPI_SUPPORT) += drivers/spi/ -LIBS-$(CONFIG_SPL_FAT_SUPPORT) += fs/fat/ +LIBS-y += fs/ LIBS-$(CONFIG_SPL_LIBGENERIC_SUPPORT) += lib/ LIBS-$(CONFIG_SPL_POWER_SUPPORT) += drivers/power/ \ drivers/power/pmic/

On Sun, Nov 10, 2013 at 10:36 PM, Masahiro Yamada yamada.m@jp.panasonic.com wrote:
Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com Cc: Simon Glass sjg@chromium.org
Acked-by: Simon Glass sjg@chromium.org
Makefile | 3 +-- fs/Makefile | 5 +++++ spl/Makefile | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/Makefile b/Makefile index c04917f..b8713a4 100644 --- a/Makefile +++ b/Makefile @@ -243,8 +243,7 @@ endif LIBS-$(CONFIG_IXP4XX_NPE) += drivers/net/npe/ LIBS-$(CONFIG_OF_EMBED) += dts/ LIBS-y += arch/$(ARCH)/lib/ -LIBS-y += fs/ \
fs/fat/
+LIBS-y += fs/ LIBS-y += net/ LIBS-y += disk/ LIBS-y += drivers/ diff --git a/fs/Makefile b/fs/Makefile index bdcd746..ee01a7d 100644 --- a/fs/Makefile +++ b/fs/Makefile @@ -6,11 +6,15 @@ # SPDX-License-Identifier: GPL-2.0+ #
+ifdef CONFIG_SPL_BUILD +obj-$(CONFIG_SPL_FAT_SUPPORT) += fat/ +else obj-y += fs.o
obj-y += cbfs/ obj-y += cramfs/ obj-y += ext4/ +obj-y += fat/ obj-y += fdos/ obj-y += jffs2/ obj-y += reiserfs/ @@ -18,3 +22,4 @@ obj-y += sandbox/ obj-y += ubifs/ obj-y += yaffs2/ obj-y += zfs/ +endif diff --git a/spl/Makefile b/spl/Makefile index 5bc75b4..29d7818 100644 --- a/spl/Makefile +++ b/spl/Makefile @@ -73,7 +73,7 @@ LIBS-$(CONFIG_SPL_MMC_SUPPORT) += drivers/mmc/ LIBS-$(CONFIG_SPL_SERIAL_SUPPORT) += drivers/serial/ LIBS-$(CONFIG_SPL_SPI_FLASH_SUPPORT) += drivers/mtd/spi/ LIBS-$(CONFIG_SPL_SPI_SUPPORT) += drivers/spi/ -LIBS-$(CONFIG_SPL_FAT_SUPPORT) += fs/fat/ +LIBS-y += fs/ LIBS-$(CONFIG_SPL_LIBGENERIC_SUPPORT) += lib/ LIBS-$(CONFIG_SPL_POWER_SUPPORT) += drivers/power/ \ drivers/power/pmic/ -- 1.8.3.2

Signed-off-by: Masahiro Yamada yamada.m@jp.panasonic.com --- fs/Makefile | 20 ++++++++++---------- fs/cbfs/Makefile | 2 +- fs/cramfs/Makefile | 4 ++-- fs/ext4/Makefile | 2 +- fs/fdos/Makefile | 2 +- fs/jffs2/Makefile | 2 -- fs/reiserfs/Makefile | 2 +- fs/sandbox/Makefile | 2 +- fs/ubifs/Makefile | 8 ++++---- fs/yaffs2/Makefile | 2 +- fs/zfs/Makefile | 2 +- 11 files changed, 23 insertions(+), 25 deletions(-)
diff --git a/fs/Makefile b/fs/Makefile index ee01a7d..34dc035 100644 --- a/fs/Makefile +++ b/fs/Makefile @@ -11,15 +11,15 @@ obj-$(CONFIG_SPL_FAT_SUPPORT) += fat/ else obj-y += fs.o
-obj-y += cbfs/ -obj-y += cramfs/ -obj-y += ext4/ +obj-$(CONFIG_CMD_CBFS) += cbfs/ +obj-$(CONFIG_CMD_CRAMFS) += cramfs/ +obj-$(CONFIG_FS_EXT4) += ext4/ obj-y += fat/ -obj-y += fdos/ -obj-y += jffs2/ -obj-y += reiserfs/ -obj-y += sandbox/ -obj-y += ubifs/ -obj-y += yaffs2/ -obj-y += zfs/ +obj-$(CONFIG_CMD_FDOS) += fdos/ +obj-$(CONFIG_CMD_JFFS2) += jffs2/ +obj-$(CONFIG_CMD_REISER) += reiserfs/ +obj-$(CONFIG_SANDBOX) += sandbox/ +obj-$(CONFIG_CMD_UBIFS) += ubifs/ +obj-$(CONFIG_YAFFS2) += yaffs2/ +obj-$(CONFIG_CMD_ZFS) += zfs/ endif diff --git a/fs/cbfs/Makefile b/fs/cbfs/Makefile index 6f33d28..a106e05 100644 --- a/fs/cbfs/Makefile +++ b/fs/cbfs/Makefile @@ -3,4 +3,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_CMD_CBFS) := cbfs.o +obj-y := cbfs.o diff --git a/fs/cramfs/Makefile b/fs/cramfs/Makefile index e2b2c73..12d73a3 100644 --- a/fs/cramfs/Makefile +++ b/fs/cramfs/Makefile @@ -5,5 +5,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_CMD_CRAMFS) := cramfs.o -obj-$(CONFIG_CMD_CRAMFS) += uncompress.o +obj-y := cramfs.o +obj-y += uncompress.o diff --git a/fs/ext4/Makefile b/fs/ext4/Makefile index 0f5d399..8d15bda 100644 --- a/fs/ext4/Makefile +++ b/fs/ext4/Makefile @@ -9,5 +9,5 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_FS_EXT4) := ext4fs.o ext4_common.o dev.o +obj-y := ext4fs.o ext4_common.o dev.o obj-$(CONFIG_EXT4_WRITE) += ext4_write.o ext4_journal.o crc16.o diff --git a/fs/fdos/Makefile b/fs/fdos/Makefile index 95480af..2f8b5ad 100644 --- a/fs/fdos/Makefile +++ b/fs/fdos/Makefile @@ -10,4 +10,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_CMD_FDOS) := fat.o vfat.o dev.o fdos.o fs.o subdir.o +obj-y := fat.o vfat.o dev.o fdos.o fs.o subdir.o diff --git a/fs/jffs2/Makefile b/fs/jffs2/Makefile index 02e481f..4cb0600 100644 --- a/fs/jffs2/Makefile +++ b/fs/jffs2/Makefile @@ -5,11 +5,9 @@ # SPDX-License-Identifier: GPL-2.0+ #
-ifdef CONFIG_CMD_JFFS2 obj-$(CONFIG_JFFS2_LZO) += compr_lzo.o obj-y += compr_rtime.o obj-y += compr_rubin.o obj-y += compr_zlib.o obj-y += jffs2_1pass.o obj-y += mini_inflate.o -endif diff --git a/fs/reiserfs/Makefile b/fs/reiserfs/Makefile index 55f70b1..5a692f0 100644 --- a/fs/reiserfs/Makefile +++ b/fs/reiserfs/Makefile @@ -9,4 +9,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_CMD_REISER) := reiserfs.o dev.o mode_string.o +obj-y := reiserfs.o dev.o mode_string.o diff --git a/fs/sandbox/Makefile b/fs/sandbox/Makefile index faa7c16..ca238f6 100644 --- a/fs/sandbox/Makefile +++ b/fs/sandbox/Makefile @@ -10,4 +10,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_SANDBOX) := sandboxfs.o +obj-y := sandboxfs.o diff --git a/fs/ubifs/Makefile b/fs/ubifs/Makefile index 47d5a8f..389b0e3 100644 --- a/fs/ubifs/Makefile +++ b/fs/ubifs/Makefile @@ -9,10 +9,10 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_CMD_UBIFS) := ubifs.o io.o super.o sb.o master.o lpt.o -obj-$(CONFIG_CMD_UBIFS) += lpt_commit.o scan.o lprops.o -obj-$(CONFIG_CMD_UBIFS) += tnc.o tnc_misc.o debug.o crc16.o budget.o -obj-$(CONFIG_CMD_UBIFS) += log.o orphan.o recovery.o replay.o +obj-y := ubifs.o io.o super.o sb.o master.o lpt.o +obj-y += lpt_commit.o scan.o lprops.o +obj-y += tnc.o tnc_misc.o debug.o crc16.o budget.o +obj-y += log.o orphan.o recovery.o replay.o
# SEE README.arm-unaligned-accesses $(obj)super.o: CFLAGS += $(PLATFORM_NO_UNALIGNED) diff --git a/fs/yaffs2/Makefile b/fs/yaffs2/Makefile index 077af78..d811287 100644 --- a/fs/yaffs2/Makefile +++ b/fs/yaffs2/Makefile @@ -16,7 +16,7 @@ # # $Id: Makefile,v 1.15 2007/07/18 19:40:38 charles Exp $
-obj-$(CONFIG_YAFFS2) := \ +obj-y := \ yaffs_allocator.o yaffs_attribs.o yaffs_bitmap.o yaffs_uboot_glue.o\ yaffs_checkptrw.o yaffs_ecc.o yaffs_error.o \ yaffsfs.o yaffs_guts.o yaffs_nameval.o yaffs_nand.o\ diff --git a/fs/zfs/Makefile b/fs/zfs/Makefile index 7090416..fa58b7f 100644 --- a/fs/zfs/Makefile +++ b/fs/zfs/Makefile @@ -5,4 +5,4 @@ # SPDX-License-Identifier: GPL-2.0+ #
-obj-$(CONFIG_CMD_ZFS) := dev.o zfs.o zfs_fletcher.o zfs_sha256.o zfs_lzjb.o +obj-y := dev.o zfs.o zfs_fletcher.o zfs_sha256.o zfs_lzjb.o

On Mon, Nov 11, 2013 at 02:35:48PM +0900, Masahiro Yamada wrote:
This series does not add any new features but refactor makefiles.
Masahiro Yamada (22): Makefile: abolish COBJS, SOBJS, etc. Makefile: specifiy an explicite object name rather than $(BOARD).o drivers: descend into sub directories only when it is necessary lib: descend into sub directories only when it is necessary drivers: tpm: clean up unused code Makefile: make directories by Makefile.build Makefile: merge $(LIBBOARD) into $(LIBS) powerpc: move mpc8xxx entry under arch/powerpc/cpu/ drivers/qe: move the entry to drivers/Makefile drivers/net/fm: descend only when CONFIG_FMAN_ENET=y drivers/net/npe: descend only when CONFIG_IXP4XX_NPE=y Makefile: rename all libraries to built-in.o Makefile: refactor a little config.mk: delete unnecessary lines tools: Makefile: delete redundant lines Makefile: delete unused lines powerpc: mpc83xx: delete unused rules powerpc: mpc83xx: Do not create a symbolic link to ddr-gen2.c powerpc: mpc824x: Do not create a symbolic link to bedbug_603e.c arm: rmobile: Do not create a symbolic link to sh timer Makefile: move fs/fat/ entry to drivers/Makefile fs: descend into sub directories when it is necessary
Makefile | 149 +++++++++-------------- arch/arm/cpu/armv7/rmobile/Makefile | 8 +- arch/microblaze/cpu/u-boot.lds | 2 +- arch/powerpc/cpu/Makefile | 3 + arch/powerpc/cpu/mpc512x/Makefile | 2 - arch/powerpc/cpu/mpc824x/.gitignore | 1 - arch/powerpc/cpu/mpc824x/Makefile | 10 +- arch/powerpc/cpu/mpc83xx/Makefile | 12 +- arch/powerpc/cpu/mpc8xxx/Makefile | 6 + board/LEOX/elpt860/u-boot.lds | 8 +- board/LaCie/edminiv2/Makefile | 4 - board/LaCie/net2big_v2/Makefile | 4 - board/LaCie/netspace_v2/Makefile | 4 - board/LaCie/wireless_space/Makefile | 4 - board/Marvell/db64360/Makefile | 4 - board/Marvell/db64460/Makefile | 4 - board/actux1/u-boot.lds | 8 +- board/actux2/u-boot.lds | 8 +- board/actux3/u-boot.lds | 8 +- board/altera/nios2-generic/Makefile | 4 - board/avionic-design/medcom-wide/Makefile | 2 - board/avionic-design/plutux/Makefile | 2 - board/avionic-design/tec/Makefile | 2 - board/compal/paz00/Makefile | 2 - board/compulab/trimslice/Makefile | 2 - board/davinci/da8xxevm/u-boot-spl-hawk.lds | 4 +- board/dvlhost/u-boot.lds | 8 +- board/emk/top5200/Makefile | 4 - board/emk/top860/Makefile | 3 - board/esd/adciop/Makefile | 4 - board/esd/apc405/Makefile | 4 - board/esd/ar405/Makefile | 4 - board/esd/ash405/Makefile | 4 - board/esd/cms700/Makefile | 4 - board/esd/cpci2dp/Makefile | 4 - board/esd/cpci405/Makefile | 4 - board/esd/cpci5200/Makefile | 4 - board/esd/cpci750/Makefile | 4 - board/esd/cpciiser4/Makefile | 4 - board/esd/dasa_sim/Makefile | 4 - board/esd/dp405/Makefile | 4 - board/esd/du405/Makefile | 4 - board/esd/hh405/Makefile | 4 - board/esd/hub405/Makefile | 4 - board/esd/ocrtc/Makefile | 4 - board/esd/pci405/Makefile | 4 - board/esd/pf5200/Makefile | 4 - board/esd/plu405/Makefile | 4 - board/esd/pmc405/Makefile | 4 - board/esd/pmc405de/Makefile | 4 - board/esd/pmc440/Makefile | 4 - board/esd/voh405/Makefile | 4 - board/esd/vom405/Makefile | 4 - board/esd/wuh405/Makefile | 4 - board/esteem192e/u-boot.lds | 4 +- board/freescale/m52277evb/u-boot.lds | 4 +- board/freescale/m53017evb/u-boot.lds | 6 +- board/freescale/mx31ads/u-boot.lds | 10 +- board/freescale/t1040qds/Makefile | 2 +- board/genietv/u-boot.lds | 10 +- board/hermes/u-boot.lds | 2 +- board/keymile/km82xx/Makefile | 3 - board/keymile/km83xx/Makefile | 4 - board/keymile/km_arm/Makefile | 4 - board/keymile/kmp204x/Makefile | 6 +- board/kup/kup4k/Makefile | 4 - board/kup/kup4x/Makefile | 4 - board/matrix_vision/mvsmr/u-boot.lds | 2 +- board/mpl/mip405/Makefile | 4 - board/mpl/pati/Makefile | 4 - board/mpl/pip405/Makefile | 4 - board/mpl/vcma9/Makefile | 4 - board/mvblue/u-boot.lds | 12 +- board/nvidia/beaver/Makefile | 2 - board/nvidia/ventana/Makefile | 2 - board/prodrive/p3mx/Makefile | 4 - board/psyent/pci5441/Makefile | 4 - board/psyent/pk1c20/Makefile | 4 - board/rbc823/u-boot.lds | 8 +- board/sandburst/karef/Makefile | 4 - board/sandburst/metrobox/Makefile | 4 - board/siemens/dxr2/Makefile | 4 - board/siemens/pxm2/Makefile | 4 - board/siemens/rut/Makefile | 4 - board/spd8xx/u-boot.lds | 4 +- board/svm_sc8xx/u-boot.lds | 10 +- board/ti/am335x/u-boot.lds | 2 +- board/ti/beagle/Makefile | 2 +- board/toradex/colibri_t20_iris/Makefile | 3 - board/tqc/tqm8260/Makefile | 4 - board/tqc/tqm8272/Makefile | 4 - board/tqc/tqm8xx/u-boot.lds | 14 +-- board/vpac270/u-boot-spl.lds | 4 +- board/xilinx/ppc405-generic/Makefile | 4 - board/xilinx/ppc440-generic/Makefile | 4 - config.mk | 6 - drivers/Makefile | 5 +- drivers/bios_emulator/Makefile | 4 +- drivers/fpga/Makefile | 2 - drivers/net/fm/Makefile | 2 - drivers/net/npe/Makefile | 2 +- drivers/qe/Makefile | 4 +- drivers/tpm/Makefile | 2 - drivers/tpm/tis_i2c.c | 185 ----------------------------- fs/Makefile | 25 ++-- fs/cbfs/Makefile | 2 +- fs/cramfs/Makefile | 4 +- fs/ext4/Makefile | 2 +- fs/fdos/Makefile | 2 +- fs/jffs2/Makefile | 2 - fs/reiserfs/Makefile | 2 +- fs/sandbox/Makefile | 2 +- fs/ubifs/Makefile | 8 +- fs/yaffs2/Makefile | 2 +- fs/zfs/Makefile | 2 +- include/configs/bct-brettl2.h | 4 +- include/configs/bf533-stamp.h | 4 +- include/configs/bf537-pnav.h | 4 +- include/configs/bf537-stamp.h | 4 +- include/configs/bf538f-ezkit.h | 4 +- include/configs/cm-bf537e.h | 4 +- include/configs/cm-bf537u.h | 4 +- include/configs/dnp5370.h | 4 +- include/configs/ibf-dsp561.h | 4 +- include/configs/tcm-bf537.h | 4 +- lib/lzma/Makefile | 2 +- lib/lzo/Makefile | 2 +- lib/rsa/Makefile | 4 +- lib/zlib/Makefile | 2 +- scripts/Makefile.build | 19 +-- spl/Makefile | 87 ++++++-------- tools/gdb/Makefile | 2 - 132 files changed, 251 insertions(+), 746 deletions(-) create mode 100644 arch/powerpc/cpu/Makefile delete mode 100644 arch/powerpc/cpu/mpc824x/.gitignore delete mode 100644 drivers/tpm/tis_i2c.c
Applied to u-boot/master, thanks!
participants (3)
-
Masahiro Yamada
-
Simon Glass
-
Tom Rini