[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1248378517.8421.4.camel@bobble.smo.corp.google.com>
Date: Thu, 23 Jul 2009 12:48:37 -0700
From: Frank Mayhar <fmayhar@...gle.com>
To: Andreas Dilger <adilger@....com>
Cc: Eric Sandeen <sandeen@...hat.com>,
Curt Wohlgemuth <curtw@...gle.com>,
ext4 development <linux-ext4@...r.kernel.org>
Subject: Re: Question on fallocate/ftruncate sequence (and flags)
On Tue, 2009-07-21 at 15:54 -0600, Andreas Dilger wrote:
> That said, we might need to have some kind of flag in the on-disk
> inode to indicate that it was preallocated beyond EOF. Otherwise,
> e2fsck will try and extend the file size to match the block count,
> which isn't correct. We could also use this flag to determine if
> truncate needs to be run on the inode even if the new size is the
> same.
As it happens there's already a flag, FS_FALLOC_FL, set by ext2 in
fallocate(). Unfortunately ext4 is using that bit (0x00040000) for
EXT4_HUGE_FILE_FL. (Ext4 is using another bit as well, 0x00100000, for
EXT4_EXT_MIGRATE_FL when fs.h defines it as FS_DIRECTIO_FL.) I really
want to use the FS_FALLOC_FL bit for this purpose but that means
reallocating HUGE_FILE_FL to some other big. Objections?
--
Frank Mayhar <fmayhar@...gle.com>
Google, Inc.
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists