From: Josef 'Jeff' Sipek Date: Fri, 16 Nov 2007 19:55:05 +0000 (-0500) Subject: Unionfs: Change free_dentry_private_info to take a struct dentry X-Git-Url: https://git.fsl.cs.sunysb.edu/?a=commitdiff_plain;h=a5f086792d3943fd587fa85db5e9ccd27cdac5ed;p=unionfs-odf.git Unionfs: Change free_dentry_private_info to take a struct dentry This makes it more symmetric with new_dentry_private_info. Signed-off-by: Josef 'Jeff' Sipek --- diff --git a/fs/unionfs/dentry.c b/fs/unionfs/dentry.c index d38f1ae2c1..4c51fe530b 100644 --- a/fs/unionfs/dentry.c +++ b/fs/unionfs/dentry.c @@ -472,8 +472,7 @@ static void unionfs_d_release(struct dentry *dentry) out_free: /* No need to unlock it, because it is disappeared. */ - free_dentry_private_data(UNIONFS_D(dentry)); - dentry->d_fsdata = NULL; /* just to be safe */ + free_dentry_private_data(dentry); out: return; diff --git a/fs/unionfs/lookup.c b/fs/unionfs/lookup.c index 61c6119015..b4c489c50d 100644 --- a/fs/unionfs/lookup.c +++ b/fs/unionfs/lookup.c @@ -18,6 +18,8 @@ #include "union.h" +static int realloc_dentry_private_data(struct dentry *dentry); + /* The rest of these are utility functions for lookup. */ /* diff --git a/fs/unionfs/main.c b/fs/unionfs/main.c index e8eb67c6bf..85eda2666a 100644 --- a/fs/unionfs/main.c +++ b/fs/unionfs/main.c @@ -763,7 +763,7 @@ static int unionfs_read_super(struct super_block *sb, void *raw_data, out_freedpd: if (UNIONFS_D(sb->s_root)) { kfree(UNIONFS_D(sb->s_root)->lower_paths); - free_dentry_private_data(UNIONFS_D(sb->s_root)); + free_dentry_private_data(sb->s_root); } dput(sb->s_root); diff --git a/fs/unionfs/union.h b/fs/unionfs/union.h index aafd2a2a87..707e30629d 100644 --- a/fs/unionfs/union.h +++ b/fs/unionfs/union.h @@ -254,9 +254,8 @@ static inline void unionfs_double_lock_dentry(struct dentry *d1, unionfs_lock_dentry(d2); } -extern int realloc_dentry_private_data(struct dentry *dentry); extern int new_dentry_private_data(struct dentry *dentry); -extern void free_dentry_private_data(struct unionfs_dentry_info *udi); +extern void free_dentry_private_data(struct dentry *dentry); extern void update_bstart(struct dentry *dentry); /*