aboutsummaryrefslogtreecommitdiffstats
path: root/fs/gfs2/log.c
diff options
context:
space:
mode:
authorSteven Whitehouse <swhiteho@redhat.com>2007-10-17 04:04:24 -0400
committerSteven Whitehouse <swhiteho@redhat.com>2008-01-25 03:07:28 -0500
commitb8e7cbb65bcc99630e123422c6829ce3c0fcdf14 (patch)
treea9f68259b90e9e65ea7f0369f448d580a8944f06 /fs/gfs2/log.c
parent9ff8ec32e58875022447af619bec6e5aee7c77e4 (diff)
[GFS2] Add writepages for GFS2 jdata
This patch resolves a lock ordering issue where we had been getting a transaction lock in the wrong order with respect to the page lock. By using writepages rather than just writepage, it is then possible to start a transaction before locking the page, and thus matching the locking order elsewhere in the code. Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/gfs2/log.c')
-rw-r--r--fs/gfs2/log.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/gfs2/log.c b/fs/gfs2/log.c
index 70b404d2774b..1e1fe8def375 100644
--- a/fs/gfs2/log.c
+++ b/fs/gfs2/log.c
@@ -650,7 +650,7 @@ static void gfs2_ordered_write(struct gfs2_sbd *sdp)
650 get_bh(bh); 650 get_bh(bh);
651 gfs2_log_unlock(sdp); 651 gfs2_log_unlock(sdp);
652 lock_buffer(bh); 652 lock_buffer(bh);
653 if (test_clear_buffer_dirty(bh)) { 653 if (buffer_mapped(bh) && test_clear_buffer_dirty(bh)) {
654 bh->b_end_io = end_buffer_write_sync; 654 bh->b_end_io = end_buffer_write_sync;
655 submit_bh(WRITE, bh); 655 submit_bh(WRITE, bh);
656 } else { 656 } else {