Test f2fs SELinux support
Stephen Smalley
maintainerPATCH 1/1 Test f2fs SELinux support
Add f2fs to the set of filesystem types being tested.
Signed-off-by Stephen Smalley <[email protected]>
--- README.md | 2 ++ defconfig | 2 ++ tests/Makefile | 2 +- tests/filesystem/Filesystem.pm | 3 +++ tests/filesystem/f2fs | 1 + tests/fs_filesystem/f2fs | 1 + 6 files changed, 10 insertions(+), 1 deletion(-) create mode 120000 tests/filesystem/f2fs create mode 120000 tests/fs_filesystem/f2fs
README.md +2 -0
@@ -59,6 +59,7 @@ similar dependencies): * kernel-devel _(used by the kernel module tests)_ * quota, xfsprogs-devel and libuuid-devel _(used by the filesystem tests)_ * e2fsprogs _(used by the ext4 filesystem tests)_ +* f2fs-tools _(used by the f2fs filesystem tests)_ * jfsutils _(used by the jfs filesystem tests)_ * dosfstools _(used by the vfat filesystem tests)_ * btrfs-progs _(used by the btrfs filesystem tests)_
@@ -89,6 +90,7 @@ following command (NOTE: On Fedora 32 and below you need to remove xfsprogs-devel \ libuuid-devel \ e2fsprogs \ + f2fs-tools \ jfsutils \ dosfstools \ btrfs-progs \
defconfig +2 -0
@@ -33,6 +33,8 @@ CONFIG_EXT4_FS_SECURITY=y CONFIG_JFS_SECURITY=y CONFIG_XFS_SECURITY=y CONFIG_JFFS2_FS_SECURITY=y +CONFIG_F2FS_FS=m +CONFIG_F2FS_FS_SECURITY=y # Network protocol implementations. # These are enabled to test the extended socket classes in
tests/Makefile +1 -1
@@ -4,7 +4,7 @@ SBINDIR ?= $(PREFIX)/sbin POLDEV ?= $(PREFIX)/share/selinux/devel INCLUDEDIR ?= $(PREFIX)/include SELINUXFS ?= /sys/fs/selinux -FILESYSTEMS ?= ext4 xfs jfs vfat btrfs +FILESYSTEMS ?= ext4 xfs jfs vfat btrfs f2fs export CFLAGS+=-g -O0 -Wall -D_GNU_SOURCE
tests/filesystem/Filesystem.pm +3 -0
@@ -129,6 +129,9 @@ sub make_fs { elsif ( $mk_type eq "btrfs" ) { $mk_size = 128; } + elsif ( $mk_type eq "f2fs" ) { + $mk_size = 64; + } print "Create $mk_dir/fstest with dd\n"; $result =
tests/filesystem/f2fs new file +1 -0
@@ -0,0 +1 @@ +.
tests/fs_filesystem/f2fs new file +1 -0
@@ -0,0 +1 @@ +.
Signature · 1 line
2.53.0
Ondrej Mosnacek
AppliedQuoted 4 lines · Stephen Smalley
Add f2fs to the set of filesystem types being tested.
Signed-off-by Stephen Smalley <[email protected]>
Quoted 10 lines
--- README.md | 2 ++ defconfig | 2 ++ tests/Makefile | 2 +- tests/filesystem/Filesystem.pm | 3 +++ tests/filesystem/f2fs | 1 + tests/fs_filesystem/f2fs | 1 + 6 files changed, 10 insertions(+), 1 deletion(-) create mode 120000 tests/filesystem/f2fs create mode 120000 tests/fs_filesystem/f2fs
Thanks, applied with minor corrections (tab vs. spaces & added the new dep to tmt/tests.fmf):
https://github.com/SELinuxProject/selinux-testsuite/commit/03577f572fea0def8f3b7ba86c88f3ed292a6c03
Signature · 3 lines
Ondrej Mosnacek Senior Software Engineer, Linux Security - SELinux kernel Red Hat, Inc.