mirror of
https://github.com/linux-apfs/apfstests.git
synced 2026-05-01 15:01:44 -07:00
overlay: use OVL_BASE_SCRATCH_MNT instead of SCRATCH_DEV
Use the new var OVL_BASE_SCRATCH_MNT to refer to overlay base dir instead of the legacy SCRATCH_DEV var. In overlay/011, when using MOUNT_PROG directly, provide OVL_BASE_SCRATCH_MNT as device argument instead of 'none'. This fix is required to support mount of base fs. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Reviewed-by: Eryu Guan <eguan@redhat.com> Signed-off-by: Eryu Guan <eguan@redhat.com>
This commit is contained in:
committed by
Eryu Guan
parent
2ab614524d
commit
33e4199895
+5
-5
@@ -55,10 +55,10 @@ _scratch_mkfs
|
||||
|
||||
# Need two lower dirs in this test, and we mount overlay ourselves,
|
||||
# create upper and workdir as well
|
||||
lowerdir1=$SCRATCH_DEV/$OVL_LOWER.1
|
||||
lowerdir2=$SCRATCH_DEV/$OVL_LOWER.2
|
||||
upperdir=$SCRATCH_DEV/$OVL_UPPER
|
||||
workdir=$SCRATCH_DEV/$OVL_WORK
|
||||
lowerdir1=$OVL_BASE_SCRATCH_MNT/$OVL_LOWER.1
|
||||
lowerdir2=$OVL_BASE_SCRATCH_MNT/$OVL_LOWER.2
|
||||
upperdir=$OVL_BASE_SCRATCH_MNT/$OVL_UPPER
|
||||
workdir=$OVL_BASE_SCRATCH_MNT/$OVL_WORK
|
||||
mkdir -p $lowerdir1 $lowerdir2 $upperdir $workdir
|
||||
|
||||
# One lowerdir contains test dir and test files, the other contains whiteout
|
||||
@@ -68,7 +68,7 @@ mknod $lowerdir2/testdir/a c 0 0
|
||||
|
||||
# Mount overlayfs and remove testdir, which led to kernel crash
|
||||
_overlay_mount_dirs "$lowerdir2:$lowerdir1" $upperdir $workdir \
|
||||
$SCRATCH_DEV $SCRATCH_MNT
|
||||
$OVL_BASE_SCRATCH_MNT $SCRATCH_MNT
|
||||
rm -rf $SCRATCH_MNT/testdir
|
||||
|
||||
# success, all done
|
||||
|
||||
Reference in New Issue
Block a user