Skip to content

Commit

Permalink
Revert "usb: dwc2: drd: fix soft connect when gadget is unconfigured"
Browse files Browse the repository at this point in the history
This reverts commit 269cbcf.

It causes build errors as reported by the kernel test robot.

Link: https://lore.kernel.org/r/[email protected]
Reported-by: kernel test robot <[email protected]>
Fixes: 269cbcf ("usb: dwc2: drd: fix soft connect when gadget is unconfigured")
Cc: [email protected]
Cc: Amelie Delaunay <[email protected]>
Cc: Minas Harutyunyan <[email protected]>
Cc: Fabrice Gasnier <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
gregkh committed Feb 12, 2022
1 parent c1dd10c commit 736e8d8
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions drivers/usb/dwc2/drd.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,10 +130,8 @@ static int dwc2_drd_role_sw_set(struct usb_role_switch *sw, enum usb_role role)
already = dwc2_ovr_avalid(hsotg, true);
} else if (role == USB_ROLE_DEVICE) {
already = dwc2_ovr_bvalid(hsotg, true);
if (hsotg->enabled) {
/* This clear DCTL.SFTDISCON bit */
dwc2_hsotg_core_connect(hsotg);
}
/* This clear DCTL.SFTDISCON bit */
dwc2_hsotg_core_connect(hsotg);
} else {
if (dwc2_is_device_mode(hsotg)) {
if (!dwc2_ovr_bvalid(hsotg, false))
Expand Down

0 comments on commit 736e8d8

Please sign in to comment.