fuse: direct-io: don't dirty ITER_BVEC pages
When reading from a loop device backed by a fuse file it deadlocks on lock_page(). This is because the page is already locked by the read() operation done on the loop device. In this case we don't want to either lock the page or dirty it. So do what fs/direct-io.c does: only dirty the page for ITER_IOVEC vectors. Reported-by: NSheng Yang <sheng@yasker.org> Fixes: aa4d8616 ("block: loop: switch to VFS ITER_BVEC") Signed-off-by: NMiklos Szeredi <mszeredi@redhat.com> Cc: <stable@vger.kernel.org> # v4.1+ Reviewed-by: NSheng Yang <sheng@yasker.org> Reviewed-by: NAshish Samant <ashish.samant@oracle.com> Tested-by: NSheng Yang <sheng@yasker.org> Tested-by: NAshish Samant <ashish.samant@oracle.com>
Showing
想要评论请 注册 或 登录