commit 7b33055e5756af3e57999f46e6785608ca8a25b9
Author: Yiannis Pericleous <[EMAIL PROTECTED]>
Date:   Thu Apr 12 16:41:06 2007 -0400

    use notify_change instead of inode_setattr for setting opaqueness

diff --git a/fs/unionfs/odf.c b/fs/unionfs/odf.c
index 7664935..5703006 100644
--- a/fs/unionfs/odf.c
+++ b/fs/unionfs/odf.c
@@ -1044,7 +1044,7 @@ retry:
 
                /* set opaqueness to 0 or -1 */
                opaque = (flags & ODF_LOOKUP_OPQ) ? osi->opaque_branch_id : -1;
-               __odf_set_opaque(odf_dentry->d_inode, opaque);
+               __odf_set_opaque(odf_dentry, opaque);
        }
        else {
                /* hardlinks, check if link inode is same as odf_dentry inode,
@@ -1401,18 +1401,18 @@ int odf_get_opaque(struct super_block *sb, struct 
dentry *dentry)
 int odf_set_opaque(struct dentry *dentry, int branch)
 {
        struct odf_dentry_info *odi = UNIONFS_D(dentry)->odf_info;
-       int err = __odf_set_opaque(odi->dentry->d_inode, branch);
+       int err = __odf_set_opaque(odi->dentry, branch);
        if (!err)
                odi->opaque = branch;
        return err;
 }
 
-int __odf_set_opaque(struct inode *i, int branch) 
+int __odf_set_opaque(struct dentry *d, int branch) 
 {
        struct iattr ia;
        ia.ia_valid = ATTR_GID;
        ia.ia_gid = branch + 1;  /* since gid is unsigned */
-       return inode_setattr(i, &ia);
+       return notify_change(d, &ia);
 }
 
 /* 
diff --git a/fs/unionfs/odf.h b/fs/unionfs/odf.h
index aadda01..6dbddea 100644
--- a/fs/unionfs/odf.h
+++ b/fs/unionfs/odf.h
@@ -116,7 +116,7 @@ int odf_is_opaque(struct dentry *dentry);
 int odf_get_opaque(struct super_block *sb, struct dentry *dentry);
 int odf_set_opaque(struct dentry *dentry, int branch);
 int __odf_is_opaque(struct inode *i);
-int __odf_set_opaque(struct inode *i, int branch);
+int __odf_set_opaque(struct dentry *d, int branch);
 #define __odf_get_opaque(i) (i->i_gid -1)
 
 /* cleanup thread functions */
_______________________________________________
unionfs-cvs mailing list: http://unionfs.filesystems.org/
[email protected]
http://www.fsl.cs.sunysb.edu/mailman/listinfo/unionfs-cvs

Reply via email to