linux-uconsole/drivers/extcon
Hans de Goede effdf2b134 extcon: axp288: Use vbus-valid instead of -present to determine cable presence
[ Upstream commit 5757aca101 ]

The vbus-present bit in the power status register also gets set to 1
when a usb-host cable (id-pin shorted to ground) is plugged in and a 5v
boost converter is supplying 5v to the otg usb bus.

This causes a "disconnect or unknown or ID event" warning in dmesg as
well as the extcon device to report the last detected charger cable
type as being connected even though none is connected.

This commit switches to checking the vbus-valid bit instead, which is
only 1 when both vbus is present and the vbus-path is enabled in the
vbus-path control register (the vbus-path gets disabled when a usb-host
cable is detected, to avoid the pmic drawing power from the 5v boost
converter).

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-08 10:14:16 +02:00
..
extcon-adc-jack.c extcon: Redefine the unique id of supported external connectors without 'enum extcon' type 2015-06-12 17:01:42 -07:00
extcon-arizona.c extcon: Modify the id and name of external connector 2015-10-16 08:30:09 +09:00
extcon-axp288.c extcon: axp288: Use vbus-valid instead of -present to determine cable presence 2017-10-08 10:14:16 +02:00
extcon-gpio.c extcon: gpio: Use descriptor-based GPIO interface instead of legacy gpio_* API 2015-09-30 19:22:50 +09:00
extcon-max8997.c extcon: Modify the id and name of external connector 2015-10-16 08:30:09 +09:00
extcon-max14577.c extcon: Modify the id and name of external connector 2015-10-16 08:30:09 +09:00
extcon-max77693.c extcon: Modify the id and name of external connector 2015-10-16 08:30:09 +09:00
extcon-max77843.c extcon: max77843: Use correct size for reading the interrupt register 2016-05-04 14:48:54 -07:00
extcon-palmas.c extcon: palmas: Fix build break due to devm_gpiod_get_optional API change 2015-08-13 20:56:18 +09:00
extcon-rt8973a.c extcon: Modify the id and name of external connector 2015-10-16 08:30:09 +09:00
extcon-rt8973a.h extcon: rt8973a: Add Richtek RT8973A extcon driver 2014-09-22 11:43:08 +09:00
extcon-sm5502.c extcon: Modify the id and name of external connector 2015-10-16 08:30:09 +09:00
extcon-sm5502.h extcon: sm5502: Move sm5502.h header file to extcon directory 2014-09-22 11:43:08 +09:00
extcon-usb-gpio.c extcon: palmas: Support GPIO based USB ID detection 2015-08-10 21:26:25 +09:00
extcon.c extcon: Modify the id and name of external connector 2015-10-16 08:30:09 +09:00
Kconfig extcon: Allow compile test of GPIO consumers if !GPIOLIB 2015-05-19 16:39:06 +09:00
Makefile extcon: axp288: Add axp288 extcon driver support 2015-05-19 16:39:04 +09:00