Changeset e247d83 in mainline for uspace/drv/uhci-hcd/hc.c


Ignore:
Timestamp:
2011-05-23T14:04:51Z (14 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
563ead9
Parents:
8953514
Message:

Const, type-casting and other minor fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/uhci-hcd/hc.c

    r8953514 re247d83  
    8585        /* allow access to hc control registers */
    8686        regs_t *io;
    87         ret = pio_enable(regs, reg_size, (void**)&io);
     87        ret = pio_enable(regs, reg_size, (void **)&io);
    8888        CHECK_RET_RETURN(ret,
    8989            "Failed(%d) to gain access to registers at %p: %s.\n",
     
    143143        }
    144144
    145         uint16_t status = pio_read_16(&registers->usbcmd);
     145        const uint16_t status = pio_read_16(&registers->usbcmd);
    146146        if (status != 0)
    147147                usb_log_warning("Previous command value: %x.\n", status);
     
    212212        /* Init USB frame list page*/
    213213        instance->frame_list = get_page();
    214         ret = instance ? EOK : ENOMEM;
     214        ret = instance->frame_list ? EOK : ENOMEM;
    215215        CHECK_RET_RETURN(ret, "Failed to get frame list page.\n");
    216216        usb_log_debug("Initialized frame list at %p.\n", instance->frame_list);
     
    277277                &instance->transfers_control_slow);
    278278
    279         /*FSBR*/
     279        /*FSBR, This feature is not needed (adds no benefit) and is supposedly
     280         * buggy on certain hw, enable at your own risk. */
    280281#ifdef FSBR
    281282        transfer_list_set_next(&instance->transfers_bulk_full,
     
    428429                }
    429430
    430                 uintptr_t frame_list =
     431                const uintptr_t frame_list =
    431432                    pio_read_32(&instance->registers->flbaseadd) & ~0xfff;
    432433                if (frame_list != addr_to_phys(instance->frame_list)) {
Note: See TracChangeset for help on using the changeset viewer.