Lines Matching refs:esc
115 ehci_softc_t *esc; in tegra_ehci_detach() local
124 esc = &sc->ehci_softc; in tegra_ehci_detach()
127 if (esc->sc_flags & EHCI_SCFLG_DONEINIT) in tegra_ehci_detach()
128 ehci_detach(esc); in tegra_ehci_detach()
129 if (esc->sc_intr_hdl != NULL) in tegra_ehci_detach()
130 bus_teardown_intr(dev, esc->sc_irq_res, in tegra_ehci_detach()
131 esc->sc_intr_hdl); in tegra_ehci_detach()
139 usb_bus_mem_free_all(&esc->sc_bus, &ehci_iterate_hw_softc); in tegra_ehci_detach()
148 ehci_softc_t *esc; in tegra_ehci_attach() local
154 esc = &sc->ehci_softc; in tegra_ehci_attach()
222 esc->sc_vendor_get_port_speed = ehci_get_port_speed_hostc; in tegra_ehci_attach()
223 esc->sc_vendor_post_reset = tegra_ehci_post_reset; in tegra_ehci_attach()
224 esc->sc_io_tag = rman_get_bustag(sc->ehci_mem_res); in tegra_ehci_attach()
225 esc->sc_bus.parent = dev; in tegra_ehci_attach()
226 esc->sc_bus.devices = esc->sc_devices; in tegra_ehci_attach()
227 esc->sc_bus.devices_max = EHCI_MAX_DEVICES; in tegra_ehci_attach()
228 esc->sc_bus.dma_bits = 32; in tegra_ehci_attach()
231 rv = usb_bus_mem_alloc_all(&esc->sc_bus, USB_GET_DMA_TAG(dev), in tegra_ehci_attach()
244 rv = bus_space_subregion(esc->sc_io_tag, in tegra_ehci_attach()
246 TEGRA_EHCI_REG_OFF, TEGRA_EHCI_REG_SIZE, &esc->sc_io_hdl); in tegra_ehci_attach()
255 NULL, (driver_intr_t *)ehci_interrupt, esc, &esc->sc_intr_hdl); in tegra_ehci_attach()
262 esc->sc_bus.bdev = device_add_child(dev, "usbus", DEVICE_UNIT_ANY); in tegra_ehci_attach()
263 if (esc->sc_bus.bdev == NULL) { in tegra_ehci_attach()
267 device_set_ivars(esc->sc_bus.bdev, &esc->sc_bus); in tegra_ehci_attach()
269 esc->sc_id_vendor = USB_VENDOR_FREESCALE; in tegra_ehci_attach()
270 strlcpy(esc->sc_vendor, "Nvidia", sizeof(esc->sc_vendor)); in tegra_ehci_attach()
273 esc->sc_flags |= EHCI_SCFLG_TT; in tegra_ehci_attach()
274 esc->sc_flags |= EHCI_SCFLG_NORESTERM; in tegra_ehci_attach()
275 rv = ehci_init(esc); in tegra_ehci_attach()
281 esc->sc_flags |= EHCI_SCFLG_DONEINIT; in tegra_ehci_attach()
284 rv = device_probe_and_attach(esc->sc_bus.bdev); in tegra_ehci_attach()