.old..........pc/vfs_nointent_2.6.0-suse/fs/namei.c
.new.........fs/namei.c
-Index: linux-2.6.3-20/fs/namei.c
+Index: linux-2.6.4-51.0/fs/namei.c
===================================================================
---- linux-2.6.3-20.orig/fs/namei.c 2004-03-08 14:32:24.000000000 -0800
-+++ linux-2.6.3-20/fs/namei.c 2004-03-08 14:40:01.000000000 -0800
+--- linux-2.6.4-51.0.orig/fs/namei.c 2004-04-05 17:36:42.000000000 -0400
++++ linux-2.6.4-51.0/fs/namei.c 2004-04-05 17:36:43.000000000 -0400
@@ -1276,7 +1276,7 @@
if (!error) {
DQUOT_INIT(inode);
name = getname(pathname);
if(IS_ERR(name))
-@@ -1716,6 +1737,16 @@
+@@ -1716,6 +1737,14 @@
error = -EBUSY;
goto exit1;
}
-+
+ if (nd.dentry->d_inode->i_op->rmdir_raw) {
+ struct inode_operations *op = nd.dentry->d_inode->i_op;
-+
++
+ error = op->rmdir_raw(&nd);
+ /* the file system wants to use normal vfs path now */
+ if (error != -EOPNOTSUPP)
+ goto exit1;
+ }
-+
down(&nd.dentry->d_inode->i_sem);
dentry = lookup_hash(&nd.last, nd.dentry);
error = PTR_ERR(dentry);
exit5:
dput(new_dentry);
exit4:
-.old..........pc/vfs_nointent_2.6.0-suse/fs/open.c
-.new.........fs/open.c
-Index: linux-2.6.3-20/fs/open.c
+Index: linux-2.6.4-51.0/fs/open.c
===================================================================
---- linux-2.6.3-20.orig/fs/open.c 2004-03-08 14:23:40.000000000 -0800
-+++ linux-2.6.3-20/fs/open.c 2004-03-08 14:40:01.000000000 -0800
-@@ -180,9 +180,10 @@
+--- linux-2.6.4-51.0.orig/fs/open.c 2004-04-05 17:36:42.000000000 -0400
++++ linux-2.6.4-51.0/fs/open.c 2004-04-06 01:37:39.000000000 -0400
+@@ -187,9 +187,10 @@
return error;
}
struct iattr newattrs;
/* Not pretty: "inode->i_size" shouldn't really be signed. But it is. */
-@@ -192,7 +193,14 @@
- newattrs.ia_size = length;
+@@ -200,7 +201,14 @@
newattrs.ia_valid = ATTR_SIZE | ATTR_CTIME;
down(&dentry->d_inode->i_sem);
+ down_write(&dentry->d_inode->i_alloc_sem);
- err = notify_change(dentry, &newattrs);
+ if (called_from_open)
-+ newattrs.ia_valid |= ATTR_FROM_OPEN;
-+ if (op->setattr_raw) {
-+ newattrs.ia_valid |= ATTR_RAW;
-+ newattrs.ia_ctime = CURRENT_TIME;
-+ err = op->setattr_raw(dentry->d_inode, &newattrs);
-+ } else
-+ err = notify_change(dentry, &newattrs);
++ newattrs.ia_valid |= ATTR_FROM_OPEN;
++ if (op->setattr_raw) {
++ newattrs.ia_valid |= ATTR_RAW;
++ newattrs.ia_ctime = CURRENT_TIME;
++ err = op->setattr_raw(dentry->d_inode, &newattrs);
++ } else
++ err = notify_change(dentry, &newattrs);
+ up_write(&dentry->d_inode->i_alloc_sem);
up(&dentry->d_inode->i_sem);
return err;
- }
-@@ -247,7 +255,7 @@
+@@ -256,7 +264,7 @@
error = locks_verify_truncate(inode, NULL, length);
if (!error) {
DQUOT_INIT(inode);
}
put_write_access(inode);
-@@ -299,7 +307,7 @@
+@@ -308,7 +316,7 @@
error = locks_verify_truncate(inode, file, length);
if (!error)
out_putf:
fput(file);
out:
-@@ -378,9 +386,19 @@
+@@ -387,9 +395,19 @@
(error = permission(inode,MAY_WRITE,&nd)) != 0)
goto dput_and_out;
}
dput_and_out:
path_release(&nd);
out:
-@@ -431,9 +449,19 @@
+@@ -440,9 +458,19 @@
(error = permission(inode,MAY_WRITE,&nd)) != 0)
goto dput_and_out;
}
dput_and_out:
path_release(&nd);
out:
-@@ -634,6 +662,18 @@
- if (IS_RDONLY(inode))
- goto dput_and_out;
-
+@@ -592,36 +620,52 @@
+ return error;
+ }
+
+-asmlinkage long sys_fchmod(unsigned int fd, mode_t mode)
++int chmod_common(struct dentry *dentry, mode_t mode)
+ {
+- struct inode * inode;
+- struct dentry * dentry;
+- struct file * file;
+- int err = -EBADF;
++ struct inode * inode = dentry->d_inode;
+ struct iattr newattrs;
++ int error = -EROFS;
+
+- file = fget(fd);
+- if (!file)
++ if (IS_RDONLY(inode))
+ goto out;
++
+ if (inode->i_op->setattr_raw) {
-+ struct inode_operations *op = nd.dentry->d_inode->i_op;
-+
++ struct inode_operations *op = dentry->d_inode->i_op;
+
+- dentry = file->f_dentry;
+- inode = dentry->d_inode;
+ newattrs.ia_mode = mode;
+ newattrs.ia_valid = ATTR_MODE | ATTR_CTIME;
+ newattrs.ia_valid |= ATTR_RAW;
+ error = op->setattr_raw(inode, &newattrs);
+ /* the file system wants to use normal vfs path now */
+ if (error != -EOPNOTSUPP)
-+ goto dput_and_out;
++ goto out;
+ }
-+
- error = -EPERM;
+
+- err = -EROFS;
+- if (IS_RDONLY(inode))
+- goto out_putf;
+- err = -EPERM;
++ error = -EPERM;
if (IS_IMMUTABLE(inode) || IS_APPEND(inode))
- goto dput_and_out;
-@@ -667,6 +707,18 @@
+- goto out_putf;
++ goto out;
++
+ down(&inode->i_sem);
+ if (mode == (mode_t) -1)
+ mode = inode->i_mode;
+ newattrs.ia_mode = (mode & S_IALLUGO) | (inode->i_mode & ~S_IALLUGO);
+ newattrs.ia_valid = ATTR_MODE | ATTR_CTIME;
+- err = notify_change(dentry, &newattrs);
++ error = notify_change(dentry, &newattrs);
+ up(&inode->i_sem);
++out:
++ return error;
++}
+
+-out_putf:
++asmlinkage long sys_fchmod(unsigned int fd, mode_t mode)
++{
++ struct file * file;
++ int err = -EBADF;
++
++ file = fget(fd);
++ if (!file)
++ goto out;
++
++ err = chmod_common(file->f_dentry, mode);
+ fput(file);
+ out:
+ return err;
+@@ -630,32 +674,13 @@
+ asmlinkage long sys_chmod(const char __user * filename, mode_t mode)
+ {
+ struct nameidata nd;
+- struct inode * inode;
+ int error;
+- struct iattr newattrs;
+
+ error = user_path_walk(filename, &nd);
+ if (error)
+ goto out;
+- inode = nd.dentry->d_inode;
+-
+- error = -EROFS;
+- if (IS_RDONLY(inode))
+- goto dput_and_out;
+-
+- error = -EPERM;
+- if (IS_IMMUTABLE(inode) || IS_APPEND(inode))
+- goto dput_and_out;
+-
+- down(&inode->i_sem);
+- if (mode == (mode_t) -1)
+- mode = inode->i_mode;
+- newattrs.ia_mode = (mode & S_IALLUGO) | (inode->i_mode & ~S_IALLUGO);
+- newattrs.ia_valid = ATTR_MODE | ATTR_CTIME;
+- error = notify_change(nd.dentry, &newattrs);
+- up(&inode->i_sem);
+
+-dput_and_out:
++ error = chmod_common(nd.dentry, mode);
+ path_release(&nd);
+ out:
+ return error;
+@@ -676,6 +701,18 @@
if (IS_RDONLY(inode))
goto out;
error = -EPERM;
if (IS_IMMUTABLE(inode) || IS_APPEND(inode))
goto out;
newattrs.ia_valid = ATTR_CTIME;
-@@ -680,6 +732,7 @@
+@@ -689,6 +726,7 @@
}
if (!S_ISDIR(inode->i_mode))
newattrs.ia_valid |= ATTR_KILL_SUID|ATTR_KILL_SGID;
down(&inode->i_sem);
error = notify_change(dentry, &newattrs);
up(&inode->i_sem);
-.old..........pc/vfs_nointent_2.6.0-suse/fs/exec.c
-.new.........fs/exec.c
-Index: linux-2.6.3-20/fs/exec.c
+Index: linux-2.6.4-51.0/fs/exec.c
===================================================================
---- linux-2.6.3-20.orig/fs/exec.c 2004-03-08 14:23:40.000000000 -0800
-+++ linux-2.6.3-20/fs/exec.c 2004-03-08 14:40:01.000000000 -0800
-@@ -1406,7 +1406,7 @@
+--- linux-2.6.4-51.0.orig/fs/exec.c 2004-04-05 17:36:42.000000000 -0400
++++ linux-2.6.4-51.0/fs/exec.c 2004-04-05 17:36:43.000000000 -0400
+@@ -1418,7 +1418,7 @@
goto close_fail;
if (!file->f_op->write)
goto close_fail;
goto close_fail;
retval = binfmt->core_dump(signr, regs, file);
-.old..........pc/vfs_nointent_2.6.0-suse/include/linux/fs.h
-.new.........include/linux/fs.h
-Index: linux-2.6.3-20/include/linux/fs.h
+Index: linux-2.6.4-51.0/include/linux/fs.h
===================================================================
---- linux-2.6.3-20.orig/include/linux/fs.h 2004-03-08 14:23:41.000000000 -0800
-+++ linux-2.6.3-20/include/linux/fs.h 2004-03-08 14:42:10.000000000 -0800
-@@ -838,13 +838,20 @@
+--- linux-2.6.4-51.0.orig/include/linux/fs.h 2004-04-05 17:36:43.000000000 -0400
++++ linux-2.6.4-51.0/include/linux/fs.h 2004-04-05 17:36:43.000000000 -0400
+@@ -866,13 +866,20 @@
int (*create) (struct inode *,struct dentry *,int, struct nameidata *);
struct dentry * (*lookup) (struct inode *,struct dentry *, struct nameidata *);
int (*link) (struct dentry *,struct inode *,struct dentry *);
int (*readlink) (struct dentry *, char __user *,int);
int (*follow_link) (struct dentry *, struct nameidata *);
void (*truncate) (struct inode *);
-@@ -1130,7 +1137,7 @@
+@@ -1169,7 +1176,7 @@
/* fs/open.c */
extern struct file *filp_open(const char *, int, int);
extern struct file * dentry_open(struct dentry *, struct vfsmount *, int);
extern struct file * dentry_open_it(struct dentry *, struct vfsmount *, int, struct lookup_intent *);
-.old..........pc/vfs_nointent_2.6.0-suse/net/unix/af_unix.c
-.new.........net/unix/af_unix.c
-Index: linux-2.6.3-20/net/unix/af_unix.c
+Index: linux-2.6.4-51.0/net/unix/af_unix.c
===================================================================
---- linux-2.6.3-20.orig/net/unix/af_unix.c 2004-03-05 02:07:04.000000000 -0800
-+++ linux-2.6.3-20/net/unix/af_unix.c 2004-03-08 14:40:01.000000000 -0800
-@@ -592,6 +592,7 @@
+--- linux-2.6.4-51.0.orig/net/unix/af_unix.c 2004-04-05 12:42:07.000000000 -0400
++++ linux-2.6.4-51.0/net/unix/af_unix.c 2004-04-05 17:36:43.000000000 -0400
+@@ -676,6 +676,7 @@
int err = 0;
if (sunname->sun_path[0]) {