Commit 1c779419 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] tmpfs 6/7 write i_size_write

From: Hugh Dickins <hugh@veritas.com>

mm/shmem.c was converted to i_size_read in -test1, and the remaining
references to a file's naked i_size are safely protected by i_sem;
but surely shmem_file_write must use i_size_write to update i_size.
parent 6673fd3d
......@@ -1239,7 +1239,7 @@ shmem_file_write(struct file *file, const char __user *buf, size_t count, loff_t
pos += bytes;
buf += bytes;
if (pos > inode->i_size)
inode->i_size = pos;
i_size_write(inode, pos);
flush_dcache_page(page);
set_page_dirty(page);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment