[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220920084431.196258-1-renzhijie2@huawei.com>
Date: Tue, 20 Sep 2022 16:44:31 +0800
From: Ren Zhijie <renzhijie2@...wei.com>
To: <heikki.krogerus@...ux.intel.com>, <gregkh@...uxfoundation.org>,
<xji@...logixsemi.com>
CC: <linux-usb@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
Ren Zhijie <renzhijie2@...wei.com>
Subject: [PATCH -next] usb: typec: anx7411: Fix build error without CONFIG_POWER_SUPPLY
Building without CONFIG_POWER_SUPPLY will fail:
drivers/usb/typec/anx7411.o: In function `anx7411_detect_power_mode':
anx7411.c:(.text+0x527): undefined reference to `power_supply_changed'
drivers/usb/typec/anx7411.o: In function `anx7411_psy_set_prop':
anx7411.c:(.text+0x90d): undefined reference to `power_supply_get_drvdata'
anx7411.c:(.text+0x930): undefined reference to `power_supply_changed'
drivers/usb/typec/anx7411.o: In function `anx7411_psy_get_prop':
anx7411.c:(.text+0x94d): undefined reference to `power_supply_get_drvdata'
drivers/usb/typec/anx7411.o: In function `anx7411_i2c_probe':
anx7411.c:(.text+0x111d): undefined reference to
`devm_power_supply_register'
drivers/usb/typec/anx7411.o: In function `anx7411_work_func':
anx7411.c:(.text+0x167c): undefined reference to `power_supply_changed'
anx7411.c:(.text+0x1b55): undefined reference to `power_supply_changed'
Add POWER_SUPPLY dependency to Kconfig.
Fixes: fe6d8a9c8e64 ("usb: typec: anx7411: Add Analogix PD ANX7411 support")
Signed-off-by: Ren Zhijie <renzhijie2@...wei.com>
---
drivers/usb/typec/Kconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/typec/Kconfig b/drivers/usb/typec/Kconfig
index 5defdfead653..831e7049977d 100644
--- a/drivers/usb/typec/Kconfig
+++ b/drivers/usb/typec/Kconfig
@@ -56,6 +56,7 @@ config TYPEC_ANX7411
tristate "Analogix ANX7411 Type-C DRP Port controller driver"
depends on I2C
depends on USB_ROLE_SWITCH
+ depends on POWER_SUPPLY
help
Say Y or M here if your system has Analogix ANX7411 Type-C DRP Port
controller driver.
--
2.17.1
Powered by blists - more mailing lists