Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S261283AbVBVVwL (ORCPT ); Tue, 22 Feb 2005 16:52:11 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S261284AbVBVVwL (ORCPT ); Tue, 22 Feb 2005 16:52:11 -0500 Received: from fed1rmmtao08.cox.net ([68.230.241.31]:26857 "EHLO fed1rmmtao08.cox.net") by vger.kernel.org with ESMTP id S261283AbVBVVwC (ORCPT ); Tue, 22 Feb 2005 16:52:02 -0500 Date: Tue, 22 Feb 2005 14:51:41 -0700 From: Tom Rini To: Linus Torvalds , Andrew Morton , Kernel Mailing List Subject: [2.6.11-rc4 i386] Re-order includes to fix userland breakage Message-ID: <20050222215141.GA30663@smtp.west.cox.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.6+20040907i Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2710 Lines: 87 The following moves all includes (except and 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 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 ===== include/linux/fs.h 1.376 vs edited ===== --- 1.376/include/linux/fs.h 2005-02-03 07:42:40 -07:00 +++ edited/include/linux/fs.h 2005-02-22 14:44:27 -07:00 @@ -7,25 +7,7 @@ */ #include -#include -#include -#include -#include -#include #include -#include -#include -#include -#include -#include - -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,13 +198,32 @@ extern int dir_notify_enable; #ifdef __KERNEL__ +#include +#include +#include +#include +#include +#include +#include +#include +#include #include #include #include #include #include + +#include #include #include + +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 *); -- Tom Rini http://gate.crashing.org/~trini/ - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/