diff options
author | Masahiro Yamada <yamada.m@jp.panasonic.com> | 2013-10-17 17:35:04 +0900 |
---|---|---|
committer | Tom Rini <trini@ti.com> | 2013-10-31 13:26:44 -0400 |
commit | 06c14117c44e4b93be0430740524d4e2ef2557c0 (patch) | |
tree | 953310770487931e0adcd07a3a34297d5ef93279 /arch/powerpc/cpu/mpc85xx | |
parent | 7cf40824bea10590cf2bb14ecfaa4c14ee907017 (diff) | |
download | u-boot-imx-06c14117c44e4b93be0430740524d4e2ef2557c0.zip u-boot-imx-06c14117c44e4b93be0430740524d4e2ef2557c0.tar.gz u-boot-imx-06c14117c44e4b93be0430740524d4e2ef2557c0.tar.bz2 |
powerpc: convert makefiles to Kbuild style
Note:
arch/powerpc/cpu/mpc8260/Makefile is originally like follows:
---<snip>---
START = start.o kgdb.o
COBJS = traps.o serial_smc.o serial_scc.o cpu.o cpu_init.o speed.o \
---<snip>---
COBJS-$(CONFIG_ETHER_ON_SCC) = ether_scc.o
---<snip>---
$(LIB): $(OBJS)
$(call cmd_link_o_target, $(OBJS) $(obj)kgdb.o)
The link rule `$(call cmd_link_o_target, $(OBJS) $(obj)kgdb.o)'
is weird.
kbdg.o is not included in $(OBJS) but linked into $(LIB)
and $(LIB) is not dependent on kgdb.o.
(Broken dependency tracking)
So,
START = start.o kgdb.o
shoud have been
START = start.o
SOBJS = kgdb.o
That is why this commit adds kgdb.o to obj-y, not to extra-y.
Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
Diffstat (limited to 'arch/powerpc/cpu/mpc85xx')
-rw-r--r-- | arch/powerpc/cpu/mpc85xx/Makefile | 233 |
1 files changed, 104 insertions, 129 deletions
diff --git a/arch/powerpc/cpu/mpc85xx/Makefile b/arch/powerpc/cpu/mpc85xx/Makefile index f70f0d7..50ddb50 100644 --- a/arch/powerpc/cpu/mpc85xx/Makefile +++ b/arch/powerpc/cpu/mpc85xx/Makefile @@ -8,10 +8,6 @@ # SPDX-License-Identifier: GPL-2.0+ # -include $(TOPDIR)/config.mk - -LIB = $(obj)lib$(CPU).o - MINIMAL= ifdef CONFIG_SPL_BUILD @@ -20,149 +16,128 @@ MINIMAL=y endif endif -START = start.o resetvec.o +extra-y = start.o resetvec.o ifdef MINIMAL -COBJS-y += cpu_init_early.o tlb.o spl_minimal.o +obj-y += cpu_init_early.o tlb.o spl_minimal.o else -SOBJS-$(CONFIG_MP) += release.o -SOBJS = $(SOBJS-y) +obj-$(CONFIG_MP) += release.o -COBJS-$(CONFIG_CMD_ERRATA) += cmd_errata.o -COBJS-$(CONFIG_CPM2) += commproc.o +obj-$(CONFIG_CMD_ERRATA) += cmd_errata.o +obj-$(CONFIG_CPM2) += commproc.o # supports ddr1 -COBJS-$(CONFIG_MPC8540) += ddr-gen1.o -COBJS-$(CONFIG_MPC8560) += ddr-gen1.o -COBJS-$(CONFIG_MPC8541) += ddr-gen1.o -COBJS-$(CONFIG_MPC8555) += ddr-gen1.o +obj-$(CONFIG_MPC8540) += ddr-gen1.o +obj-$(CONFIG_MPC8560) += ddr-gen1.o +obj-$(CONFIG_MPC8541) += ddr-gen1.o +obj-$(CONFIG_MPC8555) += ddr-gen1.o # supports ddr1/2 -COBJS-$(CONFIG_MPC8548) += ddr-gen2.o -COBJS-$(CONFIG_MPC8568) += ddr-gen2.o -COBJS-$(CONFIG_MPC8544) += ddr-gen2.o +obj-$(CONFIG_MPC8548) += ddr-gen2.o +obj-$(CONFIG_MPC8568) += ddr-gen2.o +obj-$(CONFIG_MPC8544) += ddr-gen2.o # supports ddr1/2/3 -COBJS-$(CONFIG_PPC_C29X) += ddr-gen3.o -COBJS-$(CONFIG_MPC8572) += ddr-gen3.o -COBJS-$(CONFIG_MPC8536) += ddr-gen3.o -COBJS-$(CONFIG_MPC8569) += ddr-gen3.o -COBJS-$(CONFIG_P1010) += ddr-gen3.o -COBJS-$(CONFIG_P1011) += ddr-gen3.o -COBJS-$(CONFIG_P1012) += ddr-gen3.o -COBJS-$(CONFIG_P1013) += ddr-gen3.o -COBJS-$(CONFIG_P1014) += ddr-gen3.o -COBJS-$(CONFIG_P1020) += ddr-gen3.o -COBJS-$(CONFIG_P1021) += ddr-gen3.o -COBJS-$(CONFIG_P1022) += ddr-gen3.o -COBJS-$(CONFIG_P1023) += ddr-gen3.o -COBJS-$(CONFIG_P1024) += ddr-gen3.o -COBJS-$(CONFIG_P1025) += ddr-gen3.o -COBJS-$(CONFIG_P2010) += ddr-gen3.o -COBJS-$(CONFIG_P2020) += ddr-gen3.o -COBJS-$(CONFIG_PPC_P2041) += ddr-gen3.o -COBJS-$(CONFIG_PPC_P3041) += ddr-gen3.o -COBJS-$(CONFIG_PPC_P4080) += ddr-gen3.o -COBJS-$(CONFIG_PPC_P5020) += ddr-gen3.o -COBJS-$(CONFIG_PPC_P5040) += ddr-gen3.o -COBJS-$(CONFIG_PPC_T4240) += ddr-gen3.o -COBJS-$(CONFIG_PPC_T4160) += ddr-gen3.o -COBJS-$(CONFIG_PPC_B4420) += ddr-gen3.o -COBJS-$(CONFIG_PPC_B4860) += ddr-gen3.o -COBJS-$(CONFIG_BSC9131) += ddr-gen3.o -COBJS-$(CONFIG_BSC9132) += ddr-gen3.o -COBJS-$(CONFIG_PPC_T1040) += ddr-gen3.o - -COBJS-$(CONFIG_CPM2) += ether_fcc.o -COBJS-$(CONFIG_OF_LIBFDT) += fdt.o -COBJS-$(CONFIG_FSL_CORENET) += liodn.o -COBJS-$(CONFIG_MP) += mp.o -COBJS-$(CONFIG_PCI) += pci.o -COBJS-$(CONFIG_SYS_DPAA_QBMAN) += portals.o +obj-$(CONFIG_PPC_C29X) += ddr-gen3.o +obj-$(CONFIG_MPC8572) += ddr-gen3.o +obj-$(CONFIG_MPC8536) += ddr-gen3.o +obj-$(CONFIG_MPC8569) += ddr-gen3.o +obj-$(CONFIG_P1010) += ddr-gen3.o +obj-$(CONFIG_P1011) += ddr-gen3.o +obj-$(CONFIG_P1012) += ddr-gen3.o +obj-$(CONFIG_P1013) += ddr-gen3.o +obj-$(CONFIG_P1014) += ddr-gen3.o +obj-$(CONFIG_P1020) += ddr-gen3.o +obj-$(CONFIG_P1021) += ddr-gen3.o +obj-$(CONFIG_P1022) += ddr-gen3.o +obj-$(CONFIG_P1023) += ddr-gen3.o +obj-$(CONFIG_P1024) += ddr-gen3.o +obj-$(CONFIG_P1025) += ddr-gen3.o +obj-$(CONFIG_P2010) += ddr-gen3.o +obj-$(CONFIG_P2020) += ddr-gen3.o +obj-$(CONFIG_PPC_P2041) += ddr-gen3.o +obj-$(CONFIG_PPC_P3041) += ddr-gen3.o +obj-$(CONFIG_PPC_P4080) += ddr-gen3.o +obj-$(CONFIG_PPC_P5020) += ddr-gen3.o +obj-$(CONFIG_PPC_P5040) += ddr-gen3.o +obj-$(CONFIG_PPC_T4240) += ddr-gen3.o +obj-$(CONFIG_PPC_T4160) += ddr-gen3.o +obj-$(CONFIG_PPC_B4420) += ddr-gen3.o +obj-$(CONFIG_PPC_B4860) += ddr-gen3.o +obj-$(CONFIG_BSC9131) += ddr-gen3.o +obj-$(CONFIG_BSC9132) += ddr-gen3.o +obj-$(CONFIG_PPC_T1040) += ddr-gen3.o + +obj-$(CONFIG_CPM2) += ether_fcc.o +obj-$(CONFIG_OF_LIBFDT) += fdt.o +obj-$(CONFIG_FSL_CORENET) += liodn.o +obj-$(CONFIG_MP) += mp.o +obj-$(CONFIG_PCI) += pci.o +obj-$(CONFIG_SYS_DPAA_QBMAN) += portals.o # various SoC specific assignments -COBJS-$(CONFIG_PPC_P2041) += p2041_ids.o -COBJS-$(CONFIG_PPC_P3041) += p3041_ids.o -COBJS-$(CONFIG_PPC_P4080) += p4080_ids.o -COBJS-$(CONFIG_PPC_P5020) += p5020_ids.o -COBJS-$(CONFIG_PPC_P5040) += p5040_ids.o -COBJS-$(CONFIG_PPC_T4240) += t4240_ids.o -COBJS-$(CONFIG_PPC_T4160) += t4240_ids.o -COBJS-$(CONFIG_PPC_B4420) += b4860_ids.o -COBJS-$(CONFIG_PPC_B4860) += b4860_ids.o -COBJS-$(CONFIG_PPC_T1040) += t1040_ids.o - -COBJS-$(CONFIG_QE) += qe_io.o -COBJS-$(CONFIG_CPM2) += serial_scc.o -COBJS-$(CONFIG_SYS_FSL_QORIQ_CHASSIS1) += fsl_corenet_serdes.o -COBJS-$(CONFIG_SYS_FSL_QORIQ_CHASSIS2) += fsl_corenet2_serdes.o +obj-$(CONFIG_PPC_P2041) += p2041_ids.o +obj-$(CONFIG_PPC_P3041) += p3041_ids.o +obj-$(CONFIG_PPC_P4080) += p4080_ids.o +obj-$(CONFIG_PPC_P5020) += p5020_ids.o +obj-$(CONFIG_PPC_P5040) += p5040_ids.o +obj-$(CONFIG_PPC_T4240) += t4240_ids.o +obj-$(CONFIG_PPC_T4160) += t4240_ids.o +obj-$(CONFIG_PPC_B4420) += b4860_ids.o +obj-$(CONFIG_PPC_B4860) += b4860_ids.o +obj-$(CONFIG_PPC_T1040) += t1040_ids.o + +obj-$(CONFIG_QE) += qe_io.o +obj-$(CONFIG_CPM2) += serial_scc.o +obj-$(CONFIG_SYS_FSL_QORIQ_CHASSIS1) += fsl_corenet_serdes.o +obj-$(CONFIG_SYS_FSL_QORIQ_CHASSIS2) += fsl_corenet2_serdes.o # SoC specific SERDES support -COBJS-$(CONFIG_PPC_C29X) += c29x_serdes.o -COBJS-$(CONFIG_MPC8536) += mpc8536_serdes.o -COBJS-$(CONFIG_MPC8544) += mpc8544_serdes.o -COBJS-$(CONFIG_MPC8548) += mpc8548_serdes.o -COBJS-$(CONFIG_MPC8568) += mpc8568_serdes.o -COBJS-$(CONFIG_MPC8569) += mpc8569_serdes.o -COBJS-$(CONFIG_MPC8572) += mpc8572_serdes.o -COBJS-$(CONFIG_P1010) += p1010_serdes.o -COBJS-$(CONFIG_P1011) += p1021_serdes.o -COBJS-$(CONFIG_P1012) += p1021_serdes.o -COBJS-$(CONFIG_P1013) += p1022_serdes.o -COBJS-$(CONFIG_P1014) += p1010_serdes.o -COBJS-$(CONFIG_P1017) += p1023_serdes.o -COBJS-$(CONFIG_P1020) += p1021_serdes.o -COBJS-$(CONFIG_P1021) += p1021_serdes.o -COBJS-$(CONFIG_P1022) += p1022_serdes.o -COBJS-$(CONFIG_P1023) += p1023_serdes.o -COBJS-$(CONFIG_P1024) += p1021_serdes.o -COBJS-$(CONFIG_P1025) += p1021_serdes.o -COBJS-$(CONFIG_P2010) += p2020_serdes.o -COBJS-$(CONFIG_P2020) += p2020_serdes.o -COBJS-$(CONFIG_PPC_P2041) += p2041_serdes.o -COBJS-$(CONFIG_PPC_P3041) += p3041_serdes.o -COBJS-$(CONFIG_PPC_P4080) += p4080_serdes.o -COBJS-$(CONFIG_PPC_P5020) += p5020_serdes.o -COBJS-$(CONFIG_PPC_P5040) += p5040_serdes.o -COBJS-$(CONFIG_PPC_T4240) += t4240_serdes.o -COBJS-$(CONFIG_PPC_T4160) += t4240_serdes.o -COBJS-$(CONFIG_PPC_B4420) += b4860_serdes.o -COBJS-$(CONFIG_PPC_B4860) += b4860_serdes.o -COBJS-$(CONFIG_BSC9132) += bsc9132_serdes.o -COBJS-$(CONFIG_PPC_T1040) += t1040_serdes.o - -COBJS-y += cpu.o -COBJS-y += cpu_init.o -COBJS-y += cpu_init_early.o -COBJS-y += interrupts.o -COBJS-y += speed.o -COBJS-y += tlb.o -COBJS-y += traps.o +obj-$(CONFIG_PPC_C29X) += c29x_serdes.o +obj-$(CONFIG_MPC8536) += mpc8536_serdes.o +obj-$(CONFIG_MPC8544) += mpc8544_serdes.o +obj-$(CONFIG_MPC8548) += mpc8548_serdes.o +obj-$(CONFIG_MPC8568) += mpc8568_serdes.o +obj-$(CONFIG_MPC8569) += mpc8569_serdes.o +obj-$(CONFIG_MPC8572) += mpc8572_serdes.o +obj-$(CONFIG_P1010) += p1010_serdes.o +obj-$(CONFIG_P1011) += p1021_serdes.o +obj-$(CONFIG_P1012) += p1021_serdes.o +obj-$(CONFIG_P1013) += p1022_serdes.o +obj-$(CONFIG_P1014) += p1010_serdes.o +obj-$(CONFIG_P1017) += p1023_serdes.o +obj-$(CONFIG_P1020) += p1021_serdes.o +obj-$(CONFIG_P1021) += p1021_serdes.o +obj-$(CONFIG_P1022) += p1022_serdes.o +obj-$(CONFIG_P1023) += p1023_serdes.o +obj-$(CONFIG_P1024) += p1021_serdes.o +obj-$(CONFIG_P1025) += p1021_serdes.o +obj-$(CONFIG_P2010) += p2020_serdes.o +obj-$(CONFIG_P2020) += p2020_serdes.o +obj-$(CONFIG_PPC_P2041) += p2041_serdes.o +obj-$(CONFIG_PPC_P3041) += p3041_serdes.o +obj-$(CONFIG_PPC_P4080) += p4080_serdes.o +obj-$(CONFIG_PPC_P5020) += p5020_serdes.o +obj-$(CONFIG_PPC_P5040) += p5040_serdes.o +obj-$(CONFIG_PPC_T4240) += t4240_serdes.o +obj-$(CONFIG_PPC_T4160) += t4240_serdes.o +obj-$(CONFIG_PPC_B4420) += b4860_serdes.o +obj-$(CONFIG_PPC_B4860) += b4860_serdes.o +obj-$(CONFIG_BSC9132) += bsc9132_serdes.o +obj-$(CONFIG_PPC_T1040) += t1040_serdes.o + +obj-y += cpu.o +obj-y += cpu_init.o +obj-y += cpu_init_early.o +obj-y += interrupts.o +obj-y += speed.o +obj-y += tlb.o +obj-y += traps.o # Stub implementations of cache management functions for USB -COBJS-y += cache.o +obj-y += cache.o endif # not minimal - -COBJS = $(COBJS-y) - -SRCS := $(START:.o=.S) $(SOBJS:.o=.S) $(COBJS:.o=.c) -OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS)) -START := $(addprefix $(obj),$(START)) - -all: $(obj).depend $(START) $(LIB) - -$(LIB): $(OBJS) - $(call cmd_link_o_target, $(OBJS)) - -######################################################################### - -# defines $(obj).depend target -include $(SRCTREE)/rules.mk - -sinclude $(obj).depend - -######################################################################### |