Lines Matching +full:usb2 +full:- +full:lpm +full:- +full:disable

1 // SPDX-License-Identifier: GPL-2.0
3 * host.c - DesignWare USB3 DRD Controller Host Glue
5 * Copyright (C) 2011 Texas Instruments Incorporated - https://www.ti.com
19 struct platform_device *pdev = to_platform_device(dwc->dev); in dwc3_host_fill_xhci_irq_res()
20 struct device_node *np = dev_of_node(&pdev->dev); in dwc3_host_fill_xhci_irq_res()
22 dwc->xhci_resources[1].start = irq; in dwc3_host_fill_xhci_irq_res()
23 dwc->xhci_resources[1].end = irq; in dwc3_host_fill_xhci_irq_res()
24 dwc->xhci_resources[1].flags = IORESOURCE_IRQ | irq_get_trigger_type(irq); in dwc3_host_fill_xhci_irq_res()
26 dwc->xhci_resources[1].name = of_node_full_name(pdev->dev.of_node); in dwc3_host_fill_xhci_irq_res()
28 dwc->xhci_resources[1].name = name; in dwc3_host_fill_xhci_irq_res()
33 struct platform_device *dwc3_pdev = to_platform_device(dwc->dev); in dwc3_host_get_irq()
42 if (irq == -EPROBE_DEFER) in dwc3_host_get_irq()
51 if (irq == -EPROBE_DEFER) in dwc3_host_get_irq()
61 irq = -EINVAL; in dwc3_host_get_irq()
78 xhci = platform_device_alloc("xhci-hcd", PLATFORM_DEVID_AUTO); in dwc3_host_init()
80 dev_err(dwc->dev, "couldn't allocate xHCI device\n"); in dwc3_host_init()
81 return -ENOMEM; in dwc3_host_init()
84 xhci->dev.parent = dwc->dev; in dwc3_host_init()
86 dwc->xhci = xhci; in dwc3_host_init()
88 ret = platform_device_add_resources(xhci, dwc->xhci_resources, in dwc3_host_init()
91 dev_err(dwc->dev, "couldn't add resources to xHCI device\n"); in dwc3_host_init()
97 if (dwc->usb3_lpm_capable) in dwc3_host_init()
98 props[prop_idx++] = PROPERTY_ENTRY_BOOL("usb3-lpm-capable"); in dwc3_host_init()
100 if (dwc->usb2_lpm_disable) in dwc3_host_init()
101 props[prop_idx++] = PROPERTY_ENTRY_BOOL("usb2-lpm-disable"); in dwc3_host_init()
105 * where Port Disable command doesn't work. in dwc3_host_init()
107 * The suggested workaround is that we avoid Port Disable in dwc3_host_init()
113 props[prop_idx++] = PROPERTY_ENTRY_BOOL("quirk-broken-port-ped"); in dwc3_host_init()
116 ret = device_create_managed_software_node(&xhci->dev, props, NULL); in dwc3_host_init()
118 dev_err(dwc->dev, "failed to add properties to xHCI\n"); in dwc3_host_init()
125 dev_err(dwc->dev, "failed to register xHCI device\n"); in dwc3_host_init()
137 platform_device_unregister(dwc->xhci); in dwc3_host_exit()
138 dwc->xhci = NULL; in dwc3_host_exit()