tests/Makefile: add kernel version check for watchkey
PATCH 1/1 tests/Makefile: add kernel version check for watchkey
The corresponding header files might be available even when the running kernel doesn't support the tested functionality, so add a kernel version check for this test (key notifications were introduced in kernel 5.8).
--- tests/Makefile | 2 ++ 1 file changed, 2 insertions(+)
tests/Makefile +2 -0
@@ -124,8 +124,10 @@ endif endif ifeq ($(shell grep -q all_key_perms $(POLDEV)/include/support/all_perms.spt && test -e $(INCLUDEDIR)/linux/watch_queue.h && grep -qs KEYCTL_WATCH_KEY $(INCLUDEDIR)/linux/keyctl.h && echo true),true) +ifneq ($(shell ./kvercmp $$(uname -r) 5.8),-1) SUBDIRS += watchkey endif +endif ifeq ($(DISTRO),RHEL4) SUBDIRS:=$(filter-out bounds dyntrace dyntrans inet_socket mmap nnp_nosuid overlay unix_socket, $(SUBDIRS))
Signature · 1 line
2.26.2
Quoted 7 lines · Ondrej Mosnacek
The corresponding header files might be available even when the running kernel doesn't support the tested functionality, so add a kernel version check for this test (key notifications were introduced in kernel 5.8).
Fixes 34b7da22ef88 ("selinux-testsuite: Add check for key changes on watch_queue")Signed-off-by Ondrej Mosnacek <[email protected]>
Merge at will.
Quoted 6 lines · Stephen Smalley
Quoted 5 lines · Ondrej Mosnacek
The corresponding header files might be available even when the running kernel doesn't support the tested functionality, so add a kernel version check for this test (key notifications were introduced in kernel 5.8).
Quoted 6 lines
Quoted 2 lines
Fixes 34b7da22ef88 ("selinux-testsuite: Add check for key changes on watch_queue")Signed-off-by Ondrej Mosnacek <[email protected]>Acked-by Stephen Smalley <[email protected]>Merge at will.
Thanks, also merged.
Signature · 3 lines
Ondrej Mosnacek Software Engineer, Platform Security - SELinux kernel Red Hat, Inc.