]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commit
ocfs2: return 0 in page_mkwrite to let VFS retry.
authorTao Ma <tao.ma@oracle.com>
Mon, 6 Oct 2008 08:59:55 +0000 (16:59 +0800)
committerMark Fasheh <mfasheh@suse.com>
Mon, 10 Nov 2008 17:51:47 +0000 (09:51 -0800)
commit4c1bbf1ba631d7db61ce3462349a3f5d14ae3009
tree7ba31e8afc0514062f3ba59c9b538a75a121fb1f
parentae0dff683076b2798763288c7ac2f09a18c4a998
ocfs2: return 0 in page_mkwrite to let VFS retry.

In ocfs2_page_mkwrite, we return -EINVAL when we found the page mapping
isn't updated, and it will cause the user space program get SIGBUS and
exit. The reason is that during race writeable mmap, we will do
unmap_mapping_range in ocfs2_data_downconvert_worker. The good thing is
that if we reuturn 0 in page_mkwrite, VFS will retry fault and then
call page_mkwrite again, so it is safe to return 0 here.

Signed-off-by: Tao Ma <tao.ma@oracle.com>
Signed-off-by: Mark Fasheh <mfasheh@suse.com>
fs/ocfs2/mmap.c