power: supply: cpcap-charger: add OMAP_USB2 dependency
authorArnd Bergmann <arnd@arndb.de>
Fri, 21 Jul 2017 16:14:37 +0000 (18:14 +0200)
committerSebastian Reichel <sre@kernel.org>
Mon, 24 Jul 2017 12:08:59 +0000 (14:08 +0200)
commit8b35bf5927b1e89e9b2f9ddbd701bd9b27456e78
tree1c464c9246e1cff6ea4600e145033024ab83f55f
parent0188155a234bf77c7588bdedf3b77cc87bfeb7df
power: supply: cpcap-charger: add OMAP_USB2 dependency

When CONFIG_OMAP_USB2 is set to 'm' and the charger driver is built-in,
we get this link failure:

drivers/power/supply/cpcap-charger.o: In function `cpcap_charger_probe':
cpcap-charger.c:(.text+0x48c): undefined reference to `omap_usb2_set_comparator'
drivers/power/supply/cpcap-charger.o: In function `cpcap_charger_remove':
cpcap-charger.c:(.text+0x774): undefined reference to `omap_usb2_set_comparator'

This adds a dependency to prevent that problem, while still allowing
compile-testing with the OMAP_USB2 driver completely disabled.

Fixes: 0c9888e3c192 ("power: supply: cpcap-charger: Add minimal CPCAP PMIC battery charger")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
drivers/power/supply/Kconfig