[PATCH v7 1/4] i2c: designware: Add CONFIG_ACPIGEN limitation to designware_i2c_pci.c

Minda Chen minda.chen at starfivetech.com
Thu Jul 20 13:23:30 CEST 2023


As the designware_i2c_pci.c uses ACPI APIs, If some SoCs (StarFive
JH7110) contain designware i2c and PCI but do not use ACPI,
This file will be can't be compiled. So add ACPIGEN to
designware_i2c_pci.c

Signed-off-by: Minda Chen <minda.chen at starfivetech.com>
---
 drivers/i2c/Makefile | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/i2c/Makefile b/drivers/i2c/Makefile
index 99545df2e5..92b1ec6bc3 100644
--- a/drivers/i2c/Makefile
+++ b/drivers/i2c/Makefile
@@ -18,9 +18,11 @@ obj-$(CONFIG_SYS_I2C_CADENCE) += i2c-cdns.o
 obj-$(CONFIG_SYS_I2C_CA) += i2c-cortina.o
 obj-$(CONFIG_SYS_I2C_DAVINCI) += davinci_i2c.o
 obj-$(CONFIG_SYS_I2C_DW) += designware_i2c.o
+ifdef CONFIG_ACPIGEN
 ifdef CONFIG_PCI
 obj-$(CONFIG_SYS_I2C_DW) += designware_i2c_pci.o
 endif
+endif
 obj-$(CONFIG_SYS_I2C_FSL) += fsl_i2c.o
 obj-$(CONFIG_SYS_I2C_IHS) += ihs_i2c.o
 obj-$(CONFIG_SYS_I2C_INTEL) += intel_i2c.o
-- 
2.17.1



More information about the U-Boot mailing list