Skip to content

Commit

Permalink
usb: xhci: xhci-plat: Add XHCI_RESET_ON_RESUME quirk for Phytium Pe220x
Browse files Browse the repository at this point in the history
Phytium Pe220x xHCI host controller does not have suspend/resume
support. Therefore, use of the XHCI_RESET_ON_RESUME quirk is
mandatory in order to avoid failures after resume.

Signed-off-by: Wang Zhimin <[email protected]>
Signed-off-by: Chen Zhenhua <[email protected]>
  • Loading branch information
Chen Zhenhua authored and wangzhimin1179 committed May 11, 2024
1 parent 3ae09f2 commit 44abc8f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions drivers/usb/host/xhci-plat.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,10 @@ static const struct xhci_plat_priv xhci_plat_brcm = {
.quirks = XHCI_RESET_ON_RESUME | XHCI_SUSPEND_RESUME_CLKS,
};

static const struct xhci_plat_priv xhci_plat_phytium_pe220x = {
.quirks = XHCI_RESET_ON_RESUME,
};

static const struct of_device_id usb_xhci_of_match[] = {
{
.compatible = "generic-xhci",
Expand All @@ -133,6 +137,9 @@ static const struct of_device_id usb_xhci_of_match[] = {
}, {
.compatible = "brcm,bcm7445-xhci",
.data = &xhci_plat_brcm,
}, {
.compatible = "phytium,pe220x-xhci",
.data = &xhci_plat_phytium_pe220x,
},
{},
};
Expand Down Expand Up @@ -396,6 +403,8 @@ static int xhci_generic_plat_probe(struct platform_device *pdev)

if (pdev->dev.of_node)
priv_match = of_device_get_match_data(&pdev->dev);
else if (has_acpi_companion(&pdev->dev))
priv_match = acpi_device_get_match_data(&pdev->dev);
else
priv_match = dev_get_platdata(&pdev->dev);

Expand Down Expand Up @@ -554,6 +563,7 @@ EXPORT_SYMBOL_GPL(xhci_plat_pm_ops);
static const struct acpi_device_id usb_xhci_acpi_match[] = {
/* XHCI-compliant USB Controller */
{ "PNP0D10", },
{ "PHYT0039", (kernel_ulong_t)&xhci_plat_phytium_pe220x },
{ }
};
MODULE_DEVICE_TABLE(acpi, usb_xhci_acpi_match);
Expand Down

0 comments on commit 44abc8f

Please sign in to comment.