Changes in uspace/srv/fs/mfs/mfs_balloc.c [cde999a:b7fd2a0] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/fs/mfs/mfs_balloc.c
rcde999a rb7fd2a0 38 38 const bool native, unsigned start_bit); 39 39 40 static int40 static errno_t 41 41 mfs_free_bit(struct mfs_instance *inst, uint32_t idx, bmap_id_t bid); 42 42 43 static int43 static errno_t 44 44 mfs_alloc_bit(struct mfs_instance *inst, uint32_t *idx, bmap_id_t bid); 45 45 46 static int46 static errno_t 47 47 mfs_count_free_bits(struct mfs_instance *inst, bmap_id_t bid, uint32_t *free); 48 48 … … 56 56 * @return EOK on success or an error code. 57 57 */ 58 int58 errno_t 59 59 mfs_alloc_inode(struct mfs_instance *inst, uint32_t *inum) 60 60 { 61 int r = mfs_alloc_bit(inst, inum, BMAP_INODE);61 errno_t r = mfs_alloc_bit(inst, inum, BMAP_INODE); 62 62 return r; 63 63 } … … 70 70 * @return EOK on success or an error code. 71 71 */ 72 int72 errno_t 73 73 mfs_free_inode(struct mfs_instance *inst, uint32_t inum) 74 74 { … … 84 84 * @return EOK on success or an error code. 85 85 */ 86 int86 errno_t 87 87 mfs_alloc_zone(struct mfs_instance *inst, uint32_t *zone) 88 88 { 89 int r = mfs_alloc_bit(inst, zone, BMAP_ZONE);89 errno_t r = mfs_alloc_bit(inst, zone, BMAP_ZONE); 90 90 if (r != EOK) 91 91 return r; … … 107 107 * @return EOK on success or an error code. 108 108 */ 109 int109 errno_t 110 110 mfs_free_zone(struct mfs_instance *inst, uint32_t zone) 111 111 { 112 int r;112 errno_t r; 113 113 114 114 zone -= inst->sbi->firstdatazone - 1; … … 134 134 * @return EOK on success or an error code. 135 135 */ 136 int136 errno_t 137 137 mfs_count_free_zones(struct mfs_instance *inst, uint32_t *zones) 138 138 { … … 149 149 */ 150 150 151 int151 errno_t 152 152 mfs_count_free_inodes(struct mfs_instance *inst, uint32_t *inodes) 153 153 { … … 164 164 * @return EOK on success or an error code. 165 165 */ 166 static int166 static errno_t 167 167 mfs_count_free_bits(struct mfs_instance *inst, bmap_id_t bid, uint32_t *free) 168 168 { 169 int r;169 errno_t r; 170 170 unsigned start_block; 171 171 unsigned long nblocks; … … 228 228 * @return EOK on success or an error code. 229 229 */ 230 static int230 static errno_t 231 231 mfs_free_bit(struct mfs_instance *inst, uint32_t idx, bmap_id_t bid) 232 232 { 233 233 struct mfs_sb_info *sbi; 234 int r;234 errno_t r; 235 235 unsigned start_block; 236 236 unsigned *search; … … 295 295 * @return EOK on success or an error code. 296 296 */ 297 static int297 static errno_t 298 298 mfs_alloc_bit(struct mfs_instance *inst, uint32_t *idx, bmap_id_t bid) 299 299 { … … 303 303 unsigned *search, i, start_block; 304 304 unsigned bits_per_block; 305 int r;305 errno_t r; 306 306 int freebit; 307 307
Note:
See TracChangeset
for help on using the changeset viewer.