raspberrypi / linux

Kernel source tree for Raspberry Pi-provided kernel builds. Issues unrelated to the linux kernel should be posted on the community forum at https://forums.raspberrypi.com/
Other
11.14k stars 4.99k forks source link

USB Gadget only mode is broken: struct dwc2_hsotg has no member named bus_suspended #4368

Open pmunts opened 3 years ago

pmunts commented 3 years ago

One of the recent changes to the dwc2 driver has broken USB Gadget Only mode (CONFIG_USB_DWC2_PERIPHERAL=y).

The bus_suspended field of struct dwc2_hsotg is not included in the structure definition if CONFIG_USB_DWC2_PERIPHERAL is defined. This causes a compile error:

drivers/usb/dwc2/core_intr.c: In function 'dwc_handle_gpwrdn_disc_det':
drivers/usb/dwc2/core_intr.c:710:7: error: 'struct dwc2_hsotg' has no member named 'bus_suspended'
pelwell commented 3 years ago

That's an upstream bug introduced by a recent fix (which is why it was back-ported). I've pushed a patch to rpi-5.10.y that should fix it.

pelwell commented 3 years ago

https://marc.info/?l=linux-usb&m=162218990901875&w=2