commit 55961b4b5b1bb8714390abbe942f8da095c32044
Author: Yiannis Pericleous <[EMAIL PROTECTED]>
Date:   Fri Apr 6 14:42:49 2007 -0400

    holding off hardlinks until jeffs path_lookup modifications, removed all 
nasty hardlink code

diff --git a/fs/unionfs/odf.c b/fs/unionfs/odf.c
index 49003e4..1ff831a 100644
--- a/fs/unionfs/odf.c
+++ b/fs/unionfs/odf.c
@@ -929,9 +929,6 @@ int odf_lookup(struct dentry *parent, struct dentry 
*dentry, int flags)
        struct file *link_file = NULL;
        char *name, *uuid;
        int bstart, err = 0;
-       __le64 le64;
-       u64 ino = 0;
-       mm_segment_t oldfs;
 
        /* this might be called before interpose */
        if (dbstart(dentry) == dbend(dentry) && dbstart(dentry) == 0) {
@@ -1746,17 +1743,14 @@ int odf_get_opaque(struct super_block *sb, struct 
dentry *dentry)
        if (opaque == -1)
                return -1;
 
-       /* now check all branches for the branch id */
-       for (i = 0; i < sbmax(sb); i++) {
-               if (branch_id(sb, i) == opaque)
-                       return i;
-       }
+       i = branch_id_to_idx(sb, opaque);
 
        /* if this is reached then the opaque branch was deleted, so dentry
         * can no longer be considered opaque
         */
-       odf_set_opaque(dentry, -1);
-       return -1;
+       if (i == -1)
+               odf_set_opaque(dentry, -1);
+       return i;
 }
 
 int __odf_is_opaque(struct inode *i) 
diff --git a/fs/unionfs/odf.h b/fs/unionfs/odf.h
index 0548fea..36669bc 100644
--- a/fs/unionfs/odf.h
+++ b/fs/unionfs/odf.h
@@ -97,7 +97,7 @@ static inline struct odf_dentry_info *odf_lookup_name(struct 
odf_sb_info *osi,
                struct odf_dentry_info *parent, const char *name, int len, 
                int flags, struct odf_dentry_info *old_odi)
 {
-       return __odf_lookup(osi, parent, name, len, flags, old_odi, 0);
+       return __odf_lookup(osi, parent, name, len, flags, old_odi, NULL);
 }
 struct odf_dentry_info *odf_getpath(struct dentry *d_odf, struct odf_sb_info 
*osi, const char *name);
 struct odf_dentry_info *odf_fill_info(struct odf_dentry_info *odi,
_______________________________________________
unionfs-cvs mailing list: http://unionfs.filesystems.org/
[email protected]
http://www.fsl.cs.sunysb.edu/mailman/listinfo/unionfs-cvs

Reply via email to