[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <47557870.9060405@redhat.com>
Date: Tue, 04 Dec 2007 09:55:28 -0600
From: Eric Sandeen <sandeen@...hat.com>
To: ext4 development <linux-ext4@...r.kernel.org>
Subject: [PATCH 0/3] ext4: Handle different max offsets for bitmap & extent-based
files
Basic approach: have both ext4_max_bitmap_size() and ext4_max_size()
functions to compute max offsets for both types of formats.
Use vfs sb->s_maxbytes for the "native" maxbytes, i.e. extent-format files.
Put the smaller bitmap limit in a new sbi->s_bitmap_maxbytes in the ext4
superblock info structure.
Catch bitmap files in ext4_file_write() and ext4_setattr() to limit
extending writes, llseeks, and truncates to too-large offsets which the
VFS let through due to the extent-format maxbytes. On write, allow
writes up to the max, but then stop, by using iov_shorten() to limit the
size of the write to the maximum.
3 patches follow:
ext4_two_maxbytes_functions.patch - differentiate the maxbytes f'ns
ext4_bitmap_maxbytes_vfs.patch - export iov_shorten from kernel
ext4_bitmap_maxbytes.patch - store, and limit to, bitmap_maxbytes
Comments?
Thanks,
-Eric
-
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