Lines Matching defs:cdns
31 static int __cdns3_host_init(struct cdns3 *cdns)
37 cdns3_drd_host_on(cdns);
41 dev_err(cdns->dev, "couldn't allocate xHCI device\n");
45 xhci->dev.parent = cdns->dev;
46 cdns->host_dev = xhci;
48 ret = platform_device_add_resources(xhci, cdns->xhci_res,
51 dev_err(cdns->dev, "couldn't add resources to xHCI device\n");
55 cdns->xhci_plat_data = kmemdup(&xhci_plat_cdns3_xhci,
57 if (!cdns->xhci_plat_data) {
62 if (cdns->pdata && (cdns->pdata->quirks & CDNS3_DEFAULT_PM_RUNTIME_ALLOW))
63 cdns->xhci_plat_data->quirks |= XHCI_DEFAULT_PM_RUNTIME_ALLOW;
65 ret = platform_device_add_data(xhci, cdns->xhci_plat_data,
72 dev_err(cdns->dev, "failed to register xHCI device\n");
79 cdns->xhci_regs = hcd->regs;
84 kfree(cdns->xhci_plat_data);
116 static void cdns3_host_exit(struct cdns3 *cdns)
118 kfree(cdns->xhci_plat_data);
119 platform_device_unregister(cdns->host_dev);
120 cdns->host_dev = NULL;
121 cdns3_drd_host_off(cdns);
124 int cdns3_host_init(struct cdns3 *cdns)
128 rdrv = devm_kzalloc(cdns->dev, sizeof(*rdrv), GFP_KERNEL);
137 cdns->roles[USB_ROLE_HOST] = rdrv;