Changeset 7c3fb9b in mainline for uspace/drv/bus/usb/uhci


Ignore:
Timestamp:
2018-05-17T08:29:01Z (8 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
6ff23ff
Parents:
fac0ac7
git-author:
Jiri Svoboda <jiri@…> (2018-05-16 17:28:17)
git-committer:
Jiri Svoboda <jiri@…> (2018-05-17 08:29:01)
Message:

Fix block comment formatting (ccheck).

Location:
uspace/drv/bus/usb/uhci
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/uhci/hw_struct/queue_head.h

    rfac0ac7 r7c3fb9b  
    7878static inline void qh_set_next_qh(qh_t *instance, qh_t *next)
    7979{
    80         /* Physical address has to be below 4GB,
     80        /*
     81         * Physical address has to be below 4GB,
    8182         * it is an UHCI limitation and malloc32
    82          * should guarantee this */
     83         * should guarantee this
     84         */
    8385        const uint32_t pa = addr_to_phys(next);
    8486        if (pa) {
     
    98100static inline void qh_set_element_td(qh_t *instance, td_t *td)
    99101{
    100         /* Physical address has to be below 4GB,
     102        /*
     103         * Physical address has to be below 4GB,
    101104         * it is an UHCI limitation and malloc32
    102          * should guarantee this */
     105         * should guarantee this
     106         */
    103107        const uint32_t pa = addr_to_phys(td);
    104108        if (pa) {
  • uspace/drv/bus/usb/uhci/hw_struct/transfer_descriptor.c

    rfac0ac7 r7c3fb9b  
    127127                return EIO;
    128128
    129         /* CRC or timeout error, like device not present or bad data,
    130          * it won't be reported unless err count reached zero */
     129        /*
     130         * CRC or timeout error, like device not present or bad data,
     131         * it won't be reported unless err count reached zero
     132         */
    131133        if ((instance->status & TD_STATUS_ERROR_CRC) != 0)
    132134                return EBADCHECKSUM;
     
    144146                return EIO;
    145147
    146         /* Stall might represent err count reaching zero or stall response from
    147          * the device. If err count reached zero, one of the above is reported*/
     148        /*
     149         * Stall might represent err count reaching zero or stall response from
     150         * the device. If err count reached zero, one of the above is reported
     151         */
    148152        if ((instance->status & TD_STATUS_ERROR_STALLED) != 0)
    149153                return ESTALL;
  • uspace/drv/bus/usb/uhci/hw_struct/transfer_descriptor.h

    rfac0ac7 r7c3fb9b  
    9090        volatile uint32_t buffer_ptr;
    9191
    92         /* According to UHCI design guide, there is 16 bytes of
     92        /*
     93         * According to UHCI design guide, there is 16 bytes of
    9394         * data available here.
    9495         * According to Linux kernel the hardware does not care,
  • uspace/drv/bus/usb/uhci/main.c

    rfac0ac7 r7c3fb9b  
    7676                return ENOMEM;
    7777
    78         /* See UHCI design guide page 45 for these values.
    79          * Write all WC bits in USB legacy register */
     78        /*
     79         * See UHCI design guide page 45 for these values.
     80         * Write all WC bits in USB legacy register
     81         */
    8082        return pci_config_space_write_16(parent_sess, 0xc0, 0xaf00);
    8183}
  • uspace/drv/bus/usb/uhci/uhci_batch.c

    rfac0ac7 r7c3fb9b  
    8787}
    8888
    89 /* Prepares batch for commiting.
     89/*
     90 * Prepares batch for committing.
    9091 *
    9192 * Determines the number of needed transfer descriptors (TDs).
  • uspace/drv/bus/usb/uhci/uhci_rh.c

    rfac0ac7 r7c3fb9b  
    153153        while ((port_status = pio_read_16(port)) & STATUS_IN_RESET)
    154154                ;
    155         /* PIO delay, should not be longer than 3ms as the device might
    156          * enter suspend state. */
     155        /*
     156         * PIO delay, should not be longer than 3ms as the device might
     157         * enter suspend state.
     158         */
    157159        udelay(10);
    158         /* Drop ConnectionChange as some UHCI hw
    159          * sets this bit after reset, that is incorrect */
     160        /*
     161         * Drop ConnectionChange as some UHCI hw
     162         * sets this bit after reset, that is incorrect
     163         */
    160164        port_status &= ~STATUS_WC_BITS;
    161165        pio_write_16(port, port_status | STATUS_ENABLED | STATUS_CONNECTED_CHANGED);
     
    376380                RH_DEBUG(hub, port, "Set port change flag (status %" PRIx16
    377381                    ")", status);
    378                 /* These are voluntary and don't have to be set
    379                  * there is no way we could do it on UHCI anyway */
     382                /*
     383                 * These are voluntary and don't have to be set
     384                 * there is no way we could do it on UHCI anyway
     385                 */
    380386                break;
    381387        default:
     
    459465                CLASS_REQ_OUT(USB_REQUEST_RECIPIENT_DEVICE, USB_HUB_REQUEST_CLEAR_FEATURE),
    460466                .name = "ClearHubFeature",
    461                 /* Hub features are overcurrent and supply good,
    462                  * this request may only clear changes that we never report*/
     467                /*
     468                 * Hub features are overcurrent and supply good,
     469                 * this request may only clear changes that we never report
     470                 */
    463471                .callback = req_nop,
    464472        },
     
    471479                CLASS_REQ_IN(USB_REQUEST_RECIPIENT_DEVICE, USB_HUB_REQUEST_GET_STATUS),
    472480                .name = "GetHubStatus",
    473                 /* UHCI can't report OC condition or,
    474                  * lose power source */
     481                /*
     482                 * UHCI can't report OC condition or,
     483                 * lose power source
     484                 */
    475485                .callback = virthub_base_get_null_status,
    476486        },
     
    483493                CLASS_REQ_OUT(USB_REQUEST_RECIPIENT_DEVICE, USB_HUB_REQUEST_SET_FEATURE),
    484494                .name = "SetHubFeature",
    485                 /* Hub features are overcurrent and supply good,
    486                  * this request may only set changes that we never report*/
     495                /*
     496                 * Hub features are overcurrent and supply good,
     497                 * this request may only set changes that we never report
     498                 */
    487499                .callback = req_nop,
    488500        },
Note: See TracChangeset for help on using the changeset viewer.