Skip to content

Commit

Permalink
usb: dwc3: pci: Add platform data for Synopsys HAPS
Browse files Browse the repository at this point in the history
Add platform data and set usb3_lpm_capable and has_lpm_erratum.

Cc: <stable@vger.kernel.org> # v3.18+
Signed-off-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
  • Loading branch information
John Youn authored and Felipe Balbi committed Oct 9, 2015
1 parent 9a5a078 commit bb7f3d6
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions drivers/usb/dwc3/dwc3-pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,21 @@ static int dwc3_pci_quirks(struct pci_dev *pdev)
}
}

if (pdev->vendor == PCI_VENDOR_ID_SYNOPSYS &&
(pdev->device == PCI_DEVICE_ID_SYNOPSYS_HAPSUSB3 ||
pdev->device == PCI_DEVICE_ID_SYNOPSYS_HAPSUSB3_AXI ||
pdev->device == PCI_DEVICE_ID_SYNOPSYS_HAPSUSB31)) {

struct dwc3_platform_data pdata;

memset(&pdata, 0, sizeof(pdata));
pdata.usb3_lpm_capable = true;
pdata.has_lpm_erratum = true;

return platform_device_add_data(pci_get_drvdata(pdev), &pdata,
sizeof(pdata));
}

return 0;
}

Expand Down

0 comments on commit bb7f3d6

Please sign in to comment.