diff options
author | Jan Kara <jack@suse.cz> | 2005-09-06 18:19:15 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-09-07 19:57:56 -0400 |
commit | 096125f31ae3aa2c7271463b9986dd228e0da089 (patch) | |
tree | 2a6f0b066acf1031ffffca98a44c870bcead23b4 /fs/ufs/truncate.c | |
parent | 53778ffde601c962ad9250c4998df7de6f428246 (diff) |
[PATCH] Change ll_rw_block() calls in UFS
We need to be sure that current data are sent to disk. Hence we 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>
Diffstat (limited to 'fs/ufs/truncate.c')
-rw-r--r-- | fs/ufs/truncate.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/ufs/truncate.c b/fs/ufs/truncate.c index e312bf8bad9f..61d2e35012a4 100644 --- a/fs/ufs/truncate.c +++ b/fs/ufs/truncate.c | |||
@@ -285,8 +285,7 @@ next:; | |||
285 | } | 285 | } |
286 | } | 286 | } |
287 | if (IS_SYNC(inode) && ind_ubh && ubh_buffer_dirty(ind_ubh)) { | 287 | if (IS_SYNC(inode) && ind_ubh && ubh_buffer_dirty(ind_ubh)) { |
288 | ubh_wait_on_buffer (ind_ubh); | 288 | ubh_ll_rw_block (SWRITE, 1, &ind_ubh); |
289 | ubh_ll_rw_block (WRITE, 1, &ind_ubh); | ||
290 | ubh_wait_on_buffer (ind_ubh); | 289 | ubh_wait_on_buffer (ind_ubh); |
291 | } | 290 | } |
292 | ubh_brelse (ind_ubh); | 291 | ubh_brelse (ind_ubh); |
@@ -353,8 +352,7 @@ static int ufs_trunc_dindirect (struct inode *inode, unsigned offset, __fs32 *p) | |||
353 | } | 352 | } |
354 | } | 353 | } |
355 | if (IS_SYNC(inode) && dind_bh && ubh_buffer_dirty(dind_bh)) { | 354 | if (IS_SYNC(inode) && dind_bh && ubh_buffer_dirty(dind_bh)) { |
356 | ubh_wait_on_buffer (dind_bh); | 355 | ubh_ll_rw_block (SWRITE, 1, &dind_bh); |
357 | ubh_ll_rw_block (WRITE, 1, &dind_bh); | ||
358 | ubh_wait_on_buffer (dind_bh); | 356 | ubh_wait_on_buffer (dind_bh); |
359 | } | 357 | } |
360 | ubh_brelse (dind_bh); | 358 | ubh_brelse (dind_bh); |
@@ -418,8 +416,7 @@ static int ufs_trunc_tindirect (struct inode * inode) | |||
418 | } | 416 | } |
419 | } | 417 | } |
420 | if (IS_SYNC(inode) && tind_bh && ubh_buffer_dirty(tind_bh)) { | 418 | if (IS_SYNC(inode) && tind_bh && ubh_buffer_dirty(tind_bh)) { |
421 | ubh_wait_on_buffer (tind_bh); | 419 | ubh_ll_rw_block (SWRITE, 1, &tind_bh); |
422 | ubh_ll_rw_block (WRITE, 1, &tind_bh); | ||
423 | ubh_wait_on_buffer (tind_bh); | 420 | ubh_wait_on_buffer (tind_bh); |
424 | } | 421 | } |
425 | ubh_brelse (tind_bh); | 422 | ubh_brelse (tind_bh); |