On Mon, Sep 29, 2014 at 11:28:57AM +0300, Heikki Krogerus wrote: > > > > A question, the dwc3 controller is the PCI-E device in my platform, > > > > but the class code of PCI header is 0x0c0330, the same with xHC. > > > > That's because it need to meet the windows enviroment. The dwc3 > > > > controller acted as only host mode to bind with windows xhci driver. > > > > But on linux, sometimes, we auto-bind with xhci driver as well (class > > > > code 0x0c0330) despite we use Pid/Vid on dwc3 driver. Then I need > > > > rmmod xhci_hcd module and modprobe dwc3_pci module manually. > > > > > > > > Any idea to resolve this issue? > > Declare a fixup quirk. I'm not a pci expert, but I think something > like this should work.. > > static void dwc3_fix_amd_nl_class(struct pci_dev *pdev) > { > pdev->class = 0x0c03fe; > } > DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_NL, > dwc3_fix_amd_nl_class); > Heikki, your info inspires me. :) I looked at pci driver, this update should put in pci/quirks.c. Because the behavior of the global pci_fixups_header array is maintained at that file. When system inits, pci driver would load fixup devices before driver attached. So it should define the fixup header under pci/quirks.c. After do some tests in my side. This quirk works well. Thanks, Rui -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html