lkml.org 
[lkml]   [2012]   [Mar]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC PATCH 2/3] usb, PCI: remove disable/enable device with non-xhci quirk
    On Thu, Mar 01, 2012 at 11:24:02AM -0800, Yinghai Lu wrote:
    > | commit cab928ee1f221c9cc48d6615070fefe2e444384a
    > | USB: Fix handoff when BIOS disables host PCI device.
    >
    > mention only need to do disable/enable for xhci controller.
    >
    > So just remove that for non-xhci controller and restore old behavior for them.

    As I said, we do need to do the enable/disable for all USB hosts. Jesse
    Barnes confirms that the PCI core doesn't do that for us, so we can't
    rely on the BIOS always enabling the PCI device. I don't think we need
    this patch, because we should always be doing the enable/disable for all
    USB hosts. We just never had a BIOS that caused this bug to be
    discovered until the xHCI BIOS for the Intel system in question.

    > Signed-off-by: Yinghai Lu <yinghai@kernel.org>
    >
    > ---
    > drivers/usb/host/pci-quirks.c | 18 ------------------
    > 1 file changed, 18 deletions(-)
    >
    > Index: linux-2.6/drivers/usb/host/pci-quirks.c
    > ===================================================================
    > --- linux-2.6.orig/drivers/usb/host/pci-quirks.c
    > +++ linux-2.6/drivers/usb/host/pci-quirks.c
    > @@ -889,13 +889,7 @@ static void __devinit quirk_usb_early_ha
    > if (pdev->vendor == 0x184e) /* vendor Netlogic */
    > return;
    >
    > - if (pci_enable_device(pdev) < 0) {
    > - dev_warn(&pdev->dev, "Can't enable PCI device, "
    > - "BIOS handoff failed.\n");
    > - return;
    > - }
    > quirk_usb_handoff_uhci(pdev);
    > - pci_disable_device(pdev);
    > }
    > DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,
    > PCI_CLASS_SERIAL_USB_UHCI, 0, quirk_usb_early_handoff_uhci);
    > @@ -908,13 +902,7 @@ static void __devinit quirk_usb_early_ha
    > if (pdev->vendor == 0x184e) /* vendor Netlogic */
    > return;
    >
    > - if (pci_enable_device(pdev) < 0) {
    > - dev_warn(&pdev->dev, "Can't enable PCI device, "
    > - "BIOS handoff failed.\n");
    > - return;
    > - }
    > quirk_usb_handoff_ohci(pdev);
    > - pci_disable_device(pdev);
    > }
    > DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,
    > PCI_CLASS_SERIAL_USB_OHCI, 0, quirk_usb_early_handoff_ohci);
    > @@ -924,13 +912,7 @@ static void __devinit quirk_usb_early_ha
    > if (pdev->vendor == 0x184e) /* vendor Netlogic */
    > return;
    >
    > - if (pci_enable_device(pdev) < 0) {
    > - dev_warn(&pdev->dev, "Can't enable PCI device, "
    > - "BIOS handoff failed.\n");
    > - return;
    > - }
    > quirk_usb_handoff_ehci(pdev);
    > - pci_disable_device(pdev);
    > }
    > DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,
    > PCI_CLASS_SERIAL_USB_EHCI, 0, quirk_usb_early_handoff_ehci);


    \
     
     \ /
      Last update: 2012-03-01 21:15    [W:0.023 / U:180.240 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site