summaryrefslogtreecommitdiff
path: root/include/linux/fs.h
diff options
context:
space:
mode:
authorTom Rini <trini@kernel.crashing.org>2005-02-21 22:12:49 -0800
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-02-21 22:12:49 -0800
commited712dbb567d319f51dde0585a7ebbcbd9aed354 (patch)
treeec09c6c9d5844cfa94955ad35a85fdd6d49f4b97 /include/linux/fs.h
parent0f4389e9ea7fab8b28c40a1730c1b895211430a8 (diff)
[PATCH] Re-order <linux/fs.h> includes to fix userland breakage
The following moves all includes <linux/fs.h> (except <linux/ioctl.h> and <linux/config.h> down to below the existing __KERNEL__ test. None of these includes are needed by the user-visible portions of the header, and in some cases can cause userland apps to break. For example, LTP and sash with an empty <linux/autoconf.h> will fail thusly: cc -Wall -I../../include -g -Wall -I../../../../include -Wall setrlimit02.c -L../../../../lib -lltp -o setrlimit02 In file included from /usr/include/asm/atomic.h:6, from /usr/include/linux/fs.h:20, from setrlimit02.c:46: /usr/include/asm/processor.h:68: error: `CONFIG_X86_L1_CACHE_SHIFT' undeclared here (not in a function) /usr/include/asm/processor.h:68: error: requested alignment is not a constant Build/run tested with a glibc rebuild as well. Signed-off-by: Tom Rini <trini@kernel.crashing.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/linux/fs.h')
-rw-r--r--include/linux/fs.h37
1 files changed, 19 insertions, 18 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 84b3b114f943..07f41a111113 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -7,25 +7,7 @@
*/
#include <linux/config.h>
-#include <linux/linkage.h>
-#include <linux/limits.h>
-#include <linux/wait.h>
-#include <linux/types.h>
-#include <linux/kdev_t.h>
#include <linux/ioctl.h>
-#include <linux/dcache.h>
-#include <linux/stat.h>
-#include <linux/cache.h>
-#include <linux/kobject.h>
-#include <asm/atomic.h>
-
-struct iovec;
-struct nameidata;
-struct pipe_inode_info;
-struct poll_table_struct;
-struct kstatfs;
-struct vm_area_struct;
-struct vfsmount;
/*
* It's silly to have NR_OPEN bigger than NR_FILE, but you can change
@@ -216,14 +198,33 @@ extern int dir_notify_enable;
#ifdef __KERNEL__
+#include <linux/linkage.h>
+#include <linux/limits.h>
+#include <linux/wait.h>
+#include <linux/types.h>
+#include <linux/kdev_t.h>
+#include <linux/dcache.h>
+#include <linux/stat.h>
+#include <linux/cache.h>
+#include <linux/kobject.h>
#include <linux/list.h>
#include <linux/radix-tree.h>
#include <linux/prio_tree.h>
#include <linux/audit.h>
#include <linux/init.h>
+
+#include <asm/atomic.h>
#include <asm/semaphore.h>
#include <asm/byteorder.h>
+struct iovec;
+struct nameidata;
+struct pipe_inode_info;
+struct poll_table_struct;
+struct kstatfs;
+struct vm_area_struct;
+struct vfsmount;
+
/* Used to be a macro which just called the function, now just a function */
extern void update_atime (struct inode *);