• Home
  • Raw
  • Download

Lines Matching refs:cdns

66 static int __cdns_host_init(struct cdns *cdns)  in __cdns_host_init()  argument
72 cdns_drd_host_on(cdns); in __cdns_host_init()
76 dev_err(cdns->dev, "couldn't allocate xHCI device\n"); in __cdns_host_init()
80 xhci->dev.parent = cdns->dev; in __cdns_host_init()
81 cdns->host_dev = xhci; in __cdns_host_init()
83 ret = platform_device_add_resources(xhci, cdns->xhci_res, in __cdns_host_init()
86 dev_err(cdns->dev, "couldn't add resources to xHCI device\n"); in __cdns_host_init()
90 if (cdns->version < CDNSP_CONTROLLER_V2) in __cdns_host_init()
91 cdns->xhci_plat_data = kmemdup(&xhci_plat_cdns3_xhci, in __cdns_host_init()
94 cdns->xhci_plat_data = kmemdup(&xhci_plat_cdnsp_xhci, in __cdns_host_init()
97 if (!cdns->xhci_plat_data) { in __cdns_host_init()
102 if (cdns->pdata && (cdns->pdata->quirks & CDNS3_DEFAULT_PM_RUNTIME_ALLOW)) in __cdns_host_init()
103 cdns->xhci_plat_data->quirks |= XHCI_DEFAULT_PM_RUNTIME_ALLOW; in __cdns_host_init()
105 ret = platform_device_add_data(xhci, cdns->xhci_plat_data, in __cdns_host_init()
112 dev_err(cdns->dev, "failed to register xHCI device\n"); in __cdns_host_init()
119 cdns->xhci_regs = hcd->regs; in __cdns_host_init()
124 kfree(cdns->xhci_plat_data); in __cdns_host_init()
130 static void cdns_host_exit(struct cdns *cdns) in cdns_host_exit() argument
132 kfree(cdns->xhci_plat_data); in cdns_host_exit()
133 platform_device_unregister(cdns->host_dev); in cdns_host_exit()
134 cdns->host_dev = NULL; in cdns_host_exit()
135 cdns_drd_host_off(cdns); in cdns_host_exit()
138 int cdns_host_init(struct cdns *cdns) in cdns_host_init() argument
142 rdrv = devm_kzalloc(cdns->dev, sizeof(*rdrv), GFP_KERNEL); in cdns_host_init()
151 cdns->roles[USB_ROLE_HOST] = rdrv; in cdns_host_init()