Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1480395 > unrolled thread
| Started by | Shuah Khan <shuahkh@osg.samsung.com> |
|---|---|
| First post | 2016-09-10 00:30 +0200 |
| Last post | 2016-09-10 02:10 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 1/9] selftests: move dnotify_test from Documentation/filesystems Shuah Khan <shuahkh@osg.samsung.com> - 2016-09-10 00:30 +0200
Re: [PATCH 1/9] selftests: move dnotify_test from Documentation/filesystems kbuild test robot <lkp@intel.com> - 2016-09-10 02:10 +0200
| From | Shuah Khan <shuahkh@osg.samsung.com> |
|---|---|
| Date | 2016-09-10 00:30 +0200 |
| Subject | [PATCH 1/9] selftests: move dnotify_test from Documentation/filesystems |
| Message-ID | <sfCt3-jt-5@gated-at.bofh.it> |
Move dnotify_test from Documentation/filesystems to selftests/filesystems
Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
---
Documentation/filesystems/Makefile | 5 ----
Documentation/filesystems/dnotify_test.c | 34 ----------------------
tools/testing/selftests/filesystems/Makefile | 5 ++++
tools/testing/selftests/filesystems/dnotify_test.c | 34 ++++++++++++++++++++++
4 files changed, 39 insertions(+), 39 deletions(-)
delete mode 100644 Documentation/filesystems/Makefile
delete mode 100644 Documentation/filesystems/dnotify_test.c
create mode 100644 tools/testing/selftests/filesystems/Makefile
create mode 100644 tools/testing/selftests/filesystems/dnotify_test.c
diff --git a/Documentation/filesystems/Makefile b/Documentation/filesystems/Makefile
deleted file mode 100644
index 883010c..0000000
--- a/Documentation/filesystems/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-# List of programs to build
-hostprogs-y := dnotify_test
-
-# Tell kbuild to always build the programs
-always := $(hostprogs-y)
diff --git a/Documentation/filesystems/dnotify_test.c b/Documentation/filesystems/dnotify_test.c
deleted file mode 100644
index 8b37b4a..0000000
--- a/Documentation/filesystems/dnotify_test.c
+++ /dev/null
@@ -1,34 +0,0 @@
-#define _GNU_SOURCE /* needed to get the defines */
-#include <fcntl.h> /* in glibc 2.2 this has the needed
- values defined */
-#include <signal.h>
-#include <stdio.h>
-#include <unistd.h>
-
-static volatile int event_fd;
-
-static void handler(int sig, siginfo_t *si, void *data)
-{
- event_fd = si->si_fd;
-}
-
-int main(void)
-{
- struct sigaction act;
- int fd;
-
- act.sa_sigaction = handler;
- sigemptyset(&act.sa_mask);
- act.sa_flags = SA_SIGINFO;
- sigaction(SIGRTMIN + 1, &act, NULL);
-
- fd = open(".", O_RDONLY);
- fcntl(fd, F_SETSIG, SIGRTMIN + 1);
- fcntl(fd, F_NOTIFY, DN_MODIFY|DN_CREATE|DN_MULTISHOT);
- /* we will now be notified if any of the files
- in "." is modified or new files are created */
- while (1) {
- pause();
- printf("Got event on fd=%d\n", event_fd);
- }
-}
diff --git a/tools/testing/selftests/filesystems/Makefile b/tools/testing/selftests/filesystems/Makefile
new file mode 100644
index 0000000..883010c
--- /dev/null
+++ b/tools/testing/selftests/filesystems/Makefile
@@ -0,0 +1,5 @@
+# List of programs to build
+hostprogs-y := dnotify_test
+
+# Tell kbuild to always build the programs
+always := $(hostprogs-y)
diff --git a/tools/testing/selftests/filesystems/dnotify_test.c b/tools/testing/selftests/filesystems/dnotify_test.c
new file mode 100644
index 0000000..8b37b4a
--- /dev/null
+++ b/tools/testing/selftests/filesystems/dnotify_test.c
@@ -0,0 +1,34 @@
+#define _GNU_SOURCE /* needed to get the defines */
+#include <fcntl.h> /* in glibc 2.2 this has the needed
+ values defined */
+#include <signal.h>
+#include <stdio.h>
+#include <unistd.h>
+
+static volatile int event_fd;
+
+static void handler(int sig, siginfo_t *si, void *data)
+{
+ event_fd = si->si_fd;
+}
+
+int main(void)
+{
+ struct sigaction act;
+ int fd;
+
+ act.sa_sigaction = handler;
+ sigemptyset(&act.sa_mask);
+ act.sa_flags = SA_SIGINFO;
+ sigaction(SIGRTMIN + 1, &act, NULL);
+
+ fd = open(".", O_RDONLY);
+ fcntl(fd, F_SETSIG, SIGRTMIN + 1);
+ fcntl(fd, F_NOTIFY, DN_MODIFY|DN_CREATE|DN_MULTISHOT);
+ /* we will now be notified if any of the files
+ in "." is modified or new files are created */
+ while (1) {
+ pause();
+ printf("Got event on fd=%d\n", event_fd);
+ }
+}
--
2.7.4
[toc] | [next] | [standalone]
| From | kbuild test robot <lkp@intel.com> |
|---|---|
| Date | 2016-09-10 02:10 +0200 |
| Subject | Re: [PATCH 1/9] selftests: move dnotify_test from Documentation/filesystems |
| Message-ID | <sfE1P-1ky-1@gated-at.bofh.it> |
| In reply to | #1480395 |
[Multipart message — attachments visible in raw view] — view raw
Hi Shuah,
[auto build test ERROR on linus/master]
[also build test ERROR on v4.8-rc5 next-20160909]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
[Suggest to use git(>=2.9.0) format-patch --base=<commit> (or --base=auto for convenience) to record what (public, well-known) commit your patch series was built on]
[Check https://git-scm.com/docs/git-format-patch for more information]
url: https://github.com/0day-ci/linux/commits/Shuah-Khan/Move-runnable-code-tests-from-Documentation-to-selftests/20160910-063538
config: i386-tinyconfig (attached as .config)
compiler: gcc-6 (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
All errors (new ones prefixed by >>):
>> scripts/Makefile.build:44: Documentation/filesystems/Makefile: No such file or directory
>> make[3]: *** No rule to make target 'Documentation/filesystems/Makefile'.
make[3]: Failed to remake makefile 'Documentation/filesystems/Makefile'.
vim +44 scripts/Makefile.build
f77bf0142 Sam Ravnborg 2007-10-15 28 ldflags-y :=
d72e5edbf Sam Ravnborg 2007-05-28 29
720097d89 Sam Ravnborg 2009-04-19 30 subdir-asflags-y :=
720097d89 Sam Ravnborg 2009-04-19 31 subdir-ccflags-y :=
720097d89 Sam Ravnborg 2009-04-19 32
3156fd052 Robert P. J. Day 2008-02-18 33 # Read auto.conf if it exists, otherwise ignore
c955ccafc Roman Zippel 2006-06-08 34 -include include/config/auto.conf
^1da177e4 Linus Torvalds 2005-04-16 35
20a468b51 Sam Ravnborg 2006-01-22 36 include scripts/Kbuild.include
20a468b51 Sam Ravnborg 2006-01-22 37
3156fd052 Robert P. J. Day 2008-02-18 38 # For backward compatibility check that these variables do not change
0c53c8e6e Sam Ravnborg 2007-10-14 39 save-cflags := $(CFLAGS)
0c53c8e6e Sam Ravnborg 2007-10-14 40
2a6914703 Sam Ravnborg 2005-07-25 41 # The filename Kbuild has precedence over Makefile
db8c1a7b2 Sam Ravnborg 2005-07-27 42 kbuild-dir := $(if $(filter /%,$(src)),$(src),$(srctree)/$(src))
0c53c8e6e Sam Ravnborg 2007-10-14 43 kbuild-file := $(if $(wildcard $(kbuild-dir)/Kbuild),$(kbuild-dir)/Kbuild,$(kbuild-dir)/Makefile)
0c53c8e6e Sam Ravnborg 2007-10-14 @44 include $(kbuild-file)
^1da177e4 Linus Torvalds 2005-04-16 45
0c53c8e6e Sam Ravnborg 2007-10-14 46 # If the save-* variables changed error out
0c53c8e6e Sam Ravnborg 2007-10-14 47 ifeq ($(KBUILD_NOPEDANTIC),)
0c53c8e6e Sam Ravnborg 2007-10-14 48 ifneq ("$(save-cflags)","$(CFLAGS)")
49c57d254 Arnaud Lacombe 2011-08-15 49 $(error CFLAGS was changed in "$(kbuild-file)". Fix it to use ccflags-y)
0c53c8e6e Sam Ravnborg 2007-10-14 50 endif
0c53c8e6e Sam Ravnborg 2007-10-14 51 endif
4a5838ad9 Borislav Petkov 2011-03-01 52
:::::: The code at line 44 was first introduced by commit
:::::: 0c53c8e6eb456cde30f2305421c605713856abc8 kbuild: check for wrong use of CFLAGS
:::::: TO: Sam Ravnborg <sam@neptun.(none)>
:::::: CC: Sam Ravnborg <sam@neptun.(none)>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web