]> git.kernelconcepts.de Git - karo-tx-uboot.git/commit
sunxi: usbc: Wait for vbus to fall after disabling it
authorHans de Goede <hdegoede@redhat.com>
Fri, 27 Mar 2015 20:46:00 +0000 (21:46 +0100)
committerLothar Waßmann <LW@KARO-electronics.de>
Tue, 8 Sep 2015 19:47:14 +0000 (21:47 +0200)
commit9701632b3e3396ac7f49279856c20a4cf0a4f97b
tree6257721c8de7685ede0347361ee59daa1eeec947
parent5aed1183eca356a051da534acb5f6ab532137e05
sunxi: usbc: Wait for vbus to fall after disabling it

When u-boot boots the board may be powering vbus, we turn off vbus in
sunxi_usbc_request_resources, if we are too quick with reading vusb-detect
after this we may see a residual charge and assume we've an external vusb
connected even though we do not. So when we see an external vusb wait a bit
and try again.

Without this when dealing with a pmic controller vbus and doing "reset" on
the u-boot console the musb host will only init once every other boot, because
the other boot it thinks an external vbus is present, this commit fixes this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Ian Campbell <ijc@hellion.org.uk>
arch/arm/cpu/armv7/sunxi/usbc.c