diff options
author | Samuel Holland <samuel@sholland.org> | 2021-09-12 09:22:41 -0500 |
---|---|---|
committer | Andre Przywara <andre.przywara@arm.com> | 2021-10-25 14:49:16 +0100 |
commit | 1da7b88cade196434b84e701c1dadcd3b37c97bc (patch) | |
tree | 008f608fb878d074d9fe22c1ac1b12c82ca24456 /drivers/usb/cdns3/cdns3-ti.c | |
parent | 6617894b6903e1cfc829add1558143be75d6bcd0 (diff) |
phy: sun4i-usb: Refactor VBUS detection to match Linux
The Linux driver checks the VBUS detection GPIO first; then VBUS power
supply; then finally assumes VBUS is present. When adding VBUS power
supply support, we want to match that order, so we get the same behavior
in case both a GPIO and a power supply are provided in the device tree.
So refactor the function a bit to remove the early return, and use the
same "assume VBUS is present" final fallback.
Signed-off-by: Samuel Holland <samuel@sholland.org>
Acked-by: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-ti.c')
0 files changed, 0 insertions, 0 deletions