# test whether idmapped mounts are supported
_require_idmapped_mounts()
{
- IDMAPPED_MOUNTS_TEST=$here/src/vfs/idmapped-mounts
- [ -x $IDMAPPED_MOUNTS_TEST ] || _notrun "idmapped-mounts utilities required"
+ IDMAPPED_MOUNTS_TEST=$here/src/vfs/vfstest
+ [ -x $IDMAPPED_MOUNTS_TEST ] || _notrun "vfstest utilities required"
_require_mount_setattr
- $here/src/vfs/idmapped-mounts --supported \
+ $here/src/vfs/vfstest --idmapped-mounts-supported \
--device "$TEST_DEV" \
--mount "$TEST_DIR" \
--fstype "$FSTYP"
if [ $? -ne 0 ]; then
- _notrun "idmapped-mounts not support by $FSTYP"
+ _notrun "vfstest not support by $FSTYP"
fi
}
TOPDIR = ../..
include $(TOPDIR)/include/builddefs
-TARGETS = idmapped-mounts mount-idmapped
-CFILES_IDMAPPED_MOUNTS = idmapped-mounts.c utils.c
+TARGETS = vfstest mount-idmapped
+CFILES_VFSTEST = vfstest.c utils.c
CFILES_MOUNT_IDMAPPED = mount-idmapped.c utils.c
HFILES = missing.h utils.h
include $(BUILDRULES)
-idmapped-mounts: $(CFILES_IDMAPPED_MOUNTS)
+vfstest: $(CFILES_VFSTEST)
@echo " [CC] $@"
- $(Q)$(LTLINK) $(CFILES_IDMAPPED_MOUNTS) -o $@ $(CFLAGS) $(LDFLAGS) $(LDLIBS)
+ $(Q)$(LTLINK) $(CFILES_VFSTEST) -o $@ $(CFLAGS) $(LDFLAGS) $(LDLIBS)
mount-idmapped: $(CFILES_MOUNT_IDMAPPED)
@echo " [CC] $@"
fprintf(stderr, "--fstype Filesystem type used in the tests\n");
fprintf(stderr, "--help Print help\n");
fprintf(stderr, "--mountpoint Mountpoint of device\n");
- fprintf(stderr, "--supported Test whether idmapped mounts are supported on this filesystem\n");
+ fprintf(stderr, "--idmapped-mounts-supported Test whether idmapped mounts are supported on this filesystem\n");
fprintf(stderr, "--scratch-mountpoint Mountpoint of scratch device used in the tests\n");
fprintf(stderr, "--scratch-device Scratch device used in the tests\n");
fprintf(stderr, "--test-core Run core idmapped mount testsuite\n");
{"mountpoint", required_argument, 0, 'm'},
{"scratch-mountpoint", required_argument, 0, 'a'},
{"scratch-device", required_argument, 0, 'e'},
- {"supported", no_argument, 0, 's'},
+ {"idmapped-mounts-supported", no_argument, 0, 's'},
{"help", no_argument, 0, 'h'},
{"test-core", no_argument, 0, 'c'},
{"test-fscaps-regression", no_argument, 0, 'g'},
{
int fret, ret;
int index = 0;
- bool supported = false, test_btrfs = false, test_core = false,
- test_fscaps_regression = false, test_nested_userns = false,
- test_setattr_fix_968219708108 = false,
+ bool idmapped_mounts_supported = false, test_btrfs = false,
+ test_core = false, test_fscaps_regression = false,
+ test_nested_userns = false, test_setattr_fix_968219708108 = false,
test_setxattr_fix_705191b03d50 = false;
while ((ret = getopt_long_only(argc, argv, "", longopts, &index)) != -1) {
t_mountpoint = optarg;
break;
case 's':
- supported = true;
+ idmapped_mounts_supported = true;
break;
case 'c':
test_core = true;
die("failed to open %s", t_mountpoint_scratch);
t_fs_allow_idmap = fs_allow_idmap();
- if (supported) {
+ if (idmapped_mounts_supported) {
/*
* Caller just wants to know whether the filesystem we're on
* supports idmapped mounts.