btrfs/085: check flakey device instead of backend device
authorNaohiro Aota <naohiro.aota@wdc.com>
Wed, 20 Nov 2019 06:44:06 +0000 (15:44 +0900)
committerEryu Guan <guaneryu@gmail.com>
Sun, 24 Nov 2019 16:07:06 +0000 (00:07 +0800)
commit3414cae6d231e69a08e244da242cdcaf59aeac9f
tree2c3d6cb63ae1e702a11d1e69e3ddeb09d16ea509
parent86216d73ef61c7328c4dfe7e3e3b39bb73b32369
btrfs/085: check flakey device instead of backend device

btrfs/085 mount and works on $FLAKEY_DEV, but it's inspecting the
underlying $SCRATCH_DEV. Since writing to dm-flakey does not
invalidate page cache of $SCRATCH_DEV, the btrfs command can read a
stalled data from page cache. We should check the flakey device to
avoid such cache inconsistency.

Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
tests/btrfs/085