Commit 50642709 authored by Peter Chen's avatar Peter Chen Committed by Felipe Balbi

usb: cdns3: core: quit if it uses role switch class

If the board uses role switch class for switching the role, it should
not depends on SoC OTG hardware siginal any more, so quit early.
Signed-off-by: default avatarPeter Chen <peter.chen@nxp.com>
Signed-off-by: default avatarFelipe Balbi <balbi@kernel.org>
parent a609ce2a
......@@ -280,6 +280,10 @@ int cdns3_hw_role_switch(struct cdns3 *cdns)
enum usb_role real_role, current_role;
int ret = 0;
/* Depends on role switch class */
if (cdns->role_sw)
return 0;
pm_runtime_get_sync(cdns->dev);
current_role = cdns->role;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment