Lines Matching refs:retval

50 	errcode_t		retval;  in ext2fs_create_journal_superblock()  local
56 if ((retval = ext2fs_get_mem(fs->blocksize, &jsb))) in ext2fs_create_journal_superblock()
57 return retval; in ext2fs_create_journal_superblock()
93 errcode_t retval; in write_journal_file() local
98 if ((retval = ext2fs_create_journal_superblock(fs, num_blocks, flags, in write_journal_file()
100 return retval; in write_journal_file()
104 retval = errno; in write_journal_file()
109 retval = EXT2_ET_SHORT_WRITE; in write_journal_file()
112 retval = errno; in write_journal_file()
125 retval = errno; in write_journal_file()
133 retval = 0; in write_journal_file()
138 return retval; in write_journal_file()
158 errcode_t retval; in ext2fs_zero_blocks2() local
175 retval = io_channel_zeroout(fs->io, blk, num); in ext2fs_zero_blocks2()
176 if (retval == 0) in ext2fs_zero_blocks2()
205 retval = io_channel_write_blk64(fs->io, blk, count, buf); in ext2fs_zero_blocks2()
206 if (retval) { in ext2fs_zero_blocks2()
211 return retval; in ext2fs_zero_blocks2()
222 errcode_t retval; in ext2fs_zero_blocks() local
224 retval = ext2fs_zero_blocks2(fs, blk, num, &ret_blk2, ret_count); in ext2fs_zero_blocks()
225 if (retval) in ext2fs_zero_blocks()
227 return retval; in ext2fs_zero_blocks()
268 errcode_t retval; in write_journal_inode() local
274 if ((retval = ext2fs_create_journal_superblock(fs, num_blocks, flags, in write_journal_inode()
276 return retval; in write_journal_inode()
278 if ((retval = ext2fs_read_bitmaps(fs))) in write_journal_inode()
281 if ((retval = ext2fs_read_inode(fs, journal_ino, &inode))) in write_journal_inode()
285 retval = EEXIST; in write_journal_inode()
302 retval = ext2fs_inode_size_set(fs, &inode, inode_size); in write_journal_inode()
303 if (retval) in write_journal_inode()
306 retval = ext2fs_fallocate(fs, falloc_flags, journal_ino, in write_journal_inode()
308 if (retval) in write_journal_inode()
311 if ((retval = ext2fs_write_new_inode(fs, journal_ino, &inode))) in write_journal_inode()
314 retval = ext2fs_bmap2(fs, journal_ino, &inode, NULL, 0, 0, NULL, &zblk); in write_journal_inode()
315 if (retval) in write_journal_inode()
318 retval = io_channel_write_blk64(fs->io, zblk, 1, buf); in write_journal_inode()
319 if (retval) in write_journal_inode()
330 return retval; in write_journal_inode()
374 errcode_t retval; in ext2fs_add_journal_device() local
389 if ((retval = io_channel_read_blk64(journal_dev->io, start, in ext2fs_add_journal_device()
392 return retval; in ext2fs_add_journal_device()
416 if ((retval = io_channel_write_blk64(journal_dev->io, start, in ext2fs_add_journal_device()
418 return retval; in ext2fs_add_journal_device()
438 errcode_t retval; in ext2fs_add_journal_inode2() local
447 else if ((retval = ext2fs_check_mount_point(fs->device_name, in ext2fs_add_journal_inode2()
450 return retval; in ext2fs_add_journal_inode2()
468 retval = ioctl(fd, EXT2_IOC_SETFLAGS, &f); in ext2fs_add_journal_inode2()
470 if (retval) in ext2fs_add_journal_inode2()
471 return retval; in ext2fs_add_journal_inode2()
487 if ((retval = write_journal_file(fs, jfile, num_blocks, flags))) in ext2fs_add_journal_inode2()
492 retval = errno; in ext2fs_add_journal_inode2()
497 retval = fchflags (fd, UF_NODUMP|UF_IMMUTABLE); in ext2fs_add_journal_inode2()
501 retval = errno; in ext2fs_add_journal_inode2()
505 retval = ioctl(fd, EXT2_IOC_SETFLAGS, &f); in ext2fs_add_journal_inode2()
508 if (retval) { in ext2fs_add_journal_inode2()
509 retval = errno; in ext2fs_add_journal_inode2()
514 retval = errno; in ext2fs_add_journal_inode2()
524 retval = EBUSY; in ext2fs_add_journal_inode2()
528 if ((retval = write_journal_inode(fs, journal_ino, in ext2fs_add_journal_inode2()
530 return retval; in ext2fs_add_journal_inode2()
544 return retval; in ext2fs_add_journal_inode2()
556 errcode_t retval; in main() local
566 retval = ext2fs_open (device_name, EXT2_FLAG_RW, 0, 0, in main()
568 if (retval) { in main()
569 com_err(argv[0], retval, "while opening %s", device_name); in main()
573 retval = ext2fs_add_journal_inode(fs, JFS_MIN_JOURNAL_BLOCKS, 0); in main()
574 if (retval) { in main()
575 com_err(argv[0], retval, "while adding journal to %s", in main()
579 retval = ext2fs_flush(fs); in main()
580 if (retval) { in main()