Re: [PATCH] Don't touch USB controllers with MMIO disabled in quirks

From: David Brownell
Date: Mon Oct 31 2005 - 23:52:15 EST


On Monday 31 October 2005 8:03 pm, Paul Mackerras wrote:

> static void __devinit quirk_usb_early_handoff(struct pci_dev *pdev)
> {
> + u16 cmd;
> +
> + if (pci_read_config_word(pdev, PCI_COMMAND, &cmd) ||
> + (cmd & PCI_COMMAND_MEMORY) == 0)

I suspect that should be

(tabs) || (cmd & (PCI_COMMAND_MEMORY|PCI_COMMAND_IO)) == 0

Admittedly that'll matter only for UHCI, which isn't much used out of
x86 and ia64 ... but testing for both is more correct. Other than that,
this looks good to me.

- Dave


> + return;
> if (pdev->class == PCI_CLASS_SERIAL_USB_UHCI)
> quirk_usb_handoff_uhci(pdev);
> else if (pdev->class == PCI_CLASS_SERIAL_USB_OHCI)
>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/