From: Nick Piggin <npiggin@suse.de>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Linux Memory Management List <linux-mm@kvack.org>,
Hugh Dickins <hugh@veritas.com>
Subject: [patch 2/4] reiserfs convert to new aops fix
Date: Sat, 14 Jul 2007 12:23:01 +0200 [thread overview]
Message-ID: <20070714102301.GB12215@wotan.suse.de> (raw)
In-Reply-To: <20070714102111.GA12215@wotan.suse.de>
Lock ordering fix for the same problem for reiserfs.
Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Nick Piggin <npiggin@suse.de>
Index: linux-2.6/fs/reiserfs/inode.c
===================================================================
--- linux-2.6.orig/fs/reiserfs/inode.c
+++ linux-2.6/fs/reiserfs/inode.c
@@ -2694,9 +2694,6 @@ static int reiserfs_write_end(struct fil
flush_dcache_page(page);
reiserfs_commit_page(inode, page, start, start + copied);
- unlock_page(page);
- mark_page_accessed(page);
- page_cache_release(page);
/* generic_commit_write does this for us, but does not update the
** transaction tracking stuff when the size changes. So, we have
@@ -2746,6 +2743,9 @@ static int reiserfs_write_end(struct fil
}
out:
+ unlock_page(page);
+ mark_page_accessed(page);
+ page_cache_release(page);
return ret == 0 ? copied : ret;
journal_error:
@@ -2757,7 +2757,7 @@ static int reiserfs_write_end(struct fil
reiserfs_write_unlock(inode->i_sb);
}
- return ret;
+ goto out;
}
int reiserfs_commit_write(struct file *f, struct page *page,
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2007-07-14 10:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-14 10:21 [patch 1/4] introduce write_begin write_end aops important fix Nick Piggin
2007-07-14 10:23 ` Nick Piggin [this message]
2007-07-14 10:24 ` [patch 3/4] affs convert to new aops fix Nick Piggin
2007-07-14 10:24 ` [patch 4/4] hostfs " Nick Piggin
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=20070714102301.GB12215@wotan.suse.de \
--to=npiggin@suse.de \
--cc=akpm@linux-foundation.org \
--cc=hugh@veritas.com \
--cc=linux-mm@kvack.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