Message ID | 20200903072812.2281009-1-omosnace@redhat.com (mailing list archive) |
---|---|
State | Accepted |
Delegated to: | Ondrej Mosnáček |
Headers | show |
Series | [testsuite] tests/Makefile: add kernel version check for watchkey | expand |
On Thu, Sep 3, 2020 at 3:28 AM Ondrej Mosnacek <omosnace@redhat.com> wrote: > > 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 <omosnace@redhat.com> Acked-by: Stephen Smalley <stephen.smalley.work@gmail.com> Merge at will.
On Thu, Sep 3, 2020 at 4:15 PM Stephen Smalley <stephen.smalley.work@gmail.com> wrote: > On Thu, Sep 3, 2020 at 3:28 AM Ondrej Mosnacek <omosnace@redhat.com> wrote: > > > > 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 <omosnace@redhat.com> > > Acked-by: Stephen Smalley <stephen.smalley.work@gmail.com> > > Merge at will. Thanks, also merged.
diff --git a/tests/Makefile b/tests/Makefile index 919335b..001639b 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -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))
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 <omosnace@redhat.com> --- tests/Makefile | 2 ++ 1 file changed, 2 insertions(+)