generic/563: use a loop device to avoid partition incompatibility
authorBrian Foster <bfoster@redhat.com>
Mon, 14 Dec 2020 17:18:54 +0000 (12:18 -0500)
committerEryu Guan <guaneryu@gmail.com>
Sun, 20 Dec 2020 16:18:43 +0000 (00:18 +0800)
cgroup writeback accounting does not track partition level
statistics. Instead, I/O is accounted against the parent device. As
a result, the test fails if the scratch device happens to be a
device partition. Since parent level stats are potentially polluted
by factors external to the test, wrap the scratch device in a
loopback device to guarantee the test always runs on a top-level
block device.

Reported-by: Boyang Xue <bxue@redhat.com>
Signed-off-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Zorro Lang <zlang@redhat.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>

No differences found