Changeset b7fd2a0 in mainline for uspace/app/mkexfat/mkexfat.c
- Timestamp:
- 2018-01-13T03:10:29Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- a53ed3a
- Parents:
- 36f0738
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/mkexfat/mkexfat.c
r36f0738 rb7fd2a0 112 112 vbr_checksum_update(void const *octets, size_t nbytes, uint32_t *checksum); 113 113 114 static int114 static errno_t 115 115 ebs_write(service_id_t service_id, exfat_cfg_t *cfg, 116 116 int base, uint32_t *chksum); 117 117 118 static int118 static errno_t 119 119 bitmap_write(service_id_t service_id, exfat_cfg_t *cfg); 120 120 … … 284 284 } 285 285 286 static int286 static errno_t 287 287 bootsec_write(service_id_t service_id, exfat_cfg_t *cfg) 288 288 { … … 290 290 uint32_t vbr_checksum; 291 291 uint32_t *chksum_sector; 292 int rc;292 errno_t rc; 293 293 unsigned idx; 294 294 … … 346 346 * @return EOK on success or an error code. 347 347 */ 348 static int348 static errno_t 349 349 ebs_write(service_id_t service_id, exfat_cfg_t *cfg, int base, 350 350 uint32_t *chksum) … … 352 352 uint32_t *ebs = calloc(cfg->sector_size, sizeof(uint8_t)); 353 353 int i; 354 int rc;354 errno_t rc; 355 355 356 356 if (!ebs) … … 399 399 * @return EOK on success or an error code. 400 400 */ 401 static int401 static errno_t 402 402 fat_initialize(service_id_t service_id, exfat_cfg_t *cfg) 403 403 { 404 404 unsigned long i; 405 405 uint32_t *pfat; 406 int rc;406 errno_t rc; 407 407 408 408 pfat = calloc(cfg->sector_size, 1); … … 439 439 * @return EOK on success or an error code. 440 440 */ 441 static int441 static errno_t 442 442 fat_allocate_clusters(service_id_t service_id, exfat_cfg_t *cfg, 443 443 uint32_t cur_cls, unsigned long ncls) 444 444 { 445 int rc;445 errno_t rc; 446 446 unsigned const fat_entries = cfg->sector_size / sizeof(uint32_t); 447 447 aoff64_t fat_sec = cur_cls / fat_entries + FAT_SECTOR_START; … … 496 496 * @return EOK on success or an error code. 497 497 */ 498 static int498 static errno_t 499 499 bitmap_write(service_id_t service_id, exfat_cfg_t *cfg) 500 500 { 501 501 unsigned long i, sec; 502 502 unsigned long allocated_cls; 503 int rc = EOK;503 errno_t rc = EOK; 504 504 bool need_reset = true; 505 505 … … 544 544 545 545 /** Write the upcase table to disk. */ 546 static int546 static errno_t 547 547 upcase_table_write(service_id_t service_id, exfat_cfg_t *cfg) 548 548 { 549 int rc = EOK;549 errno_t rc = EOK; 550 550 aoff64_t start_sec, nsecs, i; 551 551 uint8_t *table_ptr; … … 595 595 * @return EOK on success or an error code. 596 596 */ 597 static int597 static errno_t 598 598 root_dentries_write(service_id_t service_id, exfat_cfg_t *cfg) 599 599 { … … 601 601 aoff64_t rootdir_sec; 602 602 uint16_t wlabel[EXFAT_VOLLABEL_LEN + 1]; 603 int rc;603 errno_t rc; 604 604 uint8_t *data; 605 605 unsigned long i; … … 758 758 char *dev_path; 759 759 service_id_t service_id; 760 int rc;760 errno_t rc; 761 761 int c, opt_ind; 762 762 aoff64_t user_fs_size = 0;
Note:
See TracChangeset
for help on using the changeset viewer.