Merge tag 'v3.10.97' into update
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / drivers / usb / host / xhci.c
index 1316a03c1a43097ed6ee88750e230aa01ae9c1c2..10a9804a08c2962ca8c78e660f1efe7083701f16 100644 (file)
@@ -5117,6 +5117,9 @@ static int __init xhci_hcd_init(void)
 {
        int retval;
 
+       if (usb_disabled())
+               return -ENODEV;
+
        retval = xhci_register_pci();
        if (retval < 0) {
                printk(KERN_DEBUG "Problem registering PCI driver.");
@@ -5156,9 +5159,6 @@ static int __init xhci_hcd_init(void)
        /* xhci_run_regs has eight fields and embeds 128 xhci_intr_regs */
        BUILD_BUG_ON(sizeof(struct xhci_run_regs) != (8+8*128)*32/8);
 
-       if (usb_disabled())
-               return -ENODEV;
-
        return 0;
 
 #ifdef CONFIG_MTK_XHCI