Commit 87c16d49a6bc67ecf864ee394d386e282fbe55aa
drivers: spl: consistently use the $(SPL_TPL_) macro
To simplify drivers/Makefile a bit when using TPL/SPL, we consistently use the $(SPL_TPL_) macro to test for drivers that have separate configuration symbols for the full U-boot, SPL and TPL stages. Instead of explicitly repeating them in two separate if-guarded sections of the Makefile, we can now simply list these options once. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
Showing 1 changed file with 16 additions and 20 deletions Side-by-side Diff
... | ... | @@ -2,33 +2,34 @@ |
2 | 2 | # SPDX-License-Identifier: GPL-2.0+ |
3 | 3 | # |
4 | 4 | |
5 | -obj-$(CONFIG_$(SPL_TPL_)DM) += core/ | |
6 | -obj-$(CONFIG_$(SPL_)CLK) += clk/ | |
7 | -obj-$(CONFIG_$(SPL_)LED) += led/ | |
8 | -obj-$(CONFIG_$(SPL_)PHY) += phy/ | |
9 | -obj-$(CONFIG_$(SPL_)PINCTRL) += pinctrl/ | |
10 | -obj-$(CONFIG_$(SPL_)RAM) += ram/ | |
5 | +obj-$(CONFIG_$(SPL_TPL_)CLK) += clk/ | |
6 | +obj-$(CONFIG_$(SPL_TPL_)DM) += core/ | |
7 | +obj-$(CONFIG_$(SPL_TPL_)DRIVERS_MISC_SUPPORT) += misc/ sysreset/ firmware/ | |
8 | +obj-$(CONFIG_$(SPL_TPL_)I2C_SUPPORT) += i2c/ | |
9 | +obj-$(CONFIG_$(SPL_TPL_)LED) += led/ | |
10 | +obj-$(CONFIG_$(SPL_TPL_)MMC_SUPPORT) += mmc/ | |
11 | +obj-$(CONFIG_$(SPL_TPL_)NAND_SUPPORT) += mtd/nand/ | |
12 | +obj-$(CONFIG_$(SPL_TPL_)PHY) += phy/ | |
13 | +obj-$(CONFIG_$(SPL_TPL_)PINCTRL) += pinctrl/ | |
14 | +obj-$(CONFIG_$(SPL_TPL_)RAM) += ram/ | |
15 | +obj-$(CONFIG_$(SPL_TPL_)SERIAL_SUPPORT) += serial/ | |
16 | +obj-$(CONFIG_$(SPL_TPL_)SPI_FLASH_SUPPORT) += mtd/spi/ | |
17 | +obj-$(CONFIG_$(SPL_TPL_)SPI_SUPPORT) += spi/ | |
11 | 18 | |
19 | +ifndef CONFIG_TPL_BUILD | |
12 | 20 | ifdef CONFIG_SPL_BUILD |
13 | 21 | |
14 | 22 | obj-$(CONFIG_SPL_CPU_SUPPORT) += cpu/ |
15 | 23 | obj-$(CONFIG_SPL_CRYPTO_SUPPORT) += crypto/ |
16 | -obj-$(CONFIG_SPL_I2C_SUPPORT) += i2c/ | |
17 | 24 | obj-$(CONFIG_SPL_GPIO_SUPPORT) += gpio/ |
18 | -obj-$(CONFIG_SPL_MMC_SUPPORT) += mmc/ | |
19 | 25 | obj-$(CONFIG_SPL_MPC8XXX_INIT_DDR_SUPPORT) += ddr/fsl/ |
20 | 26 | obj-$(CONFIG_ARMADA_38X) += ddr/marvell/a38x/ |
21 | 27 | obj-$(CONFIG_ARMADA_XP) += ddr/marvell/axp/ |
22 | 28 | obj-$(CONFIG_ALTERA_SDRAM) += ddr/altera/ |
23 | -obj-$(CONFIG_SPL_SERIAL_SUPPORT) += serial/ | |
24 | -obj-$(CONFIG_SPL_SPI_SUPPORT) += spi/ | |
25 | 29 | obj-$(CONFIG_SPL_POWER_SUPPORT) += power/ power/pmic/ |
26 | 30 | obj-$(CONFIG_SPL_POWER_SUPPORT) += power/regulator/ |
27 | -obj-$(CONFIG_SPL_DRIVERS_MISC_SUPPORT) += misc/ sysreset/ firmware/ | |
28 | 31 | obj-$(CONFIG_SPL_MTD_SUPPORT) += mtd/ |
29 | -obj-$(CONFIG_SPL_NAND_SUPPORT) += mtd/nand/ | |
30 | 32 | obj-$(CONFIG_SPL_ONENAND_SUPPORT) += mtd/onenand/ |
31 | -obj-$(CONFIG_SPL_SPI_FLASH_SUPPORT) += mtd/spi/ | |
32 | 33 | obj-$(CONFIG_SPL_UBI) += mtd/ubispl/ |
33 | 34 | obj-$(CONFIG_SPL_DMA_SUPPORT) += dma/ |
34 | 35 | obj-$(CONFIG_SPL_ETH_SUPPORT) += net/ |
35 | 36 | |
36 | 37 | |
37 | 38 | |
... | ... | @@ -49,18 +50,13 @@ |
49 | 50 | obj-$(CONFIG_SPL_USB_HOST_SUPPORT) += block/ |
50 | 51 | obj-$(CONFIG_SPL_MMC_SUPPORT) += block/ |
51 | 52 | obj-$(CONFIG_SPL_FPGA_SUPPORT) += fpga/ |
53 | + | |
52 | 54 | endif |
55 | +endif | |
53 | 56 | |
54 | 57 | ifdef CONFIG_TPL_BUILD |
55 | 58 | |
56 | -obj-$(CONFIG_TPL_I2C_SUPPORT) += i2c/ | |
57 | -obj-$(CONFIG_TPL_DRIVERS_MISC_SUPPORT) += misc/ sysreset/ firmware/ | |
58 | -obj-$(CONFIG_TPL_MMC_SUPPORT) += mmc/ | |
59 | 59 | obj-$(CONFIG_TPL_MPC8XXX_INIT_DDR_SUPPORT) += ddr/fsl/ |
60 | -obj-$(CONFIG_TPL_NAND_SUPPORT) += mtd/nand/ | |
61 | -obj-$(CONFIG_TPL_SERIAL_SUPPORT) += serial/ | |
62 | -obj-$(CONFIG_TPL_SPI_FLASH_SUPPORT) += mtd/spi/ | |
63 | -obj-$(CONFIG_TPL_SPI_SUPPORT) += spi/ | |
64 | 60 | |
65 | 61 | endif |
66 | 62 |
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8
-
mentioned in commit 0532ce
-
mentioned in commit e19fa8