search for: ext2fs_new_inode

Displaying 9 results from an estimated 9 matches for "ext2fs_new_inode".

2009 Jan 21
0
[PATCH] Progs: update convert for uninitialized block groups
Hello, There is a new feature ''uninitialized block groups'' in ext4. Block and inode bitmaps in uninitialized block groups are uninitialized. This confuses the converter. The fix is call ext2fs_new_inode for each block group at open time. It set up uninitialized block and inode bitmaps appropriately. This patch also contains some other minor fixes. Thank you, Signed-off-by: Yan Zheng <zheng.yan@oracle.com> --- diff -urp btrfs-progs-unstable/convert.c btrfs-progs/convert.c --- btrfs-progs-u...
2019 Feb 19
2
Re: [PATCH nbdkit 4/4] Add linuxdisk plugin.
...+static int > +e2emptyinode (ext2_filsys fs, ext2_ino_t dir_ino, > + const char *name, const struct stat *statbuf, > + int ino_flags, ext2_ino_t *ino) > +{ > + errcode_t err; > + struct ext2_inode inode; > + int major_, minor_; > + > + err = ext2fs_new_inode (fs, dir_ino, statbuf->st_mode, 0, ino); > + if (err) { > + nbdkit_error ("ext2fs_new_inode: %s", error_message (err)); > + return -1; > + } > + > + memset (&inode, 0, sizeof inode); > + inode.i_mode = statbuf->st_mode; > + inode.i_uid = statbu...
2019 Feb 19
0
[PATCH nbdkit 4/4] Add linuxdisk plugin.
...directory exists (eg. because the user has + * two identically named subdirectories in two directory + * parameters). If this happens, skip. + */ + err = ext2fs_namei (fs, EXT2_ROOT_INO, dir_ino, name, &temp_ino); + if (err == 0) + return 0; + + /* Create the new inode. */ + err = ext2fs_new_inode (fs, dir_ino, mode, 0, ino); + if (err) { + nbdkit_error ("ext2fs_new_inode: %s", error_message (err)); + return -1; + } + + again: + err = ext2fs_mkdir (fs, dir_ino, *ino, name); + if (err) { + /* http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=217892 */ + if (err == EXT...
2019 Feb 19
7
[PATCH nbdkit 0/4] New plugin: Add linuxdisk plugin.
Turns out Japanese trains are good for coding! In supermin we have a bunch of code to create the libguestfs appliance. It creates it directly using libext2fs (part of e2fsprogs). We can use the same technique to create ext2 virtual disks in nbdkit, which is what this new plugin does. Why a new plugin instead of modifying the floppy plugin? See the 4/4 commit message for an explanation. The
2010 Mar 20
2
[PATCH 4/4] btrfs-convert: split into convert/.
...rr, "ext2fs_read_block_bitmap: %s\n", - error_message(ret)); - goto fail; - } - /* - * search each block group for a free inode. this set up - * uninit block/inode bitmaps appropriately. - */ - ino = 1; - while (ino <= ext2_fs->super->s_inodes_count) { - ext2_ino_t foo; - ext2fs_new_inode(ext2_fs, ino, 0, NULL, &foo); - ino += EXT2_INODES_PER_GROUP(ext2_fs->super); - } - - *ret_fs = ext2_fs; - return 0; -fail: - return -1; -} - -static int ext2_close(struct convert_fs *fs) -{ - ext2fs_close((ext2_filsys)fs->privdata); - return 0; -} - -static int ext2_cache_free_extents(s...
2019 Feb 19
6
[PATCH nbdkit v2 0/5] Add linuxdisk plugin.
Another interesting thing you can do with this plugin: https://rwmj.wordpress.com/2019/02/19/nbdkit-linuxdisk-plugin/ v2: - Fix inconsistent tab/space. - All 3 plugins now contain a block of text pointing to the other 2 plugins. - TMDIR -> TMPDIR - Unlink the temporary file and other cleanups along error paths. - fclose -> pclose, and check the return value for errors. -
2014 Dec 24
14
[PATCH 0/8] extlinux: support unmounted ext2/3/4 filesystem
Hello syslinux, Merry Christmas! These patches will make extlinux work with umounted ext2/3/4 filesystem, for example: $ extlinux -i /dev/sdXN or $ extlinux -i file_block Also it can work with something like: $ extlinux /dev/sdXN --reset-adv or $ extlinux file_block --reset-adv We don't use a new option (I planed to use "-d" but it is already in use), it will check whether the
2015 Jan 02
13
[PATCH 0/9] linux/syslinux: support ext2/3/4 device
Hello, Happy New Year! These patches make syslinux/linux support ext2/3/4, and it doesn't require the root privilege, I'd like to add a separate e2fs/syslinux, if that is more appropriate, it should be easy to do that. I put these patches on github so that you can easily get them in case you'd like to test them. (The repo's name is sys_tmp, which avoids confusing others, I will
2014 Feb 25
2
[PATCH supermin v4] Supermin 5 rewrite.
...NUX_S_IFDIR | (mode & 03777); - - /* Does the directory exist? This is legitimate: we just skip - * this case. - */ - ext2_ino_t ino; - err = ext2fs_namei (fs, EXT2_ROOT_INO, dir_ino, basename, &ino); - if (err == 0) - return; /* skip */ - - /* Otherwise, create it. */ - err = ext2fs_new_inode (fs, dir_ino, mode, 0, &ino); - if (err != 0) - error (EXIT_FAILURE, 0, "ext2fs_new_inode: %s", error_message (err)); - - try_again: - err = ext2fs_mkdir (fs, dir_ino, ino, basename); - if (err != 0) { - /* See: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=217892 */ -...