]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
selftests/filesystems: devpts_pts included wrong header
authorAnders Roxell <anders.roxell@linaro.org>
Wed, 18 Apr 2018 07:52:55 +0000 (09:52 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 3 Aug 2018 05:47:41 +0000 (07:47 +0200)
[ Upstream commit dd4b16b4f9b1b7d9f4a185cb8222e42f3a5daf00 ]

We were picking up the wrong header should use asm/ioctls.h form the kernel
and not the header from the system (sys/ioctl.h). In the current code we
added the correct include and we added the kernel headers path to the CFLAGS.

Fixes: ce290a19609d ("selftests: add devpts selftests")
Signed-off-by: Anders Roxell <anders.roxell@linaro.org>
Acked-by: Christian Brauner <christian.brauner@ubuntu.com>
Signed-off-by: Shuah Khan (Samsung OSG) <shuah@kernel.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/testing/selftests/filesystems/Makefile
tools/testing/selftests/filesystems/devpts_pts.c

index 5c7d7001ad37c34d1ccaf5ef34e05864cbeaa8ed..129880fb42d34c04c343dc88875515dbbb27df91 100644 (file)
@@ -1,5 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0
 
+CFLAGS += -I../../../../usr/include/
 TEST_GEN_PROGS := devpts_pts
 TEST_GEN_PROGS_EXTENDED := dnotify_test
 
index 0f2d9f4279442c6e795d75ff865bb20d44c158f4..a425840dc30cef0311f4c09d46673ad00fb63e86 100644 (file)
@@ -8,7 +8,7 @@
 #include <stdlib.h>
 #include <string.h>
 #include <unistd.h>
-#include <sys/ioctl.h>
+#include <asm/ioctls.h>
 #include <sys/mount.h>
 #include <sys/wait.h>
 #include "../kselftest.h"