Switch to using $(PHASE_) in Makefiles
Subsystems (33)
v3 cover Switch to using $(PHASE_) in Makefiles
Hey all,
This series switches to always using $(PHASE_) in Makefiles when building rather than $(PHASE_) or $(XPL_). It also starts on documenting this part of the build, but as a follow-up we need to rename doc/develop/spl.rst and expand on explaining things a bit.
Signature · 1 line
Tom
PATCH v3 1/3 Kbuild: Always use $(PHASE_)
It is confusing to have both "$(PHASE_)" and "$(XPL_)" be used in our Makefiles as part of the macros to determine when to do something in our Makefiles based on what phase of the build we are in. For consistency, bring this down to a single macro and use "$(PHASE_)" only.
---
Changes in v3:
- Address Quentin Schulz's comments.
Changes in v2:
- Drop RFC
- Update scripts/Makefile.xpl as well
--- Makefile | 4 +-- arch/arm/config.mk | 6 ++-- arch/arm/cpu/arm920t/Makefile | 2 +- arch/arm/cpu/arm926ejs/Makefile | 2 +- arch/arm/cpu/armv7/Makefile | 2 +- arch/arm/cpu/armv8/Makefile | 4 +-- arch/arm/lib/Makefile | 2 +- arch/arm/mach-at91/arm926ejs/Makefile | 2 +- arch/arm/mach-imx/Makefile | 2 +- arch/arm/mach-omap2/am33xx/Makefile | 2 +- arch/arm/mach-orion5x/Makefile | 4 +-- arch/arm/mach-stm32mp/stm32mp1/Makefile | 2 +- arch/arm/mach-tegra/Makefile | 2 +- arch/arm/mach-tegra/tegra20/Makefile | 2 +- arch/arm/mach-tegra/tegra30/Makefile | 2 +- arch/arm/mach-zynqmp/Makefile | 2 +- arch/riscv/Makefile | 2 +- arch/riscv/lib/Makefile | 8 ++--- arch/sandbox/lib/Makefile | 2 +- arch/x86/Makefile | 2 +- arch/x86/cpu/Makefile | 12 +++---- arch/x86/cpu/intel_common/Makefile | 4 +-- arch/x86/cpu/ivybridge/Makefile | 6 ++-- arch/x86/cpu/qemu/Makefile | 2 +- arch/x86/lib/Makefile | 4 +-- board/bosch/guardian/Makefile | 2 +- board/freescale/common/Makefile | 4 +-- board/st/common/Makefile | 2 +- board/tcl/sl50/Makefile | 2 +- board/ti/am335x/Makefile | 2 +- board/ti/am43xx/Makefile | 2 +- board/vscom/baltos/Makefile | 2 +- board/xilinx/zynqmp/Makefile | 2 +- boot/Makefile | 2 +- cmd/Makefile | 2 +- doc/develop/tests_writing.rst | 6 ++-- drivers/Makefile | 14 ++++---- drivers/ata/Makefile | 2 +- drivers/block/Makefile | 2 +- drivers/bus/Makefile | 2 +- drivers/core/Makefile | 6 ++-- drivers/ddr/altera/Makefile | 2 +- drivers/dfu/Makefile | 18 +++++----- drivers/firmware/Makefile | 2 +- drivers/gpio/Makefile | 10 +++--- drivers/i2c/Makefile | 16 ++++----- drivers/led/Makefile | 2 +- drivers/mailbox/Makefile | 2 +- drivers/misc/Makefile | 10 +++--- drivers/mmc/Makefile | 6 ++-- drivers/mux/Makefile | 2 +- drivers/nvme/Makefile | 2 +- drivers/phy/Makefile | 6 ++-- drivers/phy/cadence/Makefile | 4 +-- drivers/phy/ti/Makefile | 2 +- drivers/pinctrl/Makefile | 8 ++--- drivers/power/domain/Makefile | 2 +- drivers/power/pmic/Makefile | 30 ++++++++-------- drivers/power/regulator/Makefile | 46 ++++++++++++------------- drivers/remoteproc/Makefile | 2 +- drivers/serial/Makefile | 2 +- drivers/timer/Makefile | 8 ++--- drivers/usb/cdns3/Makefile | 4 +-- drivers/usb/common/Makefile | 2 +- drivers/usb/dwc3/Makefile | 4 +-- drivers/usb/gadget/udc/Makefile | 4 +-- drivers/usb/host/Makefile | 2 +- drivers/video/Makefile | 2 +- drivers/video/tidss/Makefile | 2 +- fs/fat/Makefile | 4 +-- fs/squashfs/Makefile | 2 +- lib/Makefile | 10 +++--- lib/acpi/Makefile | 8 ++--- lib/aes/Makefile | 2 +- lib/crypto/Makefile | 20 +++++------ lib/ecdsa/Makefile | 2 +- lib/lwip/Makefile | 2 +- lib/mbedtls/Makefile | 38 ++++++++++---------- net/Makefile | 6 ++-- net/lwip/Makefile | 2 +- scripts/Kbuild.include | 10 +++--- scripts/Makefile.xpl | 10 +++--- test/Makefile | 6 ++-- test/boot/Makefile | 2 +- test/cmd/Makefile | 2 +- test/common/Makefile | 6 ++-- test/fuzz/Makefile | 2 +- test/lib/Makefile | 4 +-- tools/qconfig.py | 8 ++--- 89 files changed, 240 insertions(+), 246 deletions(-)
Makefile +2 -2
@@ -835,7 +835,7 @@ UBOOTINCLUDE := \ -I$(srctree)/lib/mbedtls/port \ -I$(srctree)/lib/mbedtls/external/mbedtls \ -I$(srctree)/lib/mbedtls/external/mbedtls/include) \ - $(if $(CONFIG_$(XPL_)SYS_THUMB_BUILD), \ + $(if $(CONFIG_$(PHASE_)SYS_THUMB_BUILD), \ $(if $(CONFIG_HAS_THUMB2), \ $(if $(CONFIG_CPU_V7M), \ -I$(srctree)/arch/arm/thumb1/include), \
@@ -872,7 +872,7 @@ libs-y += disk/ libs-y += drivers/ libs-$(CONFIG_SYS_FSL_DDR) += drivers/ddr/fsl/ libs-$(CONFIG_SYS_FSL_MMDC) += drivers/ddr/fsl/ -libs-$(CONFIG_$(XPL_)ALTERA_SDRAM) += drivers/ddr/altera/ +libs-$(CONFIG_$(PHASE_)ALTERA_SDRAM) += drivers/ddr/altera/ libs-y += drivers/usb/cdns3/ libs-y += drivers/usb/dwc3/ libs-y += drivers/usb/common/
arch/arm/config.mk +3 -3
@@ -40,7 +40,7 @@ PLATFORM_ELFFLAGS += -B arm -O elf32-littlearm endif # Choose between ARM/Thumb instruction sets -ifeq ($(CONFIG_$(XPL_)SYS_THUMB_BUILD),y) +ifeq ($(CONFIG_$(PHASE_)SYS_THUMB_BUILD),y) AFLAGS_IMPLICIT_IT := $(call as-option,-Wa$(comma)-mimplicit-it=always) PF_CPPFLAGS_ARM := $(AFLAGS_IMPLICIT_IT) \ $(call cc-option, -mthumb -mthumb-interwork,\
@@ -53,7 +53,7 @@ PF_CPPFLAGS_ARM := $(call cc-option,-marm,) \ endif # Only test once -ifeq ($(CONFIG_$(XPL_)SYS_THUMB_BUILD),y) +ifeq ($(CONFIG_$(PHASE_)SYS_THUMB_BUILD),y) archprepare: checkthumb checkgcc6 checkthumb:
@@ -116,7 +116,7 @@ LDFLAGS_u-boot += -pie # # http://sourceware.org/bugzilla/show_bug.cgi?id=12532 # -ifeq ($(CONFIG_$(XPL_)SYS_THUMB_BUILD),y) +ifeq ($(CONFIG_$(PHASE_)SYS_THUMB_BUILD),y) ifeq ($(GAS_BUG_12532),) export GAS_BUG_12532:=$(shell if [ $(call binutils-version) -lt 0222 ] ; \ then echo y; else echo n; fi)
arch/arm/cpu/arm920t/Makefile +1 -1
@@ -9,6 +9,6 @@ obj-y += cpu.o # some files can only build in ARM mode -ifdef CONFIG_$(XPL_)SYS_THUMB_BUILD +ifdef CONFIG_$(PHASE_)SYS_THUMB_BUILD CFLAGS_cpu.o := -marm endif
arch/arm/cpu/arm926ejs/Makefile +1 -1
@@ -17,7 +17,7 @@ obj-$(CONFIG_ARCH_SUNXI) += sunxi/ # some files can only build in ARM or THUMB2, not THUMB1 -ifdef CONFIG_$(XPL_)SYS_THUMB_BUILD +ifdef CONFIG_$(PHASE_)SYS_THUMB_BUILD ifndef CONFIG_HAS_THUMB2 CFLAGS_cpu.o := -marm
arch/arm/cpu/armv7/Makefile +1 -1
@@ -17,7 +17,7 @@ obj-$(CONFIG_EFI_LOADER) += sctlr.o obj-$(CONFIG_ARMV7_NONSEC) += exception_level.o endif -ifneq ($(CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT),y) +ifneq ($(CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT),y) obj-y += lowlevel_init.o endif
arch/arm/cpu/armv8/Makefile +2 -2
@@ -9,7 +9,7 @@ obj-y += cpu.o ifndef CONFIG_$(PHASE_)TIMER obj-$(CONFIG_SYS_ARCH_TIMER) += generic_timer.o endif -ifndef CONFIG_$(XPL_)SYS_DCACHE_OFF +ifndef CONFIG_$(PHASE_)SYS_DCACHE_OFF obj-y += cache_v8.o obj-y += cache.o endif
@@ -33,7 +33,7 @@ obj-$(CONFIG_ACPI_PARKING_PROTOCOL) += acpi_park_v8.o else obj-$(CONFIG_ARCH_SUNXI) += fel_utils.o endif -obj-$(CONFIG_$(XPL_)ARMV8_SEC_FIRMWARE_SUPPORT) += sec_firmware.o sec_firmware_asm.o +obj-$(CONFIG_$(PHASE_)ARMV8_SEC_FIRMWARE_SUPPORT) += sec_firmware.o sec_firmware_asm.o ifdef CONFIG_XPL_BUILD obj-$(CONFIG_SPL_RECOVER_DATA_SECTION) += spl_data.o
arch/arm/lib/Makefile +1 -1
@@ -96,7 +96,7 @@ endif # some files can only build in ARM or THUMB2, not THUMB1 -ifdef CONFIG_$(XPL_)SYS_THUMB_BUILD +ifdef CONFIG_$(PHASE_)SYS_THUMB_BUILD asflags-$(CONFIG_HAS_THUMB2) += -DCONFIG_THUMB2_KERNEL ifndef CONFIG_HAS_THUMB2
arch/arm/mach-at91/arm926ejs/Makefile +1 -1
@@ -32,7 +32,7 @@ obj-y += lowlevel_init.o endif endif -ifdef CONFIG_$(XPL_)SYS_THUMB_BUILD +ifdef CONFIG_$(PHASE_)SYS_THUMB_BUILD ifndef CONFIG_HAS_THUMB2 CFLAGS_cache.o := -marm
arch/arm/mach-imx/Makefile +1 -1
@@ -60,7 +60,7 @@ obj-$(CONFIG_IMX_RDC) += rdc-sema.o ifneq ($(CONFIG_XPL_BUILD),y) obj-$(CONFIG_IMX_BOOTAUX) += imx_bootaux.o endif -obj-$(CONFIG_$(XPL_)SATA) += sata.o +obj-$(CONFIG_$(PHASE_)SATA) += sata.o obj-$(CONFIG_IMX_HAB) += hab.o obj-$(CONFIG_SYSCOUNTER_TIMER) += syscounter.o endif
arch/arm/mach-omap2/am33xx/Makefile +1 -1
@@ -11,7 +11,7 @@ endif obj-y += sys_info.o obj-y += ddr.o -ifeq ($(CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT),) +ifeq ($(CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT),) obj-y += emif4.o endif obj-y += board.o
arch/arm/mach-orion5x/Makefile +2 -2
@@ -11,13 +11,13 @@ obj-y = cpu.o obj-y += dram.o obj-y += timer.o -ifndef CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT +ifndef CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT obj-y += lowlevel_init.o endif # some files can only build in ARM or THUMB2, not THUMB1 -ifdef CONFIG_$(XPL_)SYS_THUMB_BUILD +ifdef CONFIG_$(PHASE_)SYS_THUMB_BUILD ifndef CONFIG_HAS_THUMB2 CFLAGS_cpu.o := -marm
arch/arm/mach-stm32mp/stm32mp1/Makefile +1 -1
@@ -15,5 +15,5 @@ else obj-$(CONFIG_ARMV7_PSCI) += psci.o endif -obj-$(CONFIG_$(XPL_)STM32MP15_PWR) += pwr_regulator.o +obj-$(CONFIG_$(PHASE_)STM32MP15_PWR) += pwr_regulator.o obj-$(CONFIG_OF_SYSTEM_SETUP) += fdt.o
arch/arm/mach-tegra/Makefile +1 -1
@@ -16,7 +16,7 @@ obj-$(CONFIG_TEGRA_GP_PADCTRL) += ap.o obj-y += board.o board2.o obj-y += cache.o obj-$(CONFIG_TEGRA_CLKRST) += clock.o -obj-$(CONFIG_$(XPL_)TEGRA_CRYPTO) += crypto.o +obj-$(CONFIG_$(PHASE_)TEGRA_CRYPTO) += crypto.o obj-$(CONFIG_TEGRA_PMC) += powergate.o obj-y += xusb-padctl-dummy.o
arch/arm/mach-tegra/tegra20/Makefile +1 -1
@@ -3,7 +3,7 @@ # (C) Copyright 2010,2011 Nvidia Corporation. obj-$(CONFIG_XPL_BUILD) += cpu.o -obj-$(CONFIG_$(XPL_)CMD_EBTUPDATE) += bct.o +obj-$(CONFIG_$(PHASE_)CMD_EBTUPDATE) += bct.o # The AVP is ARMv4T architecture so we must use special compiler # flags for any startup files it might use.
arch/arm/mach-tegra/tegra30/Makefile +1 -1
@@ -3,6 +3,6 @@ # Copyright (c) 2010-2012, NVIDIA CORPORATION. All rights reserved. obj-$(CONFIG_XPL_BUILD) += cpu.o -obj-$(CONFIG_$(XPL_)CMD_EBTUPDATE) += bct.o +obj-$(CONFIG_$(PHASE_)CMD_EBTUPDATE) += bct.o obj-y += clock.o
arch/arm/mach-zynqmp/Makefile +1 -1
@@ -7,7 +7,7 @@ obj-y += aes.o clk.o cpu.o obj-$(CONFIG_MP) += mp.o obj-$(CONFIG_XPL_BUILD) += spl.o handoff.o psu_spl_init.o obj-$(CONFIG_SPL_ZYNQMP_DRAM_ECC_INIT) += ecc_spl_init.o -obj-$(CONFIG_$(XPL_)ZYNQMP_PSU_INIT_ENABLED) += psu_spl_init.o +obj-$(CONFIG_$(PHASE_)ZYNQMP_PSU_INIT_ENABLED) += psu_spl_init.o ifndef CONFIG_XPL_BUILD obj-$(CONFIG_CMD_ZYNQMP) += zynqmp.o
arch/riscv/Makefile +1 -1
@@ -48,7 +48,7 @@ endif ARCH_FLAGS = -march=$(RISCV_MARCH) -mabi=$(ABI) \ -mcmodel=$(CMODEL) -ifeq ($(CONFIG_$(XPL_)FRAMEPOINTER),y) +ifeq ($(CONFIG_$(PHASE_)FRAMEPOINTER),y) ARCH_FLAGS += -fno-omit-frame-pointer endif
arch/riscv/lib/Makefile +4 -4
@@ -11,19 +11,19 @@ obj-$(CONFIG_CMD_BOOTI) += bootm.o image.o obj-$(CONFIG_CMD_GO) += boot.o obj-y += cache.o obj-$(CONFIG_SIFIVE_CACHE) += sifive_cache.o -ifeq ($(CONFIG_$(XPL_)RISCV_MMODE),y) -obj-$(CONFIG_$(XPL_)RISCV_ACLINT) += aclint_ipi.o +ifeq ($(CONFIG_$(PHASE_)RISCV_MMODE),y) +obj-$(CONFIG_$(PHASE_)RISCV_ACLINT) += aclint_ipi.o obj-$(CONFIG_ANDES_PLICSW) += andes_plicsw.o else obj-$(CONFIG_SBI) += sbi.o obj-$(CONFIG_SBI_IPI) += sbi_ipi.o endif obj-y += interrupts.o -ifeq ($(CONFIG_$(XPL_)SYSRESET),) +ifeq ($(CONFIG_$(PHASE_)SYSRESET),) obj-y += reset.o endif obj-y += setjmp.o -obj-$(CONFIG_$(XPL_)SMP) += smp.o +obj-$(CONFIG_$(PHASE_)SMP) += smp.o obj-$(CONFIG_XPL_BUILD) += spl.o obj-y += fdt_fixup.o obj-$(CONFIG_$(SPL)CMD_BDI) += bdinfo.o
arch/sandbox/lib/Makefile +1 -1
@@ -9,4 +9,4 @@ obj-y += fdt_fixup.o interrupts.o obj-$(CONFIG_PCI) += pci_io.o obj-$(CONFIG_CMD_BOOTM) += bootm.o obj-$(CONFIG_CMD_BOOTZ) += bootm.o -obj-$(CONFIG_$(SPL_)ACPIGEN) += acpi_table.o +obj-$(CONFIG_$(PHASE_)ACPIGEN) += acpi_table.o
arch/x86/Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0+ ifeq ($(CONFIG_EFI_APP),) -ifdef CONFIG_$(XPL_)X86_64 +ifdef CONFIG_$(PHASE_)X86_64 head-y := arch/x86/cpu/start64.o else ifeq ($(CONFIG_$(PHASE_)X86_16BIT_INIT),y)
arch/x86/cpu/Makefile +6 -6
@@ -6,7 +6,7 @@ # (C) Copyright 2002 # Daniel Engström, Omicron Ceti AB, [email protected]. -ifeq ($(CONFIG_$(XPL_)X86_64),y) +ifeq ($(CONFIG_$(PHASE_)X86_64),y) extra-y = start64.o else ifeq ($(CONFIG_$(PHASE_)X86_16BIT_INIT),y)
@@ -31,7 +31,7 @@ ifndef CONFIG_TPL_BUILD obj-y += cpu_x86.o endif -ifndef CONFIG_$(XPL_)X86_64 +ifndef CONFIG_$(PHASE_)X86_64 AFLAGS_REMOVE_call32.o := -mregparm=3 \ $(if $(CONFIG_EFI_STUB_64BIT),-march=i386 -m32) AFLAGS_call32.o := -fpic -fshort-wchar \
@@ -59,18 +59,18 @@ obj-$(CONFIG_QFW) += qfw_cpu.o ifndef CONFIG_SYS_COREBOOT obj-$(CONFIG_$(PHASE_)X86_32BIT_INIT) += irq.o endif -ifndef CONFIG_$(XPL_)X86_64 -obj-$(CONFIG_$(XPL_)SMP) += mp_init.o +ifndef CONFIG_$(PHASE_)X86_64 +obj-$(CONFIG_$(PHASE_)SMP) += mp_init.o endif obj-y += mtrr.o obj-$(CONFIG_PCI) += pci.o -ifndef CONFIG_$(XPL_)X86_64 +ifndef CONFIG_$(PHASE_)X86_64 obj-$(CONFIG_SMP) += sipi_vector.o endif obj-y += turbo.o obj-$(CONFIG_HAVE_ACPI_RESUME) += wakeup.o -ifeq ($(CONFIG_$(XPL_)X86_64),y) +ifeq ($(CONFIG_$(PHASE_)X86_64),y) obj-y += x86_64/ else obj-y += i386/
arch/x86/cpu/intel_common/Makefile +2 -2
@@ -26,10 +26,10 @@ obj-y += cpu.o obj-y += fast_spi.o obj-y += lpc.o obj-y += lpss.o -obj-$(CONFIG_$(XPL_)INTEL_GENERIC_WIFI) += generic_wifi.o +obj-$(CONFIG_$(PHASE_)INTEL_GENERIC_WIFI) += generic_wifi.o ifndef CONFIG_EFI_APP obj-$(CONFIG_$(PHASE_)X86_32BIT_INIT) += microcode.o -ifndef CONFIG_$(XPL_)X86_64 +ifndef CONFIG_$(PHASE_)X86_64 obj-y += microcode.o endif endif
arch/x86/cpu/ivybridge/Makefile +3 -3
@@ -5,15 +5,15 @@ ifdef CONFIG_HAVE_FSP obj-y += fsp_configs.o ivybridge.o else -obj-$(CONFIG_$(XPL_)X86_32BIT_INIT) += cpu.o +obj-$(CONFIG_$(PHASE_)X86_32BIT_INIT) += cpu.o obj-y += early_me.o obj-y += lpc.o obj-y += northbridge.o ifndef CONFIG_XPL_BUILD obj-y += sata.o endif -obj-$(CONFIG_$(XPL_)X86_32BIT_INIT) += sdram.o -ifndef CONFIG_$(XPL_)X86_32BIT_INIT +obj-$(CONFIG_$(PHASE_)X86_32BIT_INIT) += sdram.o +ifndef CONFIG_$(PHASE_)X86_32BIT_INIT obj-y += sdram_nop.o endif endif
arch/x86/cpu/qemu/Makefile +1 -1
@@ -2,7 +2,7 @@ # # Copyright (C) 2015, Bin Meng <[email protected]> -ifndef CONFIG_$(XPL_)X86_64 +ifndef CONFIG_$(PHASE_)X86_64 obj-y += car.o endif obj-y += dram.o
arch/x86/lib/Makefile +2 -2
@@ -19,7 +19,7 @@ ifndef CONFIG_XPL_BUILD obj-$(CONFIG_CMD_BOOTM) += bootm.o endif obj-y += cmd_boot.o -obj-$(CONFIG_$(XPL_)COREBOOT_SYSINFO) += coreboot/ +obj-$(CONFIG_$(PHASE_)COREBOOT_SYSINFO) += coreboot/ obj-$(CONFIG_SEABIOS) += coreboot_table.o obj-y += early_cmos.o obj-y += e820.o
@@ -90,7 +90,7 @@ endif ifdef CONFIG_EFI_STUB -ifeq ($(CONFIG_$(XPL_)X86_64),) +ifeq ($(CONFIG_$(PHASE_)X86_64),) extra-y += $(EFI_CRT0) $(EFI_RELOC) endif
board/bosch/guardian/Makefile +1 -1
@@ -5,7 +5,7 @@ # Copyright (C) 2018 Robert Bosch Power Tools GmbH # -ifeq ($(CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT),) +ifeq ($(CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT),) obj-y := mux.o endif
board/freescale/common/Makefile +2 -2
@@ -34,7 +34,7 @@ obj-$(CONFIG_FSL_NGPIXIS) += ngpixis.o endif obj-$(I2C_COMMON) += i2c_common.o obj-$(CONFIG_FSL_USE_PCA9547_MUX) += i2c_mux.o -obj-$(CONFIG_$(XPL_)VID) += vid.o +obj-$(CONFIG_$(PHASE_)VID) += vid.o obj-$(CONFIG_FSL_QIXIS) += qixis.o ifndef CONFIG_XPL_BUILD obj-$(CONFIG_ID_EEPROM) += sys_eeprom.o
@@ -54,7 +54,7 @@ obj-$(CONFIG_TARGET_MPC8548CDS) += cds_pci_ft.o obj-$(CONFIG_TARGET_P3041DS) += ics307_clk.o obj-$(CONFIG_TARGET_P4080DS) += ics307_clk.o obj-$(CONFIG_TARGET_P5040DS) += ics307_clk.o -ifeq ($(CONFIG_$(XPL_)POWER_LEGACY),y) +ifeq ($(CONFIG_$(PHASE_)POWER_LEGACY),y) obj-$(CONFIG_POWER_PFUZE100) += pfuze.o endif obj-$(CONFIG_DM_PMIC_PFUZE100) += pfuze.o
board/st/common/Makefile +1 -1
@@ -8,7 +8,7 @@ obj-$(CONFIG_PMIC_STPMIC1) += stpmic1.o ifeq ($(CONFIG_ARCH_STM32MP),y) obj-$(CONFIG_SET_DFU_ALT_INFO) += stm32mp_dfu.o -obj-$(CONFIG_$(XPL_)DFU_VIRT) += stm32mp_dfu_virt.o +obj-$(CONFIG_$(PHASE_)DFU_VIRT) += stm32mp_dfu_virt.o endif obj-$(CONFIG_TYPEC_STUSB160X) += stusb160x.o
board/tcl/sl50/Makefile +1 -1
@@ -4,7 +4,7 @@ # # Copyright (C) 2015 Toby Churchill Ltd - http://www.toby-churchill.com/ -ifeq ($(CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT),) +ifeq ($(CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT),) obj-y := mux.o endif
board/ti/am335x/Makefile +1 -1
@@ -4,7 +4,7 @@ # # Copyright (C) 2011 Texas Instruments Incorporated - https://www.ti.com/ -ifeq ($(CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT),) +ifeq ($(CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT),) obj-y := mux.o endif
board/ti/am43xx/Makefile +1 -1
@@ -4,7 +4,7 @@ # # Copyright (C) 2013 Texas Instruments Incorporated - https://www.ti.com/ -ifeq ($(CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT),) +ifeq ($(CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT),) obj-y := mux.o endif
board/vscom/baltos/Makefile +1 -1
@@ -4,7 +4,7 @@ # # Copyright (C) 2011 Texas Instruments Incorporated - https://www.ti.com/ -ifeq ($(CONFIG_$(XPL_)SKIP_LOWLEVEL_INIT),) +ifeq ($(CONFIG_$(PHASE_)SKIP_LOWLEVEL_INIT),) obj-y := mux.o endif
board/xilinx/zynqmp/Makefile +1 -1
@@ -31,7 +31,7 @@ $(warning Put custom psu_init_gpl.c/h to board/xilinx/zynqmp/custom_hw_platform/ endif endif -obj-$(CONFIG_$(XPL_)ZYNQMP_PSU_INIT_ENABLED) += $(init-objs) +obj-$(CONFIG_$(PHASE_)ZYNQMP_PSU_INIT_ENABLED) += $(init-objs) ifdef CONFIG_XPL_BUILD ifneq ($(CONFIG_ZYNQMP_SPL_PM_CFG_OBJ_FILE),"")
boot/Makefile +1 -1
@@ -47,7 +47,7 @@ obj-$(CONFIG_$(PHASE_)UPL_WRITE) += upl_write.o obj-$(CONFIG_$(PHASE_)OF_LIBFDT) += image-fdt.o obj-$(CONFIG_$(PHASE_)FIT_SIGNATURE) += fdt_region.o obj-$(CONFIG_$(PHASE_)FIT) += image-fit.o -obj-$(CONFIG_$(XPL_)MULTI_DTB_FIT) += boot_fit.o common_fit.o +obj-$(CONFIG_$(PHASE_)MULTI_DTB_FIT) += boot_fit.o common_fit.o obj-$(CONFIG_$(PHASE_)IMAGE_PRE_LOAD) += image-pre-load.o obj-$(CONFIG_$(PHASE_)IMAGE_SIGN_INFO) += image-sig.o obj-$(CONFIG_$(PHASE_)FIT_SIGNATURE) += image-fit-sig.o
cmd/Makefile +1 -1
@@ -255,7 +255,7 @@ obj-$(CONFIG_ARCH_K3) += ti/ obj-$(CONFIG_ARCH_OMAP2PLUS) += ti/ endif # !CONFIG_XPL_BUILD -obj-$(CONFIG_$(XPL_)CMD_TLV_EEPROM) += tlv_eeprom.o +obj-$(CONFIG_$(PHASE_)CMD_TLV_EEPROM) += tlv_eeprom.o obj-$(CONFIG_CMD_BCM_EXT_UTILS) += broadcom/
doc/develop/tests_writing.rst +3 -3
@@ -309,15 +309,15 @@ an #ifdef since the suite will automatically be compiled out in that case. Finally, add the test to the build by adding to the Makefile in the same directory:: - obj-$(CONFIG_$(XPL_)CMDLINE) += wibble.o + obj-$(CONFIG_$(PHASE_)CMDLINE) += wibble.o Note that CMDLINE is never enabled in SPL, so this test will only be present in U-Boot proper. See below for how to do SPL tests. You can add an extra Kconfig check if needed:: - ifneq ($(CONFIG_$(XPL_)WIBBLE),) - obj-$(CONFIG_$(XPL_)CMDLINE) += wibble.o + ifneq ($(CONFIG_$(PHASE_)WIBBLE),) + obj-$(CONFIG_$(PHASE_)CMDLINE) += wibble.o endif Each suite can have an optional init and uninit function. These are run before
drivers/Makefile +7 -7
@@ -34,15 +34,15 @@ obj-$(CONFIG_$(PHASE_)SERIAL) += serial/ obj-$(CONFIG_$(PHASE_)SPI) += spi/ obj-$(CONFIG_$(PHASE_)TIMER) += timer/ obj-$(CONFIG_$(PHASE_)VIRTIO) += virtio/ -obj-$(CONFIG_$(XPL_)DM_MAILBOX) += mailbox/ -obj-$(CONFIG_$(XPL_)REMOTEPROC) += remoteproc/ -obj-$(CONFIG_$(XPL_)SYSINFO) += sysinfo/ +obj-$(CONFIG_$(PHASE_)DM_MAILBOX) += mailbox/ +obj-$(CONFIG_$(PHASE_)REMOTEPROC) += remoteproc/ +obj-$(CONFIG_$(PHASE_)SYSINFO) += sysinfo/ obj-$(CONFIG_$(PHASE_)SM) += sm/ obj-$(CONFIG_$(PHASE_)TPM) += tpm/ -obj-$(CONFIG_$(XPL_)NVME) += nvme/ +obj-$(CONFIG_$(PHASE_)NVME) += nvme/ obj-$(CONFIG_XEN) += xen/ -obj-$(CONFIG_$(XPL_)FPGA) += fpga/ -obj-$(CONFIG_$(XPL_)VIDEO) += video/ +obj-$(CONFIG_$(PHASE_)FPGA) += fpga/ +obj-$(CONFIG_$(PHASE_)VIDEO) += video/ obj-y += bus/
@@ -55,7 +55,7 @@ obj-$(CONFIG_SPL_CRYPTO) += crypto/ obj-$(CONFIG_SPL_MPC8XXX_INIT_DDR) += ddr/fsl/ obj-$(CONFIG_ARMADA_38X) += ddr/marvell/a38x/ obj-$(CONFIG_ARMADA_XP) += ddr/marvell/axp/ -obj-$(CONFIG_$(XPL_)ALTERA_SDRAM) += ddr/altera/ +obj-$(CONFIG_$(PHASE_)ALTERA_SDRAM) += ddr/altera/ obj-$(CONFIG_ARCH_IMX8M) += ddr/imx/imx8m/ obj-$(CONFIG_IMX8ULP_DRAM) += ddr/imx/imx8ulp/ obj-$(CONFIG_ARCH_IMX9) += ddr/imx/imx9/
drivers/ata/Makefile +1 -1
@@ -5,7 +5,7 @@ obj-$(CONFIG_DWC_AHCI) += dwc_ahci.o obj-$(CONFIG_AHCI) += ahci-uclass.o -obj-$(CONFIG_$(XPL_)AHCI_PCI) += ahci-pci.o +obj-$(CONFIG_$(PHASE_)AHCI_PCI) += ahci-pci.o obj-$(CONFIG_SCSI_AHCI) += ahci.o obj-$(CONFIG_DWC_AHSATA) += dwc_ahsata.o obj-$(CONFIG_FSL_SATA) += fsl_sata.o
drivers/block/Makefile +1 -1
@@ -5,7 +5,7 @@ obj-$(CONFIG_$(PHASE_)BLK) += blk-uclass.o -ifndef CONFIG_$(XPL_)BLK +ifndef CONFIG_$(PHASE_)BLK obj-$(CONFIG_SPL_LEGACY_BLOCK) += blk_legacy.o endif
drivers/bus/Makefile +1 -1
@@ -8,4 +8,4 @@ obj-$(CONFIG_TI_PWMSS) += ti-pwmss.o obj-$(CONFIG_UNIPHIER_SYSTEM_BUS) += uniphier-system-bus.o endif -obj-$(CONFIG_$(XPL_)TI_SYSC) += ti-sysc.o +obj-$(CONFIG_$(PHASE_)TI_SYSC) += ti-sysc.o
drivers/core/Makefile +3 -3
@@ -6,16 +6,16 @@ obj-y += device.o fdtaddr.o lists.o root.o uclass.o util.o tag.o obj-$(CONFIG_$(PHASE_)ACPIGEN) += acpi.o obj-$(CONFIG_$(PHASE_)DEVRES) += devres.o obj-$(CONFIG_$(PHASE_)DM_DEVICE_REMOVE) += device-remove.o -obj-$(CONFIG_$(XPL_)SIMPLE_BUS) += simple-bus.o +obj-$(CONFIG_$(PHASE_)SIMPLE_BUS) += simple-bus.o obj-$(CONFIG_SIMPLE_PM_BUS) += simple-pm-bus.o obj-$(CONFIG_DM) += dump.o obj-$(CONFIG_$(PHASE_)REGMAP) += regmap.o obj-$(CONFIG_$(PHASE_)SYSCON) += syscon-uclass.o -obj-$(CONFIG_$(XPL_)OF_LIVE) += of_access.o of_addr.o +obj-$(CONFIG_$(PHASE_)OF_LIVE) += of_access.o of_addr.o ifndef CONFIG_DM_DEV_READ_INLINE obj-$(CONFIG_OF_CONTROL) += read.o endif -obj-$(CONFIG_$(XPL_)OF_PLATDATA) += read.o +obj-$(CONFIG_$(PHASE_)OF_PLATDATA) += read.o obj-$(CONFIG_OF_CONTROL) += of_extra.o ofnode.o read_extra.o ofnode_graph.o ccflags-$(CONFIG_DM_DEBUG) += -DDEBUG
drivers/ddr/altera/Makefile +1 -1
@@ -6,7 +6,7 @@ # (C) Copyright 2010, Thomas Chou <[email protected]> # Copyright (C) 2014-2025 Altera Corporation <www.altera.com> -ifdef CONFIG_$(XPL_)ALTERA_SDRAM +ifdef CONFIG_$(PHASE_)ALTERA_SDRAM obj-$(CONFIG_TARGET_SOCFPGA_GEN5) += sdram_gen5.o sequencer.o obj-$(CONFIG_TARGET_SOCFPGA_ARRIA10) += sdram_arria10.o obj-$(CONFIG_TARGET_SOCFPGA_STRATIX10) += sdram_soc64.o sdram_s10.o
drivers/dfu/Makefile +9 -9
@@ -3,12 +3,12 @@ # Copyright (C) 2012 Samsung Electronics # Lukasz Majewski <[email protected]> -obj-$(CONFIG_$(XPL_)DFU) += dfu.o -obj-$(CONFIG_$(XPL_)DFU_MMC) += dfu_mmc.o -obj-$(CONFIG_$(XPL_)DFU_MTD) += dfu_mtd.o -obj-$(CONFIG_$(XPL_)DFU_NAND) += dfu_nand.o -obj-$(CONFIG_$(XPL_)DFU_RAM) += dfu_ram.o -obj-$(CONFIG_$(XPL_)DFU_SF) += dfu_sf.o -obj-$(CONFIG_$(XPL_)DFU_WRITE_ALT) += dfu_alt.o -obj-$(CONFIG_$(XPL_)DFU_VIRT) += dfu_virt.o -obj-$(CONFIG_$(XPL_)DFU_SCSI) += dfu_scsi.o +obj-$(CONFIG_$(PHASE_)DFU) += dfu.o +obj-$(CONFIG_$(PHASE_)DFU_MMC) += dfu_mmc.o +obj-$(CONFIG_$(PHASE_)DFU_MTD) += dfu_mtd.o +obj-$(CONFIG_$(PHASE_)DFU_NAND) += dfu_nand.o +obj-$(CONFIG_$(PHASE_)DFU_RAM) += dfu_ram.o +obj-$(CONFIG_$(PHASE_)DFU_SF) += dfu_sf.o +obj-$(CONFIG_$(PHASE_)DFU_WRITE_ALT) += dfu_alt.o +obj-$(CONFIG_$(PHASE_)DFU_VIRT) += dfu_virt.o +obj-$(CONFIG_$(PHASE_)DFU_SCSI) += dfu_scsi.o
drivers/firmware/Makefile +1 -1
@@ -1,5 +1,5 @@ obj-$(CONFIG_FIRMWARE) += firmware-uclass.o -obj-$(CONFIG_$(XPL_)ARM_PSCI_FW) += psci.o +obj-$(CONFIG_$(PHASE_)ARM_PSCI_FW) += psci.o obj-$(CONFIG_TI_SCI_PROTOCOL) += ti_sci.o obj-$(CONFIG_SANDBOX) += firmware-sandbox.o obj-$(CONFIG_ZYNQMP_FIRMWARE) += firmware-zynqmp.o
drivers/gpio/Makefile +5 -5
@@ -10,7 +10,7 @@ obj-$(CONFIG_DM_74X164) += 74x164_gpio.o endif obj-$(CONFIG_$(PHASE_)DM_GPIO) += gpio-uclass.o -obj-$(CONFIG_$(XPL_)DM_PCA953X) += pca953x_gpio.o +obj-$(CONFIG_$(PHASE_)DM_PCA953X) += pca953x_gpio.o obj-$(CONFIG_ADI_GPIO) += gpio-adi-adsp.o obj-$(CONFIG_ASPEED_GPIO) += gpio-aspeed.o
@@ -59,12 +59,12 @@ obj-$(CONFIG_VYBRID_GPIO) += vybrid_gpio.o obj-$(CONFIG_HIKEY_GPIO) += hi6220_gpio.o obj-$(CONFIG_HSDK_CREG_GPIO) += hsdk-creg-gpio.o obj-$(CONFIG_IMX_RGPIO2P) += imx_rgpio2p.o -obj-$(CONFIG_$(XPL_)PALMAS_GPIO) += palmas_gpio.o +obj-$(CONFIG_$(PHASE_)PALMAS_GPIO) += palmas_gpio.o obj-$(CONFIG_PIC32_GPIO) += pic32_gpio.o obj-$(CONFIG_OCTEON_GPIO) += octeon_gpio.o obj-$(CONFIG_MVEBU_GPIO) += mvebu_gpio.o obj-$(CONFIG_MSM_GPIO) += msm_gpio.o -obj-$(CONFIG_$(XPL_)PCF8575_GPIO) += pcf8575_gpio.o +obj-$(CONFIG_$(PHASE_)PCF8575_GPIO) += pcf8575_gpio.o obj-$(CONFIG_$(PHASE_)QCOM_PMIC_GPIO) += qcom_pmic_gpio.o obj-$(CONFIG_MT7620_GPIO) += mt7620_gpio.o obj-$(CONFIG_MT7621_GPIO) += mt7621_gpio.o
@@ -73,11 +73,11 @@ obj-$(CONFIG_NX_GPIO) += nx_gpio.o obj-$(CONFIG_SIFIVE_GPIO) += sifive-gpio.o obj-$(CONFIG_NOMADIK_GPIO) += nmk_gpio.o obj-$(CONFIG_MAX7320_GPIO) += max7320_gpio.o -obj-$(CONFIG_$(XPL_)MAX77663_GPIO) += max77663_gpio.o +obj-$(CONFIG_$(PHASE_)MAX77663_GPIO) += max77663_gpio.o obj-$(CONFIG_SL28CPLD_GPIO) += sl28cpld-gpio.o obj-$(CONFIG_ADP5588_GPIO) += adp5588_gpio.o obj-$(CONFIG_ZYNQMP_GPIO_MODEPIN) += zynqmp_gpio_modepin.o obj-$(CONFIG_SLG7XL45106_I2C_GPO) += gpio_slg7xl45106.o obj-$(CONFIG_FTGPIO010) += ftgpio010.o -obj-$(CONFIG_$(SPL_)ADP5585_GPIO) += adp5585_gpio.o +obj-$(CONFIG_$(PHASE_)ADP5585_GPIO) += adp5585_gpio.o obj-$(CONFIG_RZG2L_GPIO) += rzg2l-gpio.o
drivers/i2c/Makefile +8 -8
@@ -2,15 +2,15 @@ # # (C) Copyright 2000-2007 # Wolfgang Denk, DENX Software Engineering, [email protected]. -obj-$(CONFIG_$(XPL_)DM_I2C) += i2c-uclass.o -ifdef CONFIG_$(XPL_)ACPIGEN -obj-$(CONFIG_$(XPL_)DM_I2C) += acpi_i2c.o +obj-$(CONFIG_$(PHASE_)DM_I2C) += i2c-uclass.o +ifdef CONFIG_$(PHASE_)ACPIGEN +obj-$(CONFIG_$(PHASE_)DM_I2C) += acpi_i2c.o endif -obj-$(CONFIG_$(XPL_)DM_I2C_GPIO) += i2c-gpio.o -obj-$(CONFIG_$(XPL_)I2C_CROS_EC_TUNNEL) += cros_ec_tunnel.o -obj-$(CONFIG_$(XPL_)I2C_CROS_EC_LDO) += cros_ec_ldo.o +obj-$(CONFIG_$(PHASE_)DM_I2C_GPIO) += i2c-gpio.o +obj-$(CONFIG_$(PHASE_)I2C_CROS_EC_TUNNEL) += cros_ec_tunnel.o +obj-$(CONFIG_$(PHASE_)I2C_CROS_EC_LDO) += cros_ec_ldo.o -obj-$(CONFIG_$(XPL_)SYS_I2C_LEGACY) += i2c_core.o +obj-$(CONFIG_$(PHASE_)SYS_I2C_LEGACY) += i2c_core.o obj-$(CONFIG_SYS_I2C_ADI) += adi_i2c.o obj-$(CONFIG_SYS_I2C_ASPEED) += ast_i2c.o obj-$(CONFIG_SYS_I2C_AST2600) += ast2600_i2c.o
@@ -58,4 +58,4 @@ obj-$(CONFIG_SYS_I2C_VERSATILE) += i2c-versatile.o obj-$(CONFIG_SYS_I2C_XILINX_XIIC) += xilinx_xiic.o obj-$(CONFIG_TEGRA186_BPMP_I2C) += tegra186_bpmp_i2c.o -obj-$(CONFIG_$(XPL_)I2C_MUX) += muxes/ +obj-$(CONFIG_$(PHASE_)I2C_MUX) += muxes/
drivers/led/Makefile +1 -1
@@ -10,6 +10,6 @@ obj-$(CONFIG_LED_BCM6358) += led_bcm6358.o obj-$(CONFIG_LED_BCM6753) += led_bcm6753.o obj-$(CONFIG_LED_BCM6858) += led_bcm6858.o obj-$(CONFIG_LED_PWM) += led_pwm.o -obj-$(CONFIG_$(XPL_)LED_GPIO) += led_gpio.o +obj-$(CONFIG_$(PHASE_)LED_GPIO) += led_gpio.o obj-$(CONFIG_LED_CORTINA) += led_cortina.o obj-$(CONFIG_LED_LP5562) += led_lp5562.o
drivers/mailbox/Makefile +1 -1
@@ -3,7 +3,7 @@ # Copyright (c) 2016, NVIDIA CORPORATION. # -obj-$(CONFIG_$(XPL_)DM_MAILBOX) += mailbox-uclass.o +obj-$(CONFIG_$(PHASE_)DM_MAILBOX) += mailbox-uclass.o obj-$(CONFIG_APPLE_MBOX) += apple-mbox.o obj-$(CONFIG_IMX_MU_MBOX) += imx-mailbox.o obj-$(CONFIG_SANDBOX_MBOX) += sandbox-mbox.o
drivers/misc/Makefile +5 -5
@@ -18,7 +18,7 @@ obj-$(CONFIG_SANDBOX) += p2sb_sandbox.o p2sb_emul.o obj-$(CONFIG_SANDBOX) += swap_case.o endif -ifdef CONFIG_$(XPL_)DM_I2C +ifdef CONFIG_$(PHASE_)DM_I2C ifndef CONFIG_XPL_BUILD obj-$(CONFIG_SANDBOX) += i2c_eeprom_emul.o obj-$(CONFIG_USB_HUB_USB251XB) += usb251xb.o
@@ -37,14 +37,14 @@ obj-$(CONFIG_FSL_DEVICE_DISABLE) += fsl_devdis.o obj-$(CONFIG_FSL_IFC) += fsl_ifc.o obj-$(CONFIG_FSL_IIM) += fsl_iim.o obj-$(CONFIG_FSL_SEC_MON) += fsl_sec_mon.o -obj-$(CONFIG_$(XPL_)FS_LOADER) += fs_loader.o +obj-$(CONFIG_$(PHASE_)FS_LOADER) += fs_loader.o obj-$(CONFIG_GATEWORKS_SC) += gsc.o obj-$(CONFIG_GDSYS_IOEP) += gdsys_ioep.o obj-$(CONFIG_GDSYS_RXAUI_CTRL) += gdsys_rxaui_ctrl.o obj-$(CONFIG_GDSYS_SOC) += gdsys_soc.o obj-$(CONFIG_IRQ) += irq-uclass.o obj-$(CONFIG_SANDBOX) += irq_sandbox.o irq_sandbox_test.o -obj-$(CONFIG_$(XPL_)I2C_EEPROM) += i2c_eeprom.o +obj-$(CONFIG_$(PHASE_)I2C_EEPROM) += i2c_eeprom.o obj-$(CONFIG_IHS_FPGA) += ihs_fpga.o obj-$(CONFIG_IMX8) += imx8/ obj-$(CONFIG_IMX_ELE) += imx_ele/
@@ -52,14 +52,14 @@ obj-$(CONFIG_LED_STATUS) += status_led.o obj-$(CONFIG_LED_STATUS_GPIO) += gpio_led.o obj-$(CONFIG_MPC83XX_SERDES) += mpc83xx_serdes.o obj-$(CONFIG_$(PHASE_)LS2_SFP) += ls2_sfp.o -obj-$(CONFIG_$(XPL_)MXC_OCOTP) += mxc_ocotp.o +obj-$(CONFIG_$(PHASE_)MXC_OCOTP) += mxc_ocotp.o obj-$(CONFIG_MXS_OCOTP) += mxs_ocotp.o obj-$(CONFIG_NPCM_OTP) += npcm_otp.o obj-$(CONFIG_NPCM_HOST) += npcm_host_intf.o obj-$(CONFIG_NUVOTON_NCT6102D) += nuvoton_nct6102d.o obj-$(CONFIG_P2SB) += p2sb-uclass.o obj-$(CONFIG_PCA9551_LED) += pca9551_led.o -obj-$(CONFIG_$(XPL_)PWRSEQ) += pwrseq-uclass.o +obj-$(CONFIG_$(PHASE_)PWRSEQ) += pwrseq-uclass.o ifdef CONFIG_QFW obj-y += qfw.o obj-$(CONFIG_QFW_ACPI) += qfw_acpi.o
drivers/mmc/Makefile +3 -3
@@ -4,17 +4,17 @@ # Wolfgang Denk, DENX Software Engineering, [email protected]. obj-y += mmc.o -obj-$(CONFIG_$(XPL_)DM_MMC) += mmc-uclass.o +obj-$(CONFIG_$(PHASE_)DM_MMC) += mmc-uclass.o ifdef CONFIG_$(PHASE_)DM_MMC obj-$(CONFIG_$(PHASE_)BOOTSTD) += mmc_bootdev.o endif obj-$(CONFIG_$(PHASE_)MMC_WRITE) += mmc_write.o -obj-$(CONFIG_$(XPL_)MMC_PWRSEQ) += mmc-pwrseq.o +obj-$(CONFIG_$(PHASE_)MMC_PWRSEQ) += mmc-pwrseq.o obj-$(CONFIG_MMC_SDHCI_ADMA_HELPERS) += sdhci-adma.o -ifndef CONFIG_$(XPL_)BLK +ifndef CONFIG_$(PHASE_)BLK obj-y += mmc_legacy.o endif
drivers/mux/Makefile +1 -1
@@ -4,4 +4,4 @@ # Jean-Jacques Hiblot <[email protected]> obj-$(CONFIG_MULTIPLEXER) += mux-uclass.o -obj-$(CONFIG_$(XPL_)MUX_MMIO) += mmio.o +obj-$(CONFIG_$(PHASE_)MUX_MMIO) += mmio.o
drivers/nvme/Makefile +1 -1
@@ -4,4 +4,4 @@ obj-y += nvme-uclass.o nvme.o nvme_show.o obj-$(CONFIG_NVME_APPLE) += nvme_apple.o -obj-$(CONFIG_$(XPL_)NVME_PCI) += nvme_pci.o +obj-$(CONFIG_$(PHASE_)NVME_PCI) += nvme_pci.o
drivers/phy/Makefile +3 -3
@@ -8,8 +8,8 @@ obj-y += marvell/ obj-y += rockchip/ obj-y += socionext/ -obj-$(CONFIG_$(XPL_)PHY) += phy-uclass.o -obj-$(CONFIG_$(XPL_)NOP_PHY) += nop-phy.o +obj-$(CONFIG_$(PHASE_)PHY) += phy-uclass.o +obj-$(CONFIG_$(PHASE_)NOP_PHY) += nop-phy.o obj-$(CONFIG_MIPI_DPHY_HELPERS) += phy-core-mipi-dphy.o obj-$(CONFIG_AB8500_USB_PHY) += phy-ab8500-usb.o obj-$(CONFIG_APPLE_ATCPHY) += phy-apple-atc.o
@@ -19,7 +19,7 @@ obj-$(CONFIG_BCM6358_USBH_PHY) += bcm6358-usbh-phy.o obj-$(CONFIG_BCM6368_USBH_PHY) += bcm6368-usbh-phy.o obj-$(CONFIG_BCM_SR_PCIE_PHY) += phy-bcm-sr-pcie.o obj-$(CONFIG_PHY_SANDBOX) += sandbox-phy.o -obj-$(CONFIG_$(XPL_)PIPE3_PHY) += ti-pipe3-phy.o +obj-$(CONFIG_$(PHASE_)PIPE3_PHY) += ti-pipe3-phy.o obj-$(CONFIG_AM654_PHY) += phy-ti-am654.o obj-$(CONFIG_STI_USB_PHY) += sti_usb_phy.o obj-$(CONFIG_PHY_RCAR_GEN2) += phy-rcar-gen2.o
drivers/phy/cadence/Makefile +2 -2
@@ -1,2 +1,2 @@ -obj-$(CONFIG_$(XPL_)PHY_CADENCE_SIERRA) += phy-cadence-sierra.o -obj-$(CONFIG_$(XPL_)PHY_CADENCE_TORRENT) += phy-cadence-torrent.o +obj-$(CONFIG_$(PHASE_)PHY_CADENCE_SIERRA) += phy-cadence-sierra.o +obj-$(CONFIG_$(PHASE_)PHY_CADENCE_TORRENT) += phy-cadence-torrent.o
drivers/phy/ti/Makefile +1 -1
@@ -1 +1 @@ -obj-$(CONFIG_$(XPL_)PHY_J721E_WIZ) += phy-j721e-wiz.o +obj-$(CONFIG_$(PHASE_)PHY_J721E_WIZ) += phy-j721e-wiz.o
drivers/pinctrl/Makefile +4 -4
@@ -1,14 +1,14 @@ # SPDX-License-Identifier: GPL-2.0+ obj-y += pinctrl-uclass.o -obj-$(CONFIG_$(XPL_)PINCTRL_GENERIC) += pinctrl-generic.o +obj-$(CONFIG_$(PHASE_)PINCTRL_GENERIC) += pinctrl-generic.o obj-$(CONFIG_PINCTRL_ADI) += pinctrl-adi-adsp.o obj-$(CONFIG_PINCTRL_APPLE) += pinctrl-apple.o obj-$(CONFIG_PINCTRL_AT91) += pinctrl-at91.o obj-$(CONFIG_PINCTRL_AT91PIO4) += pinctrl-at91-pio4.o obj-y += nxp/ -obj-$(CONFIG_$(XPL_)PINCTRL_ROCKCHIP) += rockchip/ +obj-$(CONFIG_$(PHASE_)PINCTRL_ROCKCHIP) += rockchip/ obj-$(CONFIG_ARCH_ASPEED) += aspeed/ obj-$(CONFIG_ARCH_ATH79) += ath79/ obj-$(CONFIG_PINCTRL_INTEL) += intel/
@@ -18,7 +18,7 @@ obj-$(CONFIG_PINCTRL_QCOM) += qcom/ obj-$(CONFIG_ARCH_RENESAS) += renesas/ obj-$(CONFIG_PINCTRL_SANDBOX) += pinctrl-sandbox.o obj-$(CONFIG_PINCTRL_SUNXI) += sunxi/ -obj-$(CONFIG_$(XPL_)PINCTRL_TEGRA) += tegra/ +obj-$(CONFIG_$(PHASE_)PINCTRL_TEGRA) += tegra/ obj-$(CONFIG_PINCTRL_UNIPHIER) += uniphier/ obj-$(CONFIG_PINCTRL_PIC32) += pinctrl_pic32.o obj-$(CONFIG_PINCTRL_EXYNOS) += exynos/
@@ -32,7 +32,7 @@ obj-$(CONFIG_PINCTRL_QE) += pinctrl-qe-io.o obj-$(CONFIG_PINCTRL_SINGLE) += pinctrl-single.o obj-$(CONFIG_PINCTRL_STI) += pinctrl-sti.o obj-$(CONFIG_PINCTRL_STM32) += pinctrl_stm32.o -obj-$(CONFIG_$(XPL_)PINCTRL_STMFX) += pinctrl-stmfx.o +obj-$(CONFIG_$(PHASE_)PINCTRL_STMFX) += pinctrl-stmfx.o obj-y += broadcom/ obj-$(CONFIG_PINCTRL_ZYNQMP) += pinctrl-zynqmp.o obj-$(CONFIG_PINCTRL_STARFIVE) += starfive/
drivers/power/domain/Makefile +1 -1
@@ -3,7 +3,7 @@ # Copyright (c) 2016, NVIDIA CORPORATION. # -obj-$(CONFIG_$(XPL_)POWER_DOMAIN) += power-domain-uclass.o +obj-$(CONFIG_$(PHASE_)POWER_DOMAIN) += power-domain-uclass.o obj-$(CONFIG_APPLE_PMGR_POWER_DOMAIN) += apple-pmgr.o obj-$(CONFIG_BCM6328_POWER_DOMAIN) += bcm6328-power-domain.o obj-$(CONFIG_IMX8_POWER_DOMAIN) += imx8-power-domain-legacy.o imx8-power-domain.o
drivers/power/pmic/Makefile +15 -15
@@ -4,33 +4,33 @@ # Lukasz Majewski <[email protected]> obj-$(CONFIG_$(PHASE_)DM_PMIC) += pmic-uclass.o -obj-$(CONFIG_$(XPL_)DM_PMIC_FAN53555) += fan53555.o -obj-$(CONFIG_$(XPL_)DM_PMIC_DA9063) += da9063.o -obj-$(CONFIG_$(XPL_)DM_PMIC_MAX77663) += max77663.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_FAN53555) += fan53555.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_DA9063) += da9063.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_MAX77663) += max77663.o obj-$(CONFIG_DM_PMIC_MAX77686) += max77686.o obj-$(CONFIG_DM_PMIC_MAX8998) += max8998.o obj-$(CONFIG_DM_PMIC_MC34708) += mc34708.o -obj-$(CONFIG_$(XPL_)DM_PMIC_BD71837) += bd71837.o -obj-$(CONFIG_$(XPL_)DM_PMIC_MP5416) += mp5416.o -obj-$(CONFIG_$(XPL_)DM_PMIC_PFUZE100) += pfuze100.o -obj-$(CONFIG_$(XPL_)DM_PMIC_PCA9450) += pca9450.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_BD71837) += bd71837.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_MP5416) += mp5416.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_PFUZE100) += pfuze100.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_PCA9450) += pca9450.o obj-$(CONFIG_PMIC_S2MPS11) += s2mps11.o obj-$(CONFIG_DM_PMIC_SANDBOX) += sandbox.o i2c_pmic_emul.o obj-$(CONFIG_PMIC_AB8500) += ab8500.o obj-$(CONFIG_PMIC_ACT8846) += act8846.o obj-$(CONFIG_PMIC_AS3722) += as3722.o as3722_gpio.o -obj-$(CONFIG_$(XPL_)PMIC_AXP) += axp.o +obj-$(CONFIG_$(PHASE_)PMIC_AXP) += axp.o obj-$(CONFIG_PMIC_MAX8997) += max8997.o obj-$(CONFIG_PMIC_QCOM) += pmic_qcom.o obj-$(CONFIG_$(PHASE_)PMIC_RK8XX) += rk8xx.o -obj-$(CONFIG_$(XPL_)PMIC_RN5T567) += rn5t567.o +obj-$(CONFIG_$(PHASE_)PMIC_RN5T567) += rn5t567.o obj-$(CONFIG_PMIC_TPS65090) += tps65090.o obj-$(CONFIG_PMIC_S5M8767) += s5m8767.o obj-$(CONFIG_DM_PMIC_TPS65910) += pmic_tps65910_dm.o -obj-$(CONFIG_$(XPL_)DM_PMIC_TPS80031) += tps80031.o -obj-$(CONFIG_$(XPL_)PMIC_PALMAS) += palmas.o -obj-$(CONFIG_$(XPL_)PMIC_LP873X) += lp873x.o -obj-$(CONFIG_$(XPL_)PMIC_LP87565) += lp87565.o +obj-$(CONFIG_$(PHASE_)DM_PMIC_TPS80031) += tps80031.o +obj-$(CONFIG_$(PHASE_)PMIC_PALMAS) += palmas.o +obj-$(CONFIG_$(PHASE_)PMIC_LP873X) += lp873x.o +obj-$(CONFIG_$(PHASE_)PMIC_LP87565) += lp87565.o obj-$(CONFIG_PMIC_STPMIC1) += stpmic1.o obj-$(CONFIG_PMIC_TPS65217) += pmic_tps65217.o obj-$(CONFIG_PMIC_TPS65219) += tps65219.o
@@ -38,7 +38,7 @@ obj-$(CONFIG_PMIC_TPS65941) += tps65941.o obj-$(CONFIG_PMIC_RAA215300) += raa215300.o obj-$(CONFIG_POWER_TPS65218) += pmic_tps65218.o -ifeq ($(CONFIG_$(XPL_)POWER_LEGACY),y) +ifeq ($(CONFIG_$(PHASE_)POWER_LEGACY),y) obj-$(CONFIG_POWER_LTC3676) += pmic_ltc3676.o obj-$(CONFIG_POWER_PCA9450) += pmic_pca9450.o obj-$(CONFIG_POWER_PFUZE100) += pmic_pfuze100.o
@@ -47,5 +47,5 @@ obj-$(CONFIG_POWER_HI6553) += pmic_hi6553.o obj-$(CONFIG_POWER_MC34VR500) += pmic_mc34vr500.o endif -obj-$(CONFIG_$(XPL_)POWER_TPS62362) += pmic_tps62362.o +obj-$(CONFIG_$(PHASE_)POWER_TPS62362) += pmic_tps62362.o obj-$(CONFIG_SPL_POWER_TPS65910) += pmic_tps65910.o
drivers/power/regulator/Makefile +23 -23
65 lines not on this page · raw message
drivers/remoteproc/Makefile +1 -1
@@ -4,7 +4,7 @@ # Texas Instruments Incorporated - https://www.ti.com/ # -obj-$(CONFIG_$(XPL_)REMOTEPROC) += rproc-uclass.o rproc-elf-loader.o +obj-$(CONFIG_$(PHASE_)REMOTEPROC) += rproc-uclass.o rproc-elf-loader.o # Remote proc drivers - Please keep this list alphabetically sorted. obj-$(CONFIG_K3_SYSTEM_CONTROLLER) += k3_system_controller.o
drivers/serial/Makefile +1 -1
@@ -11,7 +11,7 @@ endif obj-$(CONFIG_PL01X_SERIAL) += serial_pl01x.o obj-$(CONFIG_PL011_SERIAL) += serial_pl01x.o -obj-$(CONFIG_$(XPL_)SYS_NS16550_SERIAL) += serial_ns16550.o +obj-$(CONFIG_$(PHASE_)SYS_NS16550_SERIAL) += serial_ns16550.o obj-$(CONFIG_ALTERA_UART) += altera_uart.o obj-$(CONFIG_ALTERA_JTAG_UART) += altera_jtag_uart.o
drivers/timer/Makefile +4 -4
@@ -5,14 +5,14 @@ obj-y += timer-uclass.o obj-$(CONFIG_ADI_SC5XX_TIMER) += adi_sc5xx_timer.o obj-$(CONFIG_ALTERA_TIMER) += altera_timer.o -obj-$(CONFIG_$(XPL_)ANDES_PLMT_TIMER) += andes_plmt_timer.o +obj-$(CONFIG_$(PHASE_)ANDES_PLMT_TIMER) += andes_plmt_timer.o obj-$(CONFIG_ARC_TIMER) += arc_timer.o obj-$(CONFIG_ARM_TWD_TIMER) += arm_twd_timer.o obj-$(CONFIG_AST_TIMER) += ast_timer.o obj-$(CONFIG_AST_IBEX_TIMER) += ast_ibex_timer.o obj-$(CONFIG_ATCPIT100_TIMER) += atcpit100_timer.o -obj-$(CONFIG_$(XPL_)ATMEL_PIT_TIMER) += atmel_pit_timer.o -obj-$(CONFIG_$(XPL_)ATMEL_TCB_TIMER) += atmel_tcb_timer.o +obj-$(CONFIG_$(PHASE_)ATMEL_PIT_TIMER) += atmel_pit_timer.o +obj-$(CONFIG_$(PHASE_)ATMEL_TCB_TIMER) += atmel_tcb_timer.o obj-$(CONFIG_CADENCE_TTC_TIMER) += cadence-ttc.o obj-$(CONFIG_DESIGNWARE_APB_TIMER) += dw-apb-timer.o obj-$(CONFIG_FTTMR010_TIMER) += fttmr010_timer.o
@@ -27,7 +27,7 @@ obj-$(CONFIG_RISCV_TIMER) += riscv_timer.o obj-$(CONFIG_ROCKCHIP_TIMER) += rockchip_timer.o obj-$(CONFIG_SANDBOX_TIMER) += sandbox_timer.o obj-$(CONFIG_SP804_TIMER) += sp804_timer.o -obj-$(CONFIG_$(XPL_)RISCV_ACLINT) += riscv_aclint_timer.o +obj-$(CONFIG_$(PHASE_)RISCV_ACLINT) += riscv_aclint_timer.o obj-$(CONFIG_ARM_GLOBAL_TIMER) += arm_global_timer.o obj-$(CONFIG_STM32_TIMER) += stm32_timer.o obj-$(CONFIG_TEGRA_TIMER) += tegra-timer.o
drivers/usb/cdns3/Makefile +2 -2
@@ -4,9 +4,9 @@ cdns3-y := core.o drd.o obj-$(CONFIG_USB_CDNS3) += cdns3.o -cdns3-$(CONFIG_$(XPL_)USB_CDNS3_GADGET) += gadget.o ep0.o +cdns3-$(CONFIG_$(PHASE_)USB_CDNS3_GADGET) += gadget.o ep0.o -cdns3-$(CONFIG_$(XPL_)USB_CDNS3_HOST) += host.o +cdns3-$(CONFIG_$(PHASE_)USB_CDNS3_HOST) += host.o obj-$(CONFIG_USB_CDNS3_STARFIVE) += cdns3-starfive.o obj-$(CONFIG_USB_CDNS3_TI) += cdns3-ti.o
drivers/usb/common/Makefile +1 -1
@@ -3,7 +3,7 @@ # (C) Copyright 2016 Freescale Semiconductor, Inc. # -obj-$(CONFIG_$(XPL_)DM_USB) += common.o +obj-$(CONFIG_$(PHASE_)DM_USB) += common.o obj-$(CONFIG_USB_ISP1760) += usb_urb.o obj-$(CONFIG_USB_MUSB_HOST) += usb_urb.o obj-$(CONFIG_USB_MUSB_GADGET) += usb_urb.o
drivers/usb/dwc3/Makefile +2 -2
@@ -6,11 +6,11 @@ dwc3-y := core.o obj-$(CONFIG_USB_DWC3_GADGET) += gadget.o ep0.o -obj-$(CONFIG_$(XPL_)USB_DWC3_AM62) += dwc3-am62.o +obj-$(CONFIG_$(PHASE_)USB_DWC3_AM62) += dwc3-am62.o obj-$(CONFIG_USB_DWC3_OMAP) += dwc3-omap.o obj-$(CONFIG_USB_DWC3_MESON_G12A) += dwc3-meson-g12a.o obj-$(CONFIG_USB_DWC3_MESON_GXL) += dwc3-meson-gxl.o -obj-$(CONFIG_$(XPL_)USB_DWC3_GENERIC) += dwc3-generic.o +obj-$(CONFIG_$(PHASE_)USB_DWC3_GENERIC) += dwc3-generic.o obj-$(CONFIG_USB_DWC3_UNIPHIER) += dwc3-uniphier.o obj-$(CONFIG_USB_DWC3_LAYERSCAPE) += dwc3-layerscape.o obj-$(CONFIG_USB_DWC3_PHY_OMAP) += ti_usb_phy.o
drivers/usb/gadget/udc/Makefile +2 -2
@@ -2,9 +2,9 @@ # # USB peripheral controller drivers -ifndef CONFIG_$(XPL_)DM_USB_GADGET +ifndef CONFIG_$(PHASE_)DM_USB_GADGET obj-$(CONFIG_USB_DWC3_GADGET) += udc-core.o endif -obj-$(CONFIG_$(XPL_)DM_USB_GADGET) += udc-core.o +obj-$(CONFIG_$(PHASE_)DM_USB_GADGET) += udc-core.o obj-y += udc-uclass.o
drivers/usb/host/Makefile +1 -1
@@ -3,7 +3,7 @@ # (C) Copyright 2000-2007 # Wolfgang Denk, DENX Software Engineering, [email protected]. -ifdef CONFIG_$(XPL_)DM_USB +ifdef CONFIG_$(PHASE_)DM_USB obj-y += usb-uclass.o obj-$(CONFIG_SANDBOX) += usb-sandbox.o endif
drivers/video/Makefile +1 -1
@@ -35,7 +35,7 @@ obj-${CONFIG_EXYNOS_FB} += exynos/ obj-${CONFIG_VIDEO_ROCKCHIP} += rockchip/ obj-${CONFIG_VIDEO_STM32} += stm32/ obj-${CONFIG_VIDEO_TEGRA124} += tegra124/ -obj-${CONFIG_$(XPL_)VIDEO_TIDSS} += tidss/ +obj-${CONFIG_$(PHASE_)VIDEO_TIDSS} += tidss/ obj-y += ti/ obj-$(CONFIG_ATMEL_HLCD) += atmel_hlcdfb.o
drivers/video/tidss/Makefile +1 -1
@@ -9,4 +9,4 @@ # Author: Tomi Valkeinen <[email protected]> -obj-${CONFIG_$(XPL_)VIDEO_TIDSS} = tidss_drv.o +obj-${CONFIG_$(PHASE_)VIDEO_TIDSS} = tidss_drv.o
fs/fat/Makefile +2 -2
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0+ # -obj-$(CONFIG_$(XPL_)FS_FAT) = fat.o -obj-$(CONFIG_$(XPL_)FAT_WRITE) = fat_write.o +obj-$(CONFIG_$(PHASE_)FS_FAT) = fat.o +obj-$(CONFIG_$(PHASE_)FAT_WRITE) = fat_write.o
fs/squashfs/Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0+ # -obj-$(CONFIG_$(XPL_)FS_SQUASHFS) = sqfs.o \ +obj-$(CONFIG_$(PHASE_)FS_SQUASHFS) = sqfs.o \ sqfs_inode.o \ sqfs_dir.o \ sqfs_decompressor.o
lib/Makefile +5 -5
@@ -71,7 +71,7 @@ obj-y += crypto/ obj-$(CONFIG_$(PHASE_)ACPI) += acpi/ obj-$(CONFIG_ECDSA) += ecdsa/ -obj-$(CONFIG_$(XPL_)RSA) += rsa/ +obj-$(CONFIG_$(PHASE_)RSA) += rsa/ obj-$(CONFIG_HASH) += hash-checksum.o obj-$(CONFIG_BLAKE2) += blake2/blake2b.o
@@ -82,7 +82,7 @@ obj-$(CONFIG_$(PHASE_)SHA256_LEGACY) += sha256.o obj-$(CONFIG_$(PHASE_)SHA512_LEGACY) += sha512.o obj-$(CONFIG_CRYPT_PW) += crypt/ -obj-$(CONFIG_$(XPL_)ASN1_DECODER_LEGACY) += asn1_decoder.o +obj-$(CONFIG_$(PHASE_)ASN1_DECODER_LEGACY) += asn1_decoder.o obj-$(CONFIG_$(PHASE_)ZLIB) += zlib/ obj-$(CONFIG_$(PHASE_)ZSTD) += zstd/
@@ -91,14 +91,14 @@ obj-$(CONFIG_$(PHASE_)LZO) += lzo/ obj-$(CONFIG_$(PHASE_)LZMA) += lzma/ obj-$(CONFIG_$(PHASE_)LZ4) += lz4_wrapper.o -obj-$(CONFIG_$(XPL_)LIB_RATIONAL) += rational.o +obj-$(CONFIG_$(PHASE_)LIB_RATIONAL) += rational.o obj-$(CONFIG_LIBAVB) += libavb/ obj-$(CONFIG_$(PHASE_)OF_LIBFDT) += libfdt/ obj-$(CONFIG_$(PHASE_)OF_REAL) += fdtdec_common.o fdtdec.o -obj-$(CONFIG_$(XPL_)MBEDTLS_LIB) += mbedtls/ +obj-$(CONFIG_$(PHASE_)MBEDTLS_LIB) += mbedtls/ obj-$(CONFIG_NET_LWIP) += lwip/
@@ -150,7 +150,7 @@ else obj-y += vsprintf.o strto.o obj-$(CONFIG_SSCANF) += sscanf.o endif -obj-$(CONFIG_$(XPL_)OID_REGISTRY) += oid_registry.o +obj-$(CONFIG_$(PHASE_)OID_REGISTRY) += oid_registry.o obj-y += abuf.o obj-y += alist.o
lib/acpi/Makefile +4 -4
@@ -5,10 +5,10 @@ obj-y += acpi.o ifdef CONFIG_$(PHASE_)GENERATE_ACPI_TABLE -obj-$(CONFIG_$(XPL_)ACPIGEN) += acpigen.o -obj-$(CONFIG_$(XPL_)ACPIGEN) += acpi_device.o -obj-$(CONFIG_$(XPL_)ACPIGEN) += acpi_dp.o -obj-$(CONFIG_$(XPL_)ACPIGEN) += acpi_table.o +obj-$(CONFIG_$(PHASE_)ACPIGEN) += acpigen.o +obj-$(CONFIG_$(PHASE_)ACPIGEN) += acpi_device.o +obj-$(CONFIG_$(PHASE_)ACPIGEN) += acpi_dp.o +obj-$(CONFIG_$(PHASE_)ACPIGEN) += acpi_table.o obj-y += acpi_writer.o # With QEMU the ACPI tables come from there, not from U-Boot
lib/aes/Makefile +1 -1
@@ -2,4 +2,4 @@ # # Copyright (c) 2019, Softathome -obj-$(CONFIG_$(XPL_)FIT_CIPHER) += aes-decrypt.o +obj-$(CONFIG_$(PHASE_)FIT_CIPHER) += aes-decrypt.o
lib/crypto/Makefile +10 -10
@@ -3,17 +3,17 @@ # Makefile for asymmetric cryptographic keys # -obj-$(CONFIG_$(XPL_)ASYMMETRIC_KEY_TYPE) += asymmetric_keys.o +obj-$(CONFIG_$(PHASE_)ASYMMETRIC_KEY_TYPE) += asymmetric_keys.o asymmetric_keys-y := asymmetric_type.o -obj-$(CONFIG_$(XPL_)ASYMMETRIC_PUBLIC_KEY_SUBTYPE) += public_key_helper.o -obj-$(CONFIG_$(XPL_)ASYMMETRIC_PUBLIC_KEY_LEGACY) += public_key.o +obj-$(CONFIG_$(PHASE_)ASYMMETRIC_PUBLIC_KEY_SUBTYPE) += public_key_helper.o +obj-$(CONFIG_$(PHASE_)ASYMMETRIC_PUBLIC_KEY_LEGACY) += public_key.o # # RSA public key parser # -obj-$(CONFIG_$(XPL_)RSA_PUBLIC_KEY_PARSER_LEGACY) += rsa_public_key.o +obj-$(CONFIG_$(PHASE_)RSA_PUBLIC_KEY_PARSER_LEGACY) += rsa_public_key.o rsa_public_key-y := \ rsapubkey.asn1.o \ rsa_helper.o
@@ -31,9 +31,9 @@ endif # # X.509 Certificate handling # -obj-$(CONFIG_$(XPL_)X509_CERTIFICATE_PARSER) += x509_key_parser.o +obj-$(CONFIG_$(PHASE_)X509_CERTIFICATE_PARSER) += x509_key_parser.o x509_key_parser-y := x509_helper.o -x509_key_parser-$(CONFIG_$(XPL_)X509_CERTIFICATE_PARSER_LEGACY) += \ +x509_key_parser-$(CONFIG_$(PHASE_)X509_CERTIFICATE_PARSER_LEGACY) += \ x509.asn1.o \ x509_akid.asn1.o \ x509_cert_parser.o \
@@ -49,21 +49,21 @@ $(obj)/x509_akid.asn1.o: $(obj)/x509_akid.asn1.c $(obj)/x509_akid.asn1.h # # PKCS#7 message handling # -obj-$(CONFIG_$(XPL_)PKCS7_MESSAGE_PARSER) += pkcs7_message.o +obj-$(CONFIG_$(PHASE_)PKCS7_MESSAGE_PARSER) += pkcs7_message.o pkcs7_message-y := pkcs7_helper.o -pkcs7_message-$(CONFIG_$(SPL_)PKCS7_MESSAGE_PARSER_LEGACY) += \ +pkcs7_message-$(CONFIG_$(PHASE_)PKCS7_MESSAGE_PARSER_LEGACY) += \ pkcs7.asn1.o \ pkcs7_parser.o $(obj)/pkcs7_parser.o: $(obj)/pkcs7.asn1.h $(obj)/pkcs7.asn1.o: $(obj)/pkcs7.asn1.c $(obj)/pkcs7.asn1.h -obj-$(CONFIG_$(XPL_)PKCS7_VERIFY) += pkcs7_verify.o +obj-$(CONFIG_$(PHASE_)PKCS7_VERIFY) += pkcs7_verify.o # # Signed PE binary-wrapped key handling # -obj-$(CONFIG_$(XPL_)MSCODE_PARSER_LEGACY) += mscode.o +obj-$(CONFIG_$(PHASE_)MSCODE_PARSER_LEGACY) += mscode.o mscode-y := \ mscode_parser.o \
lib/ecdsa/Makefile +1 -1
@@ -1 +1 @@ -obj-$(CONFIG_$(XPL_)ECDSA_VERIFY) += ecdsa-verify.o +obj-$(CONFIG_$(PHASE_)ECDSA_VERIFY) += ecdsa-verify.o
lib/lwip/Makefile +1 -1
@@ -54,5 +54,5 @@ obj-y += \ lwip/src/core/udp.o \ lwip/src/netif/ethernet.o -obj-$(CONFIG_$(XPL_)MBEDTLS_LIB_TLS) += lwip/src/apps/altcp_tls/altcp_tls_mbedtls.o \ +obj-$(CONFIG_$(PHASE_)MBEDTLS_LIB_TLS) += lwip/src/apps/altcp_tls/altcp_tls_mbedtls.o \ lwip/src/apps/altcp_tls/altcp_tls_mbedtls_mem.o
lib/mbedtls/Makefile +19 -19
@@ -6,19 +6,19 @@ MBEDTLS_LIB_DIR = external/mbedtls/library # shim layer for hash -obj-$(CONFIG_$(XPL_)MD5_MBEDTLS) += md5.o -obj-$(CONFIG_$(XPL_)SHA1_MBEDTLS) += sha1.o -obj-$(CONFIG_$(XPL_)SHA256_MBEDTLS) += sha256.o -obj-$(CONFIG_$(XPL_)SHA512_MBEDTLS) += sha512.o +obj-$(CONFIG_$(PHASE_)MD5_MBEDTLS) += md5.o +obj-$(CONFIG_$(PHASE_)SHA1_MBEDTLS) += sha1.o +obj-$(CONFIG_$(PHASE_)SHA256_MBEDTLS) += sha256.o +obj-$(CONFIG_$(PHASE_)SHA512_MBEDTLS) += sha512.o # x509 libraries -obj-$(CONFIG_$(XPL_)ASYMMETRIC_PUBLIC_KEY_MBEDTLS) += \ +obj-$(CONFIG_$(PHASE_)ASYMMETRIC_PUBLIC_KEY_MBEDTLS) += \ public_key.o -obj-$(CONFIG_$(XPL_)X509_CERTIFICATE_PARSER_MBEDTLS) += \ +obj-$(CONFIG_$(PHASE_)X509_CERTIFICATE_PARSER_MBEDTLS) += \ x509_cert_parser.o -obj-$(CONFIG_$(XPL_)PKCS7_MESSAGE_PARSER_MBEDTLS) += pkcs7_parser.o -obj-$(CONFIG_$(XPL_)MSCODE_PARSER_MBEDTLS) += mscode_parser.o -obj-$(CONFIG_$(XPL_)RSA_PUBLIC_KEY_PARSER_MBEDTLS) += rsa_helper.o +obj-$(CONFIG_$(PHASE_)PKCS7_MESSAGE_PARSER_MBEDTLS) += pkcs7_parser.o +obj-$(CONFIG_$(PHASE_)MSCODE_PARSER_MBEDTLS) += mscode_parser.o +obj-$(CONFIG_$(PHASE_)RSA_PUBLIC_KEY_PARSER_MBEDTLS) += rsa_helper.o # MbedTLS crypto library obj-$(CONFIG_$(XPL_)MBEDTLS_LIB) += mbedtls_lib_crypto.o
@@ -27,35 +27,35 @@ mbedtls_lib_crypto-y := \ $(MBEDTLS_LIB_DIR)/constant_time.o \ $(MBEDTLS_LIB_DIR)/md.o -mbedtls_lib_crypto-$(CONFIG_$(XPL_)MD5_MBEDTLS) += $(MBEDTLS_LIB_DIR)/md5.o -mbedtls_lib_crypto-$(CONFIG_$(XPL_)SHA1_MBEDTLS) += $(MBEDTLS_LIB_DIR)/sha1.o -mbedtls_lib_crypto-$(CONFIG_$(XPL_)SHA256_MBEDTLS) += \ +mbedtls_lib_crypto-$(CONFIG_$(PHASE_)MD5_MBEDTLS) += $(MBEDTLS_LIB_DIR)/md5.o +mbedtls_lib_crypto-$(CONFIG_$(PHASE_)SHA1_MBEDTLS) += $(MBEDTLS_LIB_DIR)/sha1.o +mbedtls_lib_crypto-$(CONFIG_$(PHASE_)SHA256_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/sha256.o -mbedtls_lib_crypto-$(CONFIG_$(XPL_)SHA512_MBEDTLS) += \ +mbedtls_lib_crypto-$(CONFIG_$(PHASE_)SHA512_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/sha512.o -mbedtls_lib_crypto-$(CONFIG_$(XPL_)HKDF_MBEDTLS) += \ +mbedtls_lib_crypto-$(CONFIG_$(PHASE_)HKDF_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/hkdf.o # MbedTLS X509 library obj-$(CONFIG_$(XPL_)MBEDTLS_LIB_X509) += mbedtls_lib_x509.o mbedtls_lib_x509-y := $(MBEDTLS_LIB_DIR)/x509.o -mbedtls_lib_x509-$(CONFIG_$(XPL_)ASN1_DECODER_MBEDTLS) += \ +mbedtls_lib_x509-$(CONFIG_$(PHASE_)ASN1_DECODER_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/asn1parse.o \ $(MBEDTLS_LIB_DIR)/asn1write.o \ $(MBEDTLS_LIB_DIR)/oid.o -mbedtls_lib_x509-$(CONFIG_$(XPL_)RSA_PUBLIC_KEY_PARSER_MBEDTLS) += \ +mbedtls_lib_x509-$(CONFIG_$(PHASE_)RSA_PUBLIC_KEY_PARSER_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/bignum.o \ $(MBEDTLS_LIB_DIR)/bignum_core.o \ $(MBEDTLS_LIB_DIR)/rsa.o \ $(MBEDTLS_LIB_DIR)/rsa_alt_helpers.o -mbedtls_lib_x509-$(CONFIG_$(XPL_)ASYMMETRIC_PUBLIC_KEY_MBEDTLS) += \ +mbedtls_lib_x509-$(CONFIG_$(PHASE_)ASYMMETRIC_PUBLIC_KEY_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/pk.o \ $(MBEDTLS_LIB_DIR)/pk_wrap.o \ $(MBEDTLS_LIB_DIR)/pkparse.o -mbedtls_lib_x509-$(CONFIG_$(XPL_)X509_CERTIFICATE_PARSER_MBEDTLS) += \ +mbedtls_lib_x509-$(CONFIG_$(PHASE_)X509_CERTIFICATE_PARSER_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/x509_crl.o \ $(MBEDTLS_LIB_DIR)/x509_crt.o -mbedtls_lib_x509-$(CONFIG_$(XPL_)PKCS7_MESSAGE_PARSER_MBEDTLS) += \ +mbedtls_lib_x509-$(CONFIG_$(PHASE_)PKCS7_MESSAGE_PARSER_MBEDTLS) += \ $(MBEDTLS_LIB_DIR)/pkcs7.o #mbedTLS TLS support
net/Makefile +3 -3
@@ -14,7 +14,7 @@ obj-$(CONFIG_CMD_DNS) += dns.o obj-$(CONFIG_DM_DSA) += dsa-uclass.o obj-$(CONFIG_CMD_LINK_LOCAL) += link_local.o obj-$(CONFIG_IPV6) += ndisc.o -obj-$(CONFIG_$(XPL_)DM_ETH) += net.o +obj-$(CONFIG_$(PHASE_)DM_ETH) += net.o obj-$(CONFIG_IPV6) += net6.o obj-$(CONFIG_CMD_NFS) += nfs.o obj-$(CONFIG_CMD_PING) += ping.o
@@ -39,11 +39,11 @@ CFLAGS_eth_common.o += -Wno-format-extra-args endif ifeq ($(filter y,$(CONFIG_NET) $(CONFIG_NET_LWIP)),y) -obj-$(CONFIG_$(XPL_)DM_ETH) += eth-uclass.o +obj-$(CONFIG_$(PHASE_)DM_ETH) += eth-uclass.o obj-$(CONFIG_$(PHASE_)BOOTDEV_ETH) += eth_bootdev.o obj-$(CONFIG_DM_MDIO) += mdio-uclass.o obj-$(CONFIG_DM_MDIO_MUX) += mdio-mux-uclass.o -obj-$(CONFIG_$(XPL_)DM_ETH) += eth_common.o +obj-$(CONFIG_$(PHASE_)DM_ETH) += eth_common.o obj-y += net-common.o endif
net/lwip/Makefile +1 -1
@@ -1,6 +1,6 @@ ccflags-y += -I$(srctree)/lib/lwip/lwip/src/include -I$(srctree)/lib/lwip/u-boot -obj-$(CONFIG_$(SPL_)DM_ETH) += net-lwip.o +obj-$(CONFIG_$(PHASE_)DM_ETH) += net-lwip.o obj-$(CONFIG_CMD_DHCP) += dhcp.o obj-$(CONFIG_CMD_DNS) += dns.o obj-$(CONFIG_CMD_PING) += ping.o
scripts/Kbuild.include +4 -6
@@ -324,18 +324,16 @@ endif # do not delete intermediate files automatically .SECONDARY: -ifdef CONFIG_XPL_BUILD -XPL_ := SPL_ +ifeq ($(CONFIG_SPL_BUILD),y) +PHASE_ := SPL_ +else ifeq ($(CONFIG_VPL_BUILD),y) PHASE_ := VPL_ else ifeq ($(CONFIG_TPL_BUILD),y) PHASE_ := TPL_ else -PHASE_ := SPL_ +PHASE_ := endif endif -else -XPL_ := -PHASE_ := endif
scripts/Makefile.xpl +4 -6
@@ -58,20 +58,18 @@ endif export SPL_NAME -ifdef CONFIG_XPL_BUILD -XPL_ := SPL_ +ifeq ($(CONFIG_SPL_BUILD),y) +PHASE_ := SPL_ +else ifeq ($(CONFIG_VPL_BUILD),y) PHASE_ := VPL_ else ifeq ($(CONFIG_TPL_BUILD),y) PHASE_ := TPL_ else -PHASE_ := SPL_ +PHASE_ := endif endif -else -XPL_ := -PHASE_ := endif ifeq ($(obj)$(CONFIG_SUPPORT_SPL),spl)
test/Makefile +3 -3
@@ -4,15 +4,15 @@ obj-y += test-main.o -obj-$(CONFIG_$(XPL_)CMDLINE) += cmd/ -obj-$(CONFIG_$(XPL_)CMDLINE) += cmd_ut.o +obj-$(CONFIG_$(PHASE_)CMDLINE) += cmd/ +obj-$(CONFIG_$(PHASE_)CMDLINE) += cmd_ut.o obj-y += dm/ obj-$(CONFIG_FUZZ) += fuzz/ ifndef CONFIG_SANDBOX_VPL obj-$(CONFIG_UNIT_TEST) += lib/ endif ifneq ($(CONFIG_HUSH_PARSER),) -obj-$(CONFIG_$(XPL_)CMDLINE) += hush/ +obj-$(CONFIG_$(PHASE_)CMDLINE) += hush/ endif obj-$(CONFIG_UT_OPTEE) += optee/ obj-y += ut.o
test/boot/Makefile +1 -1
@@ -11,7 +11,7 @@ obj-$(CONFIG_CEDIT) += cedit.o endif ifdef CONFIG_SANDBOX -obj-$(CONFIG_$(XPL_)CMDLINE) += bootm.o +obj-$(CONFIG_$(PHASE_)CMDLINE) += bootm.o endif obj-$(CONFIG_MEASURED_BOOT) += measurement.o
test/cmd/Makefile +1 -1
@@ -3,7 +3,7 @@ # Copyright (c) 2013 Google, Inc # Copyright 2022-2023 Arm Limited and/or its affiliates <[email protected]> -obj-$(CONFIG_$(XPL_)CMDLINE) += command.o +obj-$(CONFIG_$(PHASE_)CMDLINE) += command.o ifdef CONFIG_HUSH_PARSER obj-$(CONFIG_CONSOLE_RECORD) += test_echo.o endif
test/common/Makefile +3 -3
@@ -1,13 +1,13 @@ # SPDX-License-Identifier: GPL-2.0+ obj-$(CONFIG_AUTOBOOT) += test_autoboot.o -ifneq ($(CONFIG_$(XPL_)BLOBLIST),) +ifneq ($(CONFIG_$(PHASE_)BLOBLIST),) ifdef CONFIG_BLOBLIST_FIXED -obj-$(CONFIG_$(XPL_)CMDLINE) += bloblist.o +obj-$(CONFIG_$(PHASE_)CMDLINE) += bloblist.o endif endif obj-$(CONFIG_CYCLIC) += cyclic.o obj-$(CONFIG_EVENT_DYNAMIC) += event.o obj-y += cread.o -obj-$(CONFIG_$(XPL_)CMDLINE) += print.o +obj-$(CONFIG_$(PHASE_)CMDLINE) += print.o
test/fuzz/Makefile +1 -1
@@ -4,5 +4,5 @@ # Written by Andrew Scull <[email protected]> # -obj-$(CONFIG_$(XPL_)CMDLINE) += cmd_fuzz.o +obj-$(CONFIG_$(PHASE_)CMDLINE) += cmd_fuzz.o obj-$(CONFIG_VIRTIO_SANDBOX) += virtio.o
test/lib/Makefile +2 -2
@@ -3,7 +3,7 @@ # (C) Copyright 2018 # Mario Six, Guntermann & Drunck GmbH, [email protected] -obj-$(CONFIG_$(XPL_)UT_COMPRESSION) += compression.o +obj-$(CONFIG_$(PHASE_)UT_COMPRESSION) += compression.o ifeq ($(CONFIG_XPL_BUILD),) obj-y += abuf.o
@@ -29,7 +29,7 @@ obj-$(CONFIG_GETOPT) += getopt.o obj-$(CONFIG_CRC8) += test_crc8.o obj-$(CONFIG_UT_LIB_CRYPT) += test_crypt.o obj-$(CONFIG_UT_TIME) += time.o -obj-$(CONFIG_$(XPL_)UT_UNICODE) += unicode.o +obj-$(CONFIG_$(PHASE_)UT_UNICODE) += unicode.o obj-$(CONFIG_LIB_UUID) += uuid.o else obj-$(CONFIG_SANDBOX) += kconfig_spl.o
tools/qconfig.py +3 -5
@@ -1175,7 +1175,7 @@ def prefix_config(cfg): return oper + cfg -RE_MK_CONFIGS = re.compile(r'CONFIG_(\$\(XPL_\)|\$\(PHASE_\))?([A-Za-z0-9_]*)') +RE_MK_CONFIGS = re.compile(r'CONFIG_(\$\(PHASE_\))?([A-Za-z0-9_]*)') RE_IFDEF = re.compile(r'(ifdef|ifndef)') RE_C_CONFIGS = re.compile(r'CONFIG_([A-Za-z0-9_]*)') RE_CONFIG_IS = re.compile(r'CONFIG_IS_ENABLED\(([A-Za-z0-9_]*)\)')
@@ -1220,8 +1220,6 @@ def scan_makefiles(fnames): >>> RE_MK_CONFIGS.search('CONFIG_FRED').groups() (None, 'FRED') - >>> RE_MK_CONFIGS.search('CONFIG_$(XPL_)MARY').groups() - ('$(XPL_)', 'MARY') >>> RE_MK_CONFIGS.search('CONFIG_$(PHASE_)MARY').groups() ('$(PHASE_)', 'MARY') """
@@ -1321,8 +1319,8 @@ def do_scan_source(path, do_update): spl_mode (int): If MODE_SPL, look at source code which implies an xPL_ option, but for which there is none; for MOD_PROPER, look at source code which implies a Proper - option (i.e. use of CONFIG_IS_ENABLED() or $(XPL_) or - $(PHASE_) but for which there none; + option (i.e. use of CONFIG_IS_ENABLED() or $(PHASE_) but for + which there none; if MODE_NORMAL, ignore SPL Returns:
Signature · 1 line
2.43.0
PATCH v3 2/3 doc/develop/codingstyle.rst: Add a section on conditional compilation
In reply to Tom RiniIn order to make a start on explaining how and when to use certain macros, we need to document their usage somewhere. As a first step, take section 21 of the v6.13 Linux Kernel coding-style document on conditional compilation, verbatim, and add it to our documentation. Further rewording to be clearer about U-Boot will be done next.
---
Changes in v3:
- Reword the commit message to be clearer about where this comes from.
Changes in v2:
- New patch.
--- doc/develop/codingstyle.rst | 48 +++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+)
doc/develop/codingstyle.rst +48 -0
@@ -154,6 +154,54 @@ See `here <https://www.kernel.org/doc/html/latest/doc-guide/kernel-doc.html#function-documentation>`_ for style. +Conditional Compilation +----------------------- + +Wherever possible, don't use preprocessor conditionals (#if, #ifdef) in .c +files; doing so makes code harder to read and logic harder to follow. Instead, +use such conditionals in a header file defining functions for use in those .c +files, providing no-op stub versions in the #else case, and then call those +functions unconditionally from .c files. The compiler will avoid generating +any code for the stub calls, producing identical results, but the logic will +remain easy to follow. + +Prefer to compile out entire functions, rather than portions of functions or +portions of expressions. Rather than putting an ifdef in an expression, factor +out part or all of the expression into a separate helper function and apply the +conditional to that function. + +If you have a function or variable which may potentially go unused in a +particular configuration, and the compiler would warn about its definition +going unused, mark the definition as __maybe_unused rather than wrapping it in +a preprocessor conditional. (However, if a function or variable *always* goes +unused, delete it.) + +Within code, where possible, use the IS_ENABLED macro to convert a Kconfig +symbol into a C boolean expression, and use it in a normal C conditional: + +.. code-block:: c + + if (IS_ENABLED(CONFIG_SOMETHING)) { + ... + } + +The compiler will constant-fold the conditional away, and include or exclude +the block of code just as with an #ifdef, so this will not add any runtime +overhead. However, this approach still allows the C compiler to see the code +inside the block, and check it for correctness (syntax, types, symbol +references, etc). Thus, you still have to use an #ifdef if the code inside the +block references symbols that will not exist if the condition is not met. + +At the end of any non-trivial #if or #ifdef block (more than a few lines), +place a comment after the #endif on the same line, noting the conditional +expression used. For instance: + +.. code-block:: c + + #ifdef CONFIG_SOMETHING + ... + #endif /* CONFIG_SOMETHING */ + Driver model ------------
Signature · 1 line
2.43.0
PATCH v3 3/3 doc/develop/codingstyle.rst: Expand to include CONFIG_IS_ENABLED and PHASE_
In reply to Tom RiniExpand the conditional compilation section to explain when to use CONFIG_IS_ENABLED rather than IS_ENABLED and provide an example. Next, note what the PHASE_ macro is supposed to be used for as well.
---
Changes in v3:
- Reword the start of the new content a bit after talking with Quentin Schulz.
Changes in v2:
- New patch.
--- doc/develop/codingstyle.rst | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)
doc/develop/codingstyle.rst +19 -0
@@ -192,6 +192,25 @@ inside the block, and check it for correctness (syntax, types, symbol references, etc). Thus, you still have to use an #ifdef if the code inside the block references symbols that will not exist if the condition is not met. +When working with xPL (see :doc:`spl` for more information) we need to take +further care to use the right macro. In the case where a symbol may be +referenced with an xPL-specific Kconfig symbol, use the CONFIG_IS_ENABLED macro +instead, in a similar manner: + +.. code-block:: c + + if (CONIG_IS_ENABLED(SOMETHING)) { + ... + } + +When dealing with a Kconfig symbol that has both a normal name and one or more +xPL-prefixed names, the Makefile needs special consideration as well. The +PHASE\_ macro helps us in this situation thusly: + +.. code-block:: make + + obj-$(CONFIG_$(PHASE_)SOMETHING) += something.o + At the end of any non-trivial #if or #ifdef block (more than a few lines), place a comment after the #endif on the same line, noting the conditional expression used. For instance:
Signature · 1 line
2.43.0
Quoted 8 lines · Tom Rini
Hey all,
This series switches to always using $(PHASE_) in Makefiles when building rather than $(PHASE_) or $(XPL_). It also starts on documenting this part of the build, but as a follow-up we need to rename
doc/develop/spl.rstand expand on explaining things a bit.[...]
Applied to u-boot/master, thanks!
[1/3] Kbuild: Always use $(PHASE_)
commit: 302b41d5397e9f821d360a74335e8821d4513970
[2/3] doc/develop/codingstyle.rst: Add a section on conditional compilation
commit: 0471f8d0012ff9794014d222151acb65ce387550
[3/3] doc/develop/codingstyle.rst: Expand to include CONFIG_IS_ENABLED and PHASE_
commit: fa72470a4ec5522fe92986bb53b22167d35d0913Signature · 1 line
Tom