Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1024c902 authored by Mark Fasheh's avatar Mark Fasheh
Browse files

ocfs2: unmap_mapping_range() in ocfs2_truncate()



We weren't calling this before, but since ocfs2 handles the entire truncate
operation, we should.

Signed-off-by: default avatarMark Fasheh <mark.fasheh@oracle.com>
parent e9dfc0b2
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -326,6 +326,7 @@ static int ocfs2_truncate_file(struct inode *inode,
		   (unsigned long long)OCFS2_I(inode)->ip_blkno,
		   (unsigned long long)new_i_size);

	unmap_mapping_range(inode->i_mapping, new_i_size + PAGE_SIZE - 1, 0, 1);
	truncate_inode_pages(inode->i_mapping, new_i_size);

	fe = (struct ocfs2_dinode *) di_bh->b_data;