[PATCH] Change ll_rw_block() calls in Reiser
authorJan Kara <jack@suse.cz>
Tue, 6 Sep 2005 22:19:14 +0000 (15:19 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Wed, 7 Sep 2005 23:57:56 +0000 (16:57 -0700)
We need to be sure that current data in buffer are sent to disk.  Hence we
need to call ll_rw_block() with SWRITE.

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/reiserfs/journal.c

index ca7989b04be3490f1e430cae7af2c1b242e521c8..a8e29e9bbbd08e336fc13a3fd9b1e81d7ec4eda0 100644 (file)
@@ -1034,7 +1034,7 @@ static int flush_commit_list(struct super_block *s,
                    SB_ONDISK_JOURNAL_SIZE(s);
                tbh = journal_find_get_block(s, bn);
                if (buffer_dirty(tbh))  /* redundant, ll_rw_block() checks */
-                       ll_rw_block(WRITE, 1, &tbh);
+                       ll_rw_block(SWRITE, 1, &tbh);
                put_bh(tbh);
        }
        atomic_dec(&journal->j_async_throttle);
@@ -2172,7 +2172,7 @@ static int journal_read_transaction(struct super_block *p_s_sb,
        /* flush out the real blocks */
        for (i = 0; i < get_desc_trans_len(desc); i++) {
                set_buffer_dirty(real_blocks[i]);
-               ll_rw_block(WRITE, 1, real_blocks + i);
+               ll_rw_block(SWRITE, 1, real_blocks + i);
        }
        for (i = 0; i < get_desc_trans_len(desc); i++) {
                wait_on_buffer(real_blocks[i]);