All of lore.kernel.org
 help / color / mirror / Atom feed
From: Massimo Pegorer <massimo.pegorer+oss@gmail.com>
To: Simon Glass <sjg@chromium.org>, u-boot@lists.u-boot-project.org
Cc: "Tom Rini" <trini@konsulko.com>,
	"Ilias Apalodimas" <ilias.apalodimas@linaro.org>,
	"Quentin Schulz" <u-boot@0leil.net>,
	"Kever Yang" <kever.yang@rock-chips.com>,
	"Mattijs Korpershoek" <mkorpershoek@kernel.org>,
	"Jonas Karlman" <jonas@kwiboo.se>,
	"Neil Armstrong" <neil.armstrong@linaro.org>,
	"Marek Vasut" <marek.vasut+usb@mailbox.org>,
	"Jörg Sommer" <joerg@jo-so.de>,
	"Carlo Caione" <ccaione@baylibre.com>,
	"Alexey Charkov" <alchark@gmail.com>,
	"Massimo Pegorer" <massimo.pegorer+oss@gmail.com>
Subject: [PATCH 2/2] drivers: Skip needless CONFIG_TPL_BUILD check
Date: Tue, 08 Sep 2026 19:05:00 +0200	[thread overview]
Message-ID: <20260908-xpl-v1-2-58e9e5248c29@gmail.com> (raw)
In-Reply-To: <20260908-xpl-v1-0-58e9e5248c29@gmail.com>

Just check that CONFIG_XPL_BUILD is not set to select files for U-Boot
proper build. Indeed, CONFIG_TPL_BUILD being set implies by design that
CONFIG_XPL_BUILD is set too, therefore CONFIG_XPL_BUILD not set implies
that CONFIG_TPL_BUILD is not set either, making its check needless.

Fixes: 371dc068bbf5 ("drivers: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD")
Signed-off-by: Massimo Pegorer <massimo.pegorer+oss@gmail.com>
---
 drivers/Makefile          | 2 +-
 drivers/bus/Makefile      | 2 +-
 drivers/mtd/Makefile      | 2 +-
 drivers/mtd/nand/Makefile | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/Makefile b/drivers/Makefile
index 269c3db12e8..da37338fe1f 100644
--- a/drivers/Makefile
+++ b/drivers/Makefile
@@ -87,7 +87,7 @@ obj-$(CONFIG_TPL_MPC8XXX_INIT_DDR) += ddr/fsl/
 
 endif
 
-ifeq ($(CONFIG_XPL_BUILD)$(CONFIG_TPL_BUILD),)
+ifeq ($(CONFIG_XPL_BUILD),)
 
 obj-y += ata/
 obj-$(CONFIG_DM_DEMO) += demo/
diff --git a/drivers/bus/Makefile b/drivers/bus/Makefile
index 2d242bc2886..239d9a35fe4 100644
--- a/drivers/bus/Makefile
+++ b/drivers/bus/Makefile
@@ -3,7 +3,7 @@
 # Makefile for the bus drivers.
 #
 
-ifeq ($(CONFIG_XPL_BUILD)$(CONFIG_TPL_BUILD),)
+ifeq ($(CONFIG_XPL_BUILD),)
 obj-$(CONFIG_TI_PWMSS)	+= ti-pwmss.o
 obj-$(CONFIG_UNIPHIER_SYSTEM_BUS) += uniphier-system-bus.o
 endif
diff --git a/drivers/mtd/Makefile b/drivers/mtd/Makefile
index ce05e206073..e204f19ff8b 100644
--- a/drivers/mtd/Makefile
+++ b/drivers/mtd/Makefile
@@ -16,7 +16,7 @@ mtd-$(CONFIG_RENESAS_RPC_HF) += renesas_rpc_hf.o
 mtd-$(CONFIG_HBMC_AM654) += hbmc-am654.o
 
 # U-Boot build
-ifeq ($(CONFIG_XPL_BUILD)$(CONFIG_TPL_BUILD),)
+ifeq ($(CONFIG_XPL_BUILD),)
 
 ifneq ($(mtd-y),)
 obj-y += mtd.o
diff --git a/drivers/mtd/nand/Makefile b/drivers/mtd/nand/Makefile
index c8169cf7390..cf53c5f601e 100644
--- a/drivers/mtd/nand/Makefile
+++ b/drivers/mtd/nand/Makefile
@@ -1,6 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0+
 
-ifeq ($(CONFIG_XPL_BUILD)$(CONFIG_TPL_BUILD),)
+ifeq ($(CONFIG_XPL_BUILD),)
 nandcore-objs := core.o bbt.o
 obj-$(CONFIG_MTD_NAND_CORE) += nandcore.o
 obj-$(CONFIG_MTD_RAW_NAND) += raw/

-- 
2.34.1


      parent reply	other threads:[~2026-09-08 17:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-08 17:04 [PATCH 0/2] Avoid needless CONFIG_TPL_BUILD checks for U-Boot proper build Massimo Pegorer
2026-09-08 17:04 ` [PATCH 1/2] arch: arm: rockchip: Skip needless CONFIG_TPL_BUILD check Massimo Pegorer
2026-09-08 17:05 ` Massimo Pegorer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260908-xpl-v1-2-58e9e5248c29@gmail.com \
    --to=massimo.pegorer+oss@gmail.com \
    --cc=alchark@gmail.com \
    --cc=ccaione@baylibre.com \
    --cc=ilias.apalodimas@linaro.org \
    --cc=joerg@jo-so.de \
    --cc=jonas@kwiboo.se \
    --cc=kever.yang@rock-chips.com \
    --cc=marek.vasut+usb@mailbox.org \
    --cc=mkorpershoek@kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=sjg@chromium.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@0leil.net \
    --cc=u-boot@lists.u-boot-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.