commit abd74cbf36a21f54921e835013cb616366403909
Author: Yiannis Pericleous <[EMAIL PROTECTED]>
Date: Sat Apr 21 11:51:11 2007 -0400
cleanup: keep all top-of-function automatic variables clustered together
Conflicts:
fs/unionfs/dirhelper.c
fs/unionfs/lookup.c
diff --git a/fs/unionfs/branchman.c b/fs/unionfs/branchman.c
index
eba222100958920a17045633b378a9a7ac8ac721..3163e4e72c08154ec61cba5bf4abe0de1d60eff6
100644
--- a/fs/unionfs/branchman.c
+++ b/fs/unionfs/branchman.c
@@ -28,7 +28,6 @@ int unionfs_ioctl_queryfile(struct file
{
int err = 0;
fd_set branchlist;
-
int bstart = 0, bend = 0, bindex = 0;
struct dentry *dentry, *hidden_dentry;
diff --git a/fs/unionfs/commonfops.c b/fs/unionfs/commonfops.c
index
1cb03f1383977093ff7500570b081898b025f7a7..bb83f8a10ec3e4b208027856c33b78c6041d6bf8
100644
--- a/fs/unionfs/commonfops.c
+++ b/fs/unionfs/commonfops.c
@@ -30,7 +30,6 @@ static int copyup_deleted_file(struct fi
const int countersize = sizeof(counter) * 2;
const int nlen = sizeof(".unionfs") + i_inosize + countersize - 1;
char name[nlen + 1];
-
int err;
struct dentry *tmp_dentry = NULL;
struct dentry *hidden_dentry;
@@ -260,7 +259,6 @@ static int open_highest_file(struct file
int bindex, bstart, bend, err = 0;
struct file *hidden_file;
struct dentry *hidden_dentry;
-
struct dentry *dentry = file->f_dentry;
struct inode *parent_inode = dentry->d_parent->d_inode;
struct super_block *sb = dentry->d_sb;
@@ -354,7 +352,6 @@ int unionfs_file_revalidate(struct file
int sbgen, fgen, dgen;
int bstart, bend;
int size;
-
int err = 0;
dentry = file->f_dentry;
diff --git a/fs/unionfs/copyup.c b/fs/unionfs/copyup.c
index
450b1048f73ef54ab042fd14f05a0f6e1768a094..ddf18797a5cfd94d038e691a23b71216588317ad
100644
--- a/fs/unionfs/copyup.c
+++ b/fs/unionfs/copyup.c
@@ -622,12 +622,10 @@ static struct dentry *create_parents_nam
struct dentry *hidden_dentry = NULL;
const char *childname;
unsigned int childnamelen;
-
int old_kmalloc_size;
int kmalloc_size;
int num_dentry;
int count;
-
int old_bstart;
int old_bend;
struct dentry **path = NULL;
diff --git a/fs/unionfs/dentry.c b/fs/unionfs/dentry.c
index
463cf4cd3d9c484b6711817055518cc578768554..e85bcf4c9a9fc51063c2372f8f65e59cb7606c7e
100644
--- a/fs/unionfs/dentry.c
+++ b/fs/unionfs/dentry.c
@@ -36,7 +36,6 @@ static int __unionfs_d_revalidate_one(st
int positive = 0;
int locked = 0;
int interpose_flag;
-
struct nameidata lowernd; /* TODO: be gentler to the stack */
if (nd)
diff --git a/fs/unionfs/main.c b/fs/unionfs/main.c
index
f1060c53312eb2dee82162283bd2ad1fc3b51465..8288cb9c21b140929768c98fb7fd88797bf419ab
100644
--- a/fs/unionfs/main.c
+++ b/fs/unionfs/main.c
@@ -251,6 +251,7 @@ int __parse_branch_mode(const char *name
int parse_branch_mode(const char *name)
{
int perms = __parse_branch_mode(name);
+
if (perms == 0)
perms = MAY_READ | MAY_WRITE;
return perms;
@@ -267,7 +268,6 @@ static int parse_dirs_option(struct supe
int bindex = 0;
int i = 0;
int j = 0;
-
struct dentry *dent1;
struct dentry *dent2;
@@ -538,7 +538,6 @@ static int unionfs_read_super(struct sup
int silent)
{
int err = 0;
-
struct unionfs_dentry_info *hidden_root_info = NULL;
struct odf_sb_info *odf;
int bindex, bstart, bend;
@@ -776,6 +775,7 @@ static struct file_system_type unionfs_f
static int __init init_unionfs_fs(void)
{
int err;
+
printk("Registering unionfs " UNIONFS_VERSION "\n");
if ((err = unionfs_init_filldir_cache()))
diff --git a/fs/unionfs/super.c b/fs/unionfs/super.c
index
55aa7f0396c0c693b5c5cf93311150d12122d621..de4a8b644039d5e1d58bb85d8200fee4b33a9b60
100644
--- a/fs/unionfs/super.c
+++ b/fs/unionfs/super.c
@@ -214,6 +214,7 @@ static noinline int do_remount_del_optio
int err = -EINVAL;
int idx;
struct nameidata nd;
+
/* optarg contains the branch name to delete */
/*
diff --git a/fs/unionfs/union.h b/fs/unionfs/union.h
index
84fc8d0143c0d26b8b64afd08ca72f0cd329b1af..e3ff9c960393ea6918a66df90d9b235da7b877ec
100644
--- a/fs/unionfs/union.h
+++ b/fs/unionfs/union.h
@@ -240,6 +240,7 @@ #define MAXRDCOOKIE (0xfff)
static inline off_t rdstate2offset(struct unionfs_dir_state *buf)
{
off_t tmp;
+
tmp = ((buf->cookie & MAXRDCOOKIE) << RDOFFBITS)
| (buf->offset & DIREOF);
return tmp;
@@ -385,6 +386,7 @@ static inline int set_branchperms(struct
static inline int is_robranch_super(const struct super_block *sb, int index)
{
int ret;
+
unionfs_read_lock(sb);
ret = (!(branchperms(sb, index) & MAY_WRITE)) ? -EROFS : 0;
unionfs_read_unlock(sb);
@@ -462,6 +464,7 @@ static inline struct vfsmount *unionfs_m
int bindex)
{
struct vfsmount *mnt;
+
if (!dentry) {
if (bindex < 0)
return NULL;
@@ -480,6 +483,7 @@ static inline struct vfsmount *unionfs_m
static inline void unionfs_mntput(struct dentry *dentry, int bindex)
{
struct vfsmount *mnt;
+
if (!dentry) {
if (bindex < 0)
return;
_______________________________________________
unionfs-cvs mailing list: http://unionfs.filesystems.org/
[email protected]
http://www.fsl.cs.sunysb.edu/mailman/listinfo/unionfs-cvs