[PATCH] reiserfs: fix journaling issue regarding fsync()
authorHisashi Hifumi <hifumi.hisashi@oss.ntt.co.jp>
Mon, 10 Jul 2006 11:43:56 +0000 (04:43 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 10 Jul 2006 20:24:13 +0000 (13:24 -0700)
commit73ce5934e2d855db436566297f12966eb507a435
tree8e3e2fa1690dbd2f5a389ea5c5b151287f9e0297
parent0808925ea5684a0ce25483b30e94d4f398804978
[PATCH] reiserfs: fix journaling issue regarding fsync()

When write() extends a file(i_size is increased) and fsync() is called,
change of inode must be written to journaling area through fsync().
But,currently the i_trans_id is not correctly updated when i_size is
increased.  So fsync() does not kick the journal writer.

Reiserfs_file_write() already updates the transaction when blocks are
allocated, but the case when i_size increases and new blocks are not added
is not correctly treated.

Following patch fix this bug.

Signed-off-by: Hisashi Hifumi <hifumi.hisashi@oss.ntt.co.jp>
Cc: Jeff Mahoney <jeffm@suse.com>
Cc: Chris Mason <mason@suse.com>
Cc: Hans Reiser <reiser@namesys.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/reiserfs/file.c