btrfs: add regression test for clone ioctl
Regression test for a btrfs clone ioctl issue where races between
a clone operation and concurrent target file reads would result in
leaving stale data in the page cache. After the clone operation
finished, reading from the clone target file would return the old
and no longer valid data. This affected only buffered reads (i.e.
didn't affect direct IO reads).
This issue was fixed by the following linux kernel patch:
Btrfs: ensure readers see new data after a clone operation
(commit
c125b8bff1d9f6c8c91ce4eb8bd5616058c7d510)
Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: Josef Bacik <jbacik@fb.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>