Messages in this thread | | | Date | Mon, 23 Jul 2012 18:45:09 +0400 | From | Sergei Shtylyov <> | Subject | Re: [PATCH 1/2] xhci: provide usb_disable_xhci_ports function for Intel chipsets. |
| |
Hello.
On 07/23/2012 03:46 PM, Denis Turischev wrote:
> Some devices with Intel Panther Point chipset may require switchover > usb ports from XHCI back to EHCI controller before shutdown. > Overwise various BIOS bugs related to power management may be > triggered.
> Signed-off-by: Denis Turischev <denis@compulab.co.il> > --- > drivers/usb/host/pci-quirks.c | 14 ++++++++++++++ > drivers/usb/host/pci-quirks.h | 1 + > 2 files changed, 15 insertions(+)
> diff --git a/drivers/usb/host/pci-quirks.c b/drivers/usb/host/pci-quirks.c > index df0828c..b19a84a 100644 > --- a/drivers/usb/host/pci-quirks.c > +++ b/drivers/usb/host/pci-quirks.c > @@ -800,6 +800,20 @@ void usb_enable_xhci_ports(struct pci_dev *xhci_pdev) > } > EXPORT_SYMBOL_GPL(usb_enable_xhci_ports); > > +void usb_disable_xhci_ports(struct pci_dev *xhci_pdev) > +{ > + u32 ports_available; > + > + ports_available = 0x0;
Why not make it an initializer? And why do you need the variable at all?
> + > + pci_write_config_dword(xhci_pdev, USB_INTEL_USB3_PSSEN, > + cpu_to_le32(ports_available));
cpu_to_le32() not needed.
> + > + pci_write_config_dword(xhci_pdev, USB_INTEL_XUSB2PR, > + cpu_to_le32(ports_available)); > +} > +EXPORT_SYMBOL_GPL(usb_disable_xhci_ports); > + > /** > * PCI Quirks for xHCI. > *
WBR, Sergei
| |