From 2f56a3f8d824d34525951483e95b0ed04c5954bf Mon Sep 17 00:00:00 2001 From: Konstantin Komarov Date: Fri, 7 Oct 2022 13:57:28 +0300 Subject: fs/ntfs3: Fixing work with sparse clusters Simplify logic in ntfs_extend_initialized_size, ntfs_sparse_cluster and ntfs_fallocate. Signed-off-by: Konstantin Komarov --- fs/ntfs3/inode.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'fs/ntfs3/inode.c') diff --git a/fs/ntfs3/inode.c b/fs/ntfs3/inode.c index 763dd982a43a..d8d00ffe7a1f 100644 --- a/fs/ntfs3/inode.c +++ b/fs/ntfs3/inode.c @@ -646,7 +646,12 @@ static noinline int ntfs_get_block_vbo(struct inode *inode, u64 vbo, bh->b_size = block_size; off = vbo & (PAGE_SIZE - 1); set_bh_page(bh, page, off); - ll_rw_block(REQ_OP_READ, 1, &bh); + + lock_buffer(bh); + bh->b_end_io = end_buffer_read_sync; + get_bh(bh); + submit_bh(REQ_OP_READ, bh); + wait_on_buffer(bh); if (!buffer_uptodate(bh)) { err = -EIO; -- cgit v1.2.3