On Wed, Jul 21, 2021 at 08:46:17AM +0800, kernel test robot wrote: > Hi Matthias, > > I love your patch! Yet something to improve: > > [auto build test ERROR on usb/usb-testing] > [also build test ERROR on robh/for-next driver-core/driver-core-testing linus/master v5.14-rc2 next-20210720] > [cannot apply to char-misc/char-misc-testing] > [If your patch is applied to the wrong git tree, kindly drop us a note. > And when submitting patch, we suggest to use '--base' as documented in > https://git-scm.com/docs/git-format-patch] > > url: https://github.com/0day-ci/linux/commits/Matthias-Kaehlcke/usb-misc-Add-onboard_usb_hub-driver/20210720-144614 > base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing > config: i386-randconfig-a003-20210720 (attached as .config) > compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0 > reproduce (this is a W=1 build): > # https://github.com/0day-ci/linux/commit/1ac4caccda0f2e6904b0e1462bc9735c690d719f > git remote add linux-review https://github.com/0day-ci/linux > git fetch --no-tags linux-review Matthias-Kaehlcke/usb-misc-Add-onboard_usb_hub-driver/20210720-144614 > git checkout 1ac4caccda0f2e6904b0e1462bc9735c690d719f > # save the attached .config to linux build tree > mkdir build_dir > make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash > > If you fix the issue, kindly add following tag as appropriate > Reported-by: kernel test robot <lkp@xxxxxxxxx> > > All errors (new ones prefixed by >>): > > ld: drivers/usb/dwc3/core.o: in function `dwc3_resume_common': > >> drivers/usb/dwc3/core.c:1853: undefined reference to `dwc3_gadget_resume' > ld: drivers/usb/dwc3/core.o: in function `dwc3_runtime_resume': > >> drivers/usb/dwc3/core.c:1912: undefined reference to `dwc3_gadget_process_pending_events' > ld: drivers/usb/dwc3/core.o: in function `dwc3_suspend_common': > >> drivers/usb/dwc3/core.c:1750: undefined reference to `dwc3_gadget_suspend' What happened here is that USB_DWC3 was selected, but one of USB_DWC3_HOST, USB_DWC3_GADGET or USB_DWC3_DUAL_ROLE. Typically one of them would be selected by: choice bool "DWC3 Mode Selection" default USB_DWC3_DUAL_ROLE if (USB && USB_GADGET) default USB_DWC3_HOST if (USB && !USB_GADGET) default USB_DWC3_GADGET if (!USB && USB_GADGET) In this case USB_XHCI_PLATFORM is not set (previously it would be selected by USB_DWC3) and USB_DWC3_HOST (and USB_DWC3_DUAL_ROLE) now depends on it. The following change should fix this: config USB_DWC3 - depends on (USB || USB_GADGET) && HAS_DMA + depends on (USB && USB_XHCI_PLATFORM) || USB_GADGET)) && HAS_DMA