aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/linux/types.h
diff options
context:
space:
mode:
authorJustin P. Mattock <justinmattock@gmail.com>2010-07-01 14:28:27 -0700
committerJiri Kosina <jkosina@suse.cz>2010-07-11 21:38:56 +0200
commit69c8f52b3897f2faf8510ea7ede8fffabe26c531 (patch)
tree89589a401031070707721932421ba7eb1cc85bd6 /include/linux/types.h
parentRevert "Remove dead CONFIG_SIBYTE_BCM1480_PROF" (diff)
downloadwireguard-linux-69c8f52b3897f2faf8510ea7ede8fffabe26c531.tar.xz
wireguard-linux-69c8f52b3897f2faf8510ea7ede8fffabe26c531.zip
fix #warning about using kernel headers in userpsace
Move the preprocessor #warning message: warning: #warning Attempt to use kernel headers from user space, see http://kernelnewbies.org/KernelHeaders from kernel.h to types.h. And also fixe the #warning message due to the preprocessor not being able to read the web address due to it thinking it was the start of a comment. also remove the extra #ifndef _KERNEL_ since it's already there. Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'include/linux/types.h')
-rw-r--r--include/linux/types.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/types.h b/include/linux/types.h
index 23d237a075e2..331d8baabcf2 100644
--- a/include/linux/types.h
+++ b/include/linux/types.h
@@ -8,7 +8,10 @@
#define DECLARE_BITMAP(name,bits) \
unsigned long name[BITS_TO_LONGS(bits)]
-
+#else
+#ifndef __EXPORTED_HEADERS__
+#warning "Attempt to use kernel headers from user space, see http://kernelnewbies.org/KernelHeaders"
+#endif /* __EXPORTED_HEADERS__ */
#endif
#include <linux/posix_types.h>