Changeset 1433ecda in mainline for uspace/drv/block


Ignore:
Timestamp:
2018-04-04T15:42:37Z (8 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
2c4e1cc
Parents:
47b2d7e3
Message:

Fix cstyle: make ccheck-fix and commit only files where all the changes are good.

Location:
uspace/drv/block
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/block/ahci/ahci.c

    r47b2d7e3 r1433ecda  
    978978        sata->cmd_header->cmdtableu = HI(phys);
    979979        sata->cmd_header->cmdtable = LO(phys);
    980         sata->cmd_table = (uint32_t*) virt_table;
     980        sata->cmd_table = (uint32_t *) virt_table;
    981981
    982982        return sata;
     
    10761076        fibril_mutex_unlock(&sata_devices_count_lock);
    10771077
    1078         rc= ddf_fun_set_name(sata->fun, sata_dev_name);
     1078        rc = ddf_fun_set_name(sata->fun, sata_dev_name);
    10791079        if (rc != EOK) {
    10801080                ddf_msg(LVL_ERROR, "Failed setting function name.");
  • uspace/drv/block/ata_bd/ata_bd.c

    r47b2d7e3 r1433ecda  
    428428
    429429                d->blocks =
    430                      (uint32_t) idata.total_lba28_0 |
     430                    (uint32_t) idata.total_lba28_0 |
    431431                    ((uint32_t) idata.total_lba28_1 << 16);
    432432        } else {
     
    439439
    440440                d->blocks =
    441                      (uint64_t) idata.total_lba48_0 |
     441                    (uint64_t) idata.total_lba48_0 |
    442442                    ((uint64_t) idata.total_lba48_1 << 16) |
    443443                    ((uint64_t) idata.total_lba48_2 << 32) |
     
    461461        for (i = 0; i < len; ++i) {
    462462                c = model[i];
    463                 if (c >= 0x80) c = '?';
     463                if (c >= 0x80)
     464                        c = '?';
    464465
    465466                chr_encode(c, d->model, &pos, 40);
     
    795796        pio_write_8(&ctrl->cmd->drive_head, drv_head);
    796797
    797         if (wait_status(ctrl, 0, ~(SR_BSY|SR_DRQ), NULL, TIMEOUT_BSY) != EOK) {
     798        if (wait_status(ctrl, 0, ~(SR_BSY | SR_DRQ), NULL, TIMEOUT_BSY) != EOK) {
    798799                fibril_mutex_unlock(&ctrl->lock);
    799800                return EIO;
     
    12631264        while ((status & ~n_reset) != 0 || (status & set) != set) {
    12641265                --cnt;
    1265                 if (cnt <= 0) break;
     1266                if (cnt <= 0)
     1267                        break;
    12661268
    12671269                status = pio_read_8(&ctrl->cmd->status);
     
    12721274                async_usleep(10000);
    12731275                --cnt;
    1274                 if (cnt <= 0) break;
     1276                if (cnt <= 0)
     1277                        break;
    12751278
    12761279                status = pio_read_8(&ctrl->cmd->status);
  • uspace/drv/block/usbmast/bo_trans.c

    r47b2d7e3 r1433ecda  
    116116                usb_pipe_clear_halt(
    117117                    usb_device_get_default_pipe(mfun->mdev->usb_dev), dpipe);
    118         } else if (rc != EOK) {
     118        } else if (rc != EOK) {
    119119                usb_log_error("Failed to transfer data: %s", str_error(rc));
    120120                return EIO;
     
    141141        if (csw.dCSWTag != tag) {
    142142                usb_log_error("Received CSW with incorrect tag. (expected: %"
    143                     PRIX32" received: %"PRIx32, tag, csw.dCSWTag);
     143                    PRIX32 " received: %" PRIx32, tag, csw.dCSWTag);
    144144                return EIO;
    145145        }
  • uspace/drv/block/usbmast/main.c

    r47b2d7e3 r1433ecda  
    179179        usb_log_debug("Get LUN count...");
    180180        mdev->lun_count = usb_masstor_get_lun_count(mdev);
    181         mdev->luns = calloc(mdev->lun_count, sizeof(ddf_fun_t*));
     181        mdev->luns = calloc(mdev->lun_count, sizeof(ddf_fun_t *));
    182182        if (mdev->luns == NULL) {
    183183                usb_log_error("Failed allocating luns table.");
  • uspace/drv/block/usbmast/scsi_ms.c

    r47b2d7e3 r1433ecda  
    196196        if (cmd.rcvd_size < SCSI_STD_INQUIRY_DATA_MIN_SIZE) {
    197197                usb_log_error("SCSI Inquiry response too short (%zu).",
    198                      cmd.rcvd_size);
     198                    cmd.rcvd_size);
    199199                return EIO;
    200200        }
     
    306306        if (cmd.rcvd_size < sizeof(data)) {
    307307                usb_log_error("SCSI Read Capacity response too short (%zu).",
    308                      cmd.rcvd_size);
     308                    cmd.rcvd_size);
    309309                return EIO;
    310310        }
     
    349349        rc = usbmast_run_cmd(mfun, &cmd);
    350350
    351         if (rc != EOK) {
     351        if (rc != EOK) {
    352352                usb_log_error("Read (10) transport failed, device %s: %s.",
    353353                    usb_device_get_name(mfun->mdev->usb_dev), str_error(rc));
Note: See TracChangeset for help on using the changeset viewer.