Revert "xhci: Detect lpm incapable xHC USB3 roothub ports from ACPI tables"
This reverts commit 96562a23cf
which is
commit 74622f0a81d0c2bcfc39f9192b788124e8c7f0af upstream.
It breaks the android kernel abi and is not needed for android at this
point in time as the USB3 issues it resolves are not in Android devices.
If this is needed in the future, it can be brought back in an ABI-safe way.
Bug: 161946584
Change-Id: I8284b5237ebd06c9b2fe5f518a4edb6d1765b4f9
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
@@ -351,38 +351,8 @@ static void xhci_pme_acpi_rtd3_enable(struct pci_dev *dev)
|
||||
NULL);
|
||||
ACPI_FREE(obj);
|
||||
}
|
||||
|
||||
static void xhci_find_lpm_incapable_ports(struct usb_hcd *hcd, struct usb_device *hdev)
|
||||
{
|
||||
struct xhci_hcd *xhci = hcd_to_xhci(hcd);
|
||||
struct xhci_hub *rhub = &xhci->usb3_rhub;
|
||||
int ret;
|
||||
int i;
|
||||
|
||||
/* This is not the usb3 roothub we are looking for */
|
||||
if (hcd != rhub->hcd)
|
||||
return;
|
||||
|
||||
if (hdev->maxchild > rhub->num_ports) {
|
||||
dev_err(&hdev->dev, "USB3 roothub port number mismatch\n");
|
||||
return;
|
||||
}
|
||||
|
||||
for (i = 0; i < hdev->maxchild; i++) {
|
||||
ret = usb_acpi_port_lpm_incapable(hdev, i);
|
||||
|
||||
dev_dbg(&hdev->dev, "port-%d disable U1/U2 _DSM: %d\n", i + 1, ret);
|
||||
|
||||
if (ret >= 0) {
|
||||
rhub->ports[i]->lpm_incapable = ret;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
static void xhci_pme_acpi_rtd3_enable(struct pci_dev *dev) { }
|
||||
static void xhci_find_lpm_incapable_ports(struct usb_hcd *hcd, struct usb_device *hdev) { }
|
||||
#endif /* CONFIG_ACPI */
|
||||
|
||||
/* called during probe() after chip reset completes */
|
||||
@@ -418,10 +388,6 @@ static int xhci_pci_setup(struct usb_hcd *hcd)
|
||||
static int xhci_pci_update_hub_device(struct usb_hcd *hcd, struct usb_device *hdev,
|
||||
struct usb_tt *tt, gfp_t mem_flags)
|
||||
{
|
||||
/* Check if acpi claims some USB3 roothub ports are lpm incapable */
|
||||
if (!hdev->parent)
|
||||
xhci_find_lpm_incapable_ports(hcd, hdev);
|
||||
|
||||
return xhci_update_hub_device(hcd, hdev, tt, mem_flags);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user