--- /dev/null
+From git-commits-head-owner@vger.kernel.org Fri Jul 14 22:59:23 2006
+Date: Sat, 15 Jul 2006 05:59:19 GMT
+Message-Id: <200607150559.k6F5xJN0006555@hera.kernel.org>
+From: Linus Torvalds <torvalds@osdl.org>
+To: git-commits-head@vger.kernel.org
+Subject: Relax /proc fix a bit
+
+Relax /proc fix a bit
+
+Clearign all of i_mode was a bit draconian. We only really care about
+S_ISUID/ISGID, after all.
+
+Signed-off-by: Linus Torvalds <torvalds@osdl.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ fs/proc/base.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- linux-2.6.17.5.orig/fs/proc/base.c
++++ linux-2.6.17.5/fs/proc/base.c
+@@ -1404,8 +1404,8 @@ static int pid_revalidate(struct dentry
+ } else {
+ inode->i_uid = 0;
+ inode->i_gid = 0;
+- inode->i_mode = 0;
+ }
++ inode->i_mode &= ~(S_ISUID | S_ISGID);
+ security_task_to_inode(task, inode);
+ return 1;
+ }
+@@ -1433,6 +1433,7 @@ static int tid_fd_revalidate(struct dent
+ inode->i_uid = 0;
+ inode->i_gid = 0;
+ }
++ inode->i_mode &= ~(S_ISUID | S_ISGID);
+ security_task_to_inode(task, inode);
+ return 1;
+ }