Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/uhci-rhd/port.c

    rc0cea918 rf9c03b5  
    6868 * @return Error code. (Always EOK)
    6969 */
    70 static inline void uhci_port_write_status(uhci_port_t *port, port_status_t val)
    71 {
    72         assert(port);
    73         pio_write_16(port->address, val);
     70static inline void uhci_port_write_status(
     71    uhci_port_t *port, port_status_t value)
     72{
     73        assert(port);
     74        pio_write_16(port->address, value);
    7475}
    7576/*----------------------------------------------------------------------------*/
     
    100101        port->rh = rh;
    101102
    102         int ret =
    103             usb_hc_connection_initialize_from_device(&port->hc_connection, rh);
    104         if (ret != EOK) {
     103        int rc = usb_hc_connection_initialize_from_device(
     104            &port->hc_connection, rh);
     105        if (rc != EOK) {
    105106                usb_log_error("Failed to initialize connection to HC.");
    106                 return ret;
     107                return rc;
    107108        }
    108109
     
    237238        /* Enable the port. */
    238239        uhci_port_set_enabled(port, true);
     240
    239241        return EOK;
    240242}
     
    269271        usb_log_info("New device at port %u, address %d (handle %llu).\n",
    270272            port->number, dev_addr, port->attached_device);
     273
    271274        return EOK;
    272275}
     
    310313        /* Write new value. */
    311314        uhci_port_write_status(port, port_status);
    312 
    313         /* Wait for port to become enabled */
    314         do {
    315                 async_usleep(1000);
    316                 port_status = uhci_port_read_status(port);
    317         } while ((port_status & STATUS_CONNECTED) &&
    318             !(port_status & STATUS_ENABLED));
    319315
    320316        usb_log_debug("%s: %sabled port.\n",
Note: See TracChangeset for help on using the changeset viewer.