]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: fix pages truncation in btrfs_ioctl_clone()
authorLi Zefan <lizf@cn.fujitsu.com>
Sun, 18 Sep 2011 14:20:46 +0000 (10:20 -0400)
committerChris Mason <chris.mason@oracle.com>
Sun, 18 Sep 2011 14:20:46 +0000 (10:20 -0400)
commit8e228ac35adea5d3124df4d13415249b800233fc
tree9f2c706625a67a5164f774805eb8aaa32ea2410b
parent39663f181d04568e092d1bb5f988756b872b42e0
Btrfs: fix pages truncation in btrfs_ioctl_clone()

It's a bug in commit f5fd19a09e2de4c4ffcaa470499cc91d15cb98e6
(Btrfs: truncate pages from clone ioctl target range)

We should pass the dest range to the truncate function, but not the
src range.

Also move the function before locking extent state.

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/ioctl.c