Re: [PATCH 05/11] ext4: Make sure blocks are properly allocatedunder mmaped page even when blocksize < pagesize

From: Jan Kara
Date: Wed May 27 2009 - 10:52:25 EST

On Wed 27-05-09 10:30:06, Theodore Tso wrote:
> On Wed, May 27, 2009 at 03:01:02PM +0200, Jan Kara wrote:
> > In a situation like:
> > truncate(f, 1024);
> > a = mmap(f, 0, 4096);
> > a[0] = 'a';
> > truncate(f, 4096);
> >
> > we end up with a dirty page which does not have all blocks allocated /
> > reserved. Fix the problem by using new VFS infrastructure.
> >
> > Signed-off-by: Jan Kara <jack@xxxxxxx>
> Hi Jan,
> Have you tested with -o nodelalloc? There is apparently a problem
> with ext4 when blocksize < pagesize which Aneesh has been working on.
> He has been able to reproduce the problem, and theorized that an
> earlier version your patch set would address the problem, but it
> apparently did not. See:
> ... and Aneesh can provide more details. Aneesh, you might want to
> try testing with this latest set and see if you can reproduce the
> problem with this set.
Yes, I've exchanged a few emails with Aneesh privately yesterday and
today. There were bugs in my original patch set which should now be fixed.
Hopefully it also fixes the bug Aneesh sees (it's definitely the type of
bug this patch set should solve and if it does not I should fix it ;).

Jan Kara <jack@xxxxxxx>
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at