Changeset 8033f89 in mainline for uspace/drv/bus/usb/xhci/rh.c


Ignore:
Timestamp:
2018-01-23T12:41:22Z (7 years ago)
Author:
Ondřej Hlavatý <aearsis@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
e7e1fd3
Parents:
e546142
Message:

xhci: cstyle

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/xhci/rh.c

    re546142 r8033f89  
    155155                return ENOENT;
    156156
    157         unsigned psiv = (status & XHCI_REG_MASK(XHCI_PORT_PS)) >> XHCI_REG_SHIFT(XHCI_PORT_PS);
     157        unsigned psiv = (status & XHCI_REG_MASK(XHCI_PORT_PS))
     158            >> XHCI_REG_SHIFT(XHCI_PORT_PS);
    158159        const usb_speed_t speed = port->rh->hc->speeds[psiv].usb_speed;
    159160
     
    171172        port->device->rh_port = dev->port;
    172173
    173         usb_log_debug("Enumerating new %s-speed device on port %u.", usb_str_speed(dev->speed), dev->port);
     174        usb_log_debug("Enumerating new %s-speed device on port %u.",
     175            usb_str_speed(dev->speed), dev->port);
    174176
    175177        if ((err = bus_device_enumerate(dev))) {
     
    229231                 * standard mechanisms of register handling fails here.
    230232                 */
    231                 XHCI_REG_WR_FIELD(&port->regs->portsc, status & ~XHCI_REG_MASK(XHCI_PORT_PED), 32);
     233                XHCI_REG_WR_FIELD(&port->regs->portsc,
     234                    status & ~XHCI_REG_MASK(XHCI_PORT_PED), 32);
    232235
    233236                const bool connected = !!(status & XHCI_REG_MASK(XHCI_PORT_CCS));
     
    264267}
    265268
    266 void xhci_rh_set_ports_protocol(xhci_rh_t *rh, unsigned offset, unsigned count, unsigned major)
     269void xhci_rh_set_ports_protocol(xhci_rh_t *rh,
     270    unsigned offset, unsigned count, unsigned major)
    267271{
    268272        for (unsigned i = offset; i < offset + count; i++)
     
    285289                 * such ports.
    286290                 */
    287                 if (XHCI_REG_RD(port->regs, XHCI_PORT_CCS) && port->base.state == PORT_DISABLED)
     291                if (XHCI_REG_RD(port->regs, XHCI_PORT_CCS)
     292                    && port->base.state == PORT_DISABLED)
    288293                        usb_port_connected(&port->base, &rh_enumerate_device);
    289294        }
Note: See TracChangeset for help on using the changeset viewer.