Changes in uspace/drv/bus/usb/uhci/hc.c [8300c72:bb97118] in mainline
- File:
-
- 1 edited
-
uspace/drv/bus/usb/uhci/hc.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/uhci/hc.c
r8300c72 rbb97118 1 1 /* 2 * Copyright (c) 2025 Jiri Svoboda3 2 * Copyright (c) 2011 Jan Vesely 4 3 * Copyright (c) 2018 Ondrej Hlavaty, Petr Manek … … 189 188 190 189 if (instance->hw_failures < UHCI_ALLOWED_HW_FAIL) { 191 /* reinitialize hw, this triggers virtual disconnect */190 /* reinitialize hw, this triggers virtual disconnect*/ 192 191 hc_init_hw(instance); 193 192 } else { … … 266 265 //TODO Implement 267 266 return ENOTSUP; 268 }269 270 /** Quiesce host controller.271 *272 * @param[in] instance Host controller structure to use.273 */274 int hc_quiesce(hc_device_t *hcd)275 {276 hc_t *instance = hcd_to_hc(hcd);277 uhci_regs_t *registers = instance->registers;278 279 /* Reset everything, who knows what touched it before us */280 pio_write_16(®isters->usbcmd, UHCI_CMD_GLOBAL_RESET);281 fibril_usleep(50000); /* 50ms according to USB spec(root hub reset) */282 pio_write_16(®isters->usbcmd, 0);283 284 /* Reset hc, all states and counters. Hope that hw is not broken */285 pio_write_16(®isters->usbcmd, UHCI_CMD_HCRESET);286 do {287 fibril_usleep(10);288 } while ((pio_read_16(®isters->usbcmd) & UHCI_CMD_HCRESET) != 0);289 290 return EOK;291 267 } 292 268
Note:
See TracChangeset
for help on using the changeset viewer.
