summaryrefslogtreecommitdiff
path: root/fs/buffer.c
diff options
context:
space:
mode:
authorMonakhov Dmitriy <dmonakhov@openvz.org>2006-10-11 01:22:00 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-11 11:14:23 -0700
commit8c58165108e26d18849a0138c719e680f281197a (patch)
treeff5e54e11357867ef3e8edfa9df8de25a688afdc /fs/buffer.c
parent97e860d364aa9d08e895ecb619b9122ae2c70df8 (diff)
[PATCH] D-cache aliasing issue in __block_prepare_write
A couple of flush_dcache_page()s are missing on the I/O-error paths. Cc: "David S. Miller" <davem@davemloft.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/buffer.c')
-rw-r--r--fs/buffer.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/buffer.c b/fs/buffer.c
index 2a7828c0e59b..f65ef8821c73 100644
--- a/fs/buffer.c
+++ b/fs/buffer.c
@@ -1854,6 +1854,7 @@ static int __block_prepare_write(struct inode *inode, struct page *page,
clear_buffer_new(bh);
kaddr = kmap_atomic(page, KM_USER0);
memset(kaddr+block_start, 0, bh->b_size);
+ flush_dcache_page(page);
kunmap_atomic(kaddr, KM_USER0);
set_buffer_uptodate(bh);
mark_buffer_dirty(bh);
@@ -2360,6 +2361,7 @@ failed:
*/
kaddr = kmap_atomic(page, KM_USER0);
memset(kaddr, 0, PAGE_CACHE_SIZE);
+ flush_dcache_page(page);
kunmap_atomic(kaddr, KM_USER0);
SetPageUptodate(page);
set_page_dirty(page);