e2fsprogs/misc
Lukas Czerner d2bfdc7ff1 e2fsprogs: Use punch hole as "discard" on regular files
If e2fsprogs tools (mke2fs, e2fsck) is run on regular file instead of
on block device, we can use punch hole instead of regular discard
command which would not work on regular file anyway. This gives us
several advantages. First of all when e2fsck is run with '-E discard'
parameter it will punch out all ununsed space from the image, hence
trimming down the file system image. And secondly, when creating an
file system on regular file (with '-E discard' which is default), we
can use punch hole to clear the file content, hence we can skip inode
table initialization, because reads from sparse area returns zeros. This
will result in faster file system creation (without the need to specify
lazy_itable_init) and smaller images.

This commit also fixes some tests that would fail due to mke2fs showing
discard progress, hence the output would differ.

Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
2011-09-15 23:49:20 -04:00
..
Makefile.in mke2fs.static: change library ordering to avoid a link error 2011-09-13 23:03:17 -04:00
badblocks.8.in badblocks: Add the -B option which forces the use of buffered I/O 2011-02-18 01:16:02 -05:00
badblocks.c misc: clean up compiler warnings 2011-06-11 10:58:25 -04:00
base_device.c Remove trailing whitespace for the entire source tree 2008-08-27 23:07:54 -04:00
base_device.tst ChangeLog, Makefile.in, base_device.c, base_device.tst, fsck.c, fsck.h: 2000-12-03 06:33:56 +00:00
blkid.8.in blkid: On the man page, show option arguments in the descriptions. 2008-08-14 13:29:50 -04:00
blkid.c Fix miscellaneous gcc -Wall warnings in blkid and tune2fs 2009-07-11 23:56:49 -04:00
chattr.1.in Fix spelling mistake in the man page for chattr 2009-06-02 09:02:39 -04:00
chattr.c chattr: Add extent conversion support 2009-05-28 08:32:29 -04:00
dumpe2fs.8.in Update man pages to include ext4 in the synposis, instead of just "ext2/ext3" 2009-05-30 12:34:28 -04:00
dumpe2fs.c Merge branch 'maint' into next 2011-06-04 20:24:36 -04:00
e2freefrag.8.in e2freefrag: Update manpage to include e2fsprogs version and release date 2009-08-22 23:41:49 -04:00
e2freefrag.c misc: clean up compiler warnings 2011-06-11 10:58:25 -04:00
e2freefrag.h e2freefrag: Improve output to include be more like xfs_db's freesp -s 2009-07-24 18:33:46 -04:00
e2image.8.in e2image: Support for conversion QCOW2 image into raw 2011-05-18 11:53:11 -04:00
e2image.c e2fsprogs: create open() and stat() helpers 2011-09-15 23:46:57 -04:00
e2initrd_helper.c remove useless if-before-free tests 2009-03-08 20:37:12 -04:00
e2label.8.in Update man pages to include ext4 in the synposis, instead of just "ext2/ext3" 2009-05-30 12:34:28 -04:00
e2label.c Remove trailing whitespace for the entire source tree 2008-08-27 23:07:54 -04:00
e2undo.8.in Add e2undo command 2008-04-27 19:42:05 -04:00
e2undo.c misc: clean up compiler warnings 2011-06-11 10:58:25 -04:00
e4defrag.8.in e4defrag: update man page about -c option 2010-12-13 09:59:07 -05:00
e4defrag.c e4defrag: Use libext2fs to get the correct superblock information 2010-12-24 16:56:24 -05:00
filefrag.8.in filefrag: Add option to force use of the FIBMAP ioctl 2009-08-15 23:15:44 -04:00
filefrag.c Merge branch 'maint' into next 2011-05-07 23:24:55 -04:00
findfs.8.in Update version string for WIP release. 2002-08-18 03:38:15 -04:00
findsuper.c Convert uses of super->s_*_blocks_count to ext2fs_*_blocks_count() 2009-09-07 20:46:34 -04:00
fsck.8.in Make fsck ignore mounted filesystems if given the -M option 2008-02-17 17:35:46 -05:00
fsck.c remove useless if-before-free tests 2009-03-08 20:37:12 -04:00
fsck.h Fix miscellaneous gcc -Wall warnings 2008-03-17 23:17:13 -04:00
ismounted.c fix fd leak that causes fsck to fail with "too many open files" 2009-10-03 13:38:47 -04:00
jfs_user.h Move linux/jbd.h to ext2fs/kernel-jbd.h, to avoid using the 2001-12-23 19:33:51 -05:00
logsave.8.in * Add support for the -a and -s options to logsave. 2003-04-16 14:05:06 -04:00
logsave.c logsave: Update usage message so it is correct 2011-05-07 21:21:42 -04:00
lsattr.1.in chattr.1.in: Clarify man page. 2004-01-31 20:27:36 -05:00
lsattr.c lsattr: exit with a non-zero status on errors 2009-06-21 21:46:34 -04:00
mke2fs.8.in mke2fs: support creation of filesystem with quota feature 2011-08-31 16:31:49 -04:00
mke2fs.c e2fsprogs: Use punch hole as "discard" on regular files 2011-09-15 23:49:20 -04:00
mke2fs.conf Merge branch 'maint' into next 2011-02-20 21:54:43 -05:00
mke2fs.conf.5.in mke2fs: add support for cluster size in mke2fs.conf 2011-06-14 14:32:48 -04:00
mklost+found.8.in chattr.1.in: Clarify man page. 2004-01-31 20:27:36 -05:00
mklost+found.c Remove trailing whitespace for the entire source tree 2008-08-27 23:07:54 -04:00
nls-enable.h Remove warning message about using NLS. 2003-12-07 12:17:27 -05:00
partinfo.c Remove trailing whitespace for the entire source tree 2008-08-27 23:07:54 -04:00
profile-to-c.awk Compile the default mke2fs.conf into mke2fs program 2007-07-04 14:27:30 -04:00
tune2fs.8.in tune2fs: Add support for turning on quota feature 2011-08-31 18:08:42 -04:00
tune2fs.c mke2fs: Use ext2fs_flush() only once 2011-09-13 22:42:19 -04:00
util.c e2fsprogs: create open() and stat() helpers 2011-09-15 23:46:57 -04:00
util.h mke2fs: Use ext2fs_flush() only once 2011-09-13 22:42:19 -04:00
uuidd.8.in Fix the pathname of /var/lib/uuidd/uuidd.pid in uuidd man page. 2008-01-19 18:13:14 -05:00
uuidd.c libuuid, uuidd: Avoid infinite loop while reading from the socket fd 2009-06-29 20:03:20 -04:00
uuidd.rc Add uuidd daemon to prevent duplicate time-based UUID's 2007-12-16 17:28:46 -05:00
uuidgen.1.in Fix typo and clarify the uuidgen man page 2007-08-20 21:46:19 -04:00
uuidgen.c Remove trailing whitespace for the entire source tree 2008-08-27 23:07:54 -04:00