Changes in uspace/lib/ext4/src/balloc.c [b7fd2a0:8d2dd7f2] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/ext4/src/balloc.c
rb7fd2a0 r8d2dd7f2 53 53 * 54 54 */ 55 errno_t ext4_balloc_free_block(ext4_inode_ref_t *inode_ref, uint32_t block_addr)55 int ext4_balloc_free_block(ext4_inode_ref_t *inode_ref, uint32_t block_addr) 56 56 { 57 57 ext4_filesystem_t *fs = inode_ref->fs; … … 65 65 /* Load block group reference */ 66 66 ext4_block_group_ref_t *bg_ref; 67 errno_t rc = ext4_filesystem_get_block_group_ref(fs, block_group, &bg_ref);67 int rc = ext4_filesystem_get_block_group_ref(fs, block_group, &bg_ref); 68 68 if (rc != EOK) 69 69 return rc; … … 118 118 } 119 119 120 static errno_t ext4_balloc_free_blocks_internal(ext4_inode_ref_t *inode_ref,120 static int ext4_balloc_free_blocks_internal(ext4_inode_ref_t *inode_ref, 121 121 uint32_t first, uint32_t count) 122 122 { … … 134 134 /* Load block group reference */ 135 135 ext4_block_group_ref_t *bg_ref; 136 errno_t rc = ext4_filesystem_get_block_group_ref(fs, block_group_first, &bg_ref);136 int rc = ext4_filesystem_get_block_group_ref(fs, block_group_first, &bg_ref); 137 137 if (rc != EOK) 138 138 return rc; … … 198 198 * 199 199 */ 200 errno_t ext4_balloc_free_blocks(ext4_inode_ref_t *inode_ref,200 int ext4_balloc_free_blocks(ext4_inode_ref_t *inode_ref, 201 201 uint32_t first, uint32_t count) 202 202 { 203 errno_t r;203 int r; 204 204 uint32_t gid; 205 205 uint64_t limit; … … 293 293 * 294 294 */ 295 static errno_t ext4_balloc_find_goal(ext4_inode_ref_t *inode_ref, uint32_t *goal)295 static int ext4_balloc_find_goal(ext4_inode_ref_t *inode_ref, uint32_t *goal) 296 296 { 297 297 *goal = 0; … … 307 307 /* If inode has some blocks, get last block address + 1 */ 308 308 if (inode_block_count > 0) { 309 errno_t rc = ext4_filesystem_get_inode_data_block_index(inode_ref,309 int rc = ext4_filesystem_get_inode_data_block_index(inode_ref, 310 310 inode_block_count - 1, goal); 311 311 if (rc != EOK) … … 325 325 /* Load block group reference */ 326 326 ext4_block_group_ref_t *bg_ref; 327 errno_t rc = ext4_filesystem_get_block_group_ref(inode_ref->fs,327 int rc = ext4_filesystem_get_block_group_ref(inode_ref->fs, 328 328 block_group, &bg_ref); 329 329 if (rc != EOK) … … 343 343 * 344 344 */ 345 errno_t ext4_balloc_alloc_block(ext4_inode_ref_t *inode_ref, uint32_t *fblock)345 int ext4_balloc_alloc_block(ext4_inode_ref_t *inode_ref, uint32_t *fblock) 346 346 { 347 347 uint32_t allocated_block = 0; … … 354 354 355 355 /* Find GOAL */ 356 errno_t rc = ext4_balloc_find_goal(inode_ref, &goal);356 int rc = ext4_balloc_find_goal(inode_ref, &goal); 357 357 if (rc != EOK) 358 358 return rc; … … 625 625 * 626 626 */ 627 errno_t ext4_balloc_try_alloc_block(ext4_inode_ref_t *inode_ref, uint32_t fblock,627 int ext4_balloc_try_alloc_block(ext4_inode_ref_t *inode_ref, uint32_t fblock, 628 628 bool *free) 629 629 { 630 errno_t rc;630 int rc; 631 631 632 632 ext4_filesystem_t *fs = inode_ref->fs;
Note:
See TracChangeset
for help on using the changeset viewer.