From: Nick Piggin <npiggin@suse.de>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-fsdevel@vger.kernel.org, linux-ext4@vger.kernel.org
Subject: Re: [patch 17/41] ext2 convert to new aops.
Date: Wed, 16 May 2007 14:45:05 +0200 [thread overview]
Message-ID: <20070516124505.GA29668@wotan.suse.de> (raw)
In-Reply-To: <20070514060652.572496000@wotan.suse.de>
On Mon, May 14, 2007 at 04:06:36PM +1000, npiggin@suse.de wrote:
> Cc: linux-ext4@vger.kernel.org
> Cc: Linux Filesystems <linux-fsdevel@vger.kernel.org>
> Signed-off-by: Nick Piggin <npiggin@suse.de>
Found a problem in ext2 pagecache directory handling. Trivial fix follows.
Longer-term, it might be better to rework these things a bit so they can
directly use the pagecache_write_begin/pagecache_write_end accessors.
---
Index: linux-2.6/fs/ext2/dir.c
===================================================================
--- linux-2.6.orig/fs/ext2/dir.c
+++ linux-2.6/fs/ext2/dir.c
@@ -70,10 +70,18 @@ static int ext2_commit_chunk(struct page
dir->i_version++;
block_write_end(NULL, mapping, pos, len, len, page, NULL);
+
+ if (pos+len > dir->i_size) {
+ i_size_write(dir, pos+len);
+ mark_inode_dirty(dir);
+ }
+
if (IS_DIRSYNC(dir))
err = write_one_page(page, 1);
else
unlock_page(page);
+ mark_page_accessed(page);
+
return err;
}
next prev parent reply other threads:[~2007-05-16 12:45 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20070514060619.689648000@wotan.suse.de>
2007-05-14 6:06 ` [patch 17/41] ext2 convert to new aops npiggin
2007-05-16 12:45 ` Nick Piggin [this message]
2007-05-14 6:06 ` [patch 18/41] ext3 " npiggin
2007-05-14 6:06 ` [patch 19/41] ext4 " npiggin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070516124505.GA29668@wotan.suse.de \
--to=npiggin@suse.de \
--cc=akpm@linux-foundation.org \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).