staging/lustre/llite: Fix Multiple Assignments
authorNathaniel Clark <nathaniel.l.clark@intel.com>
Fri, 10 Jun 2016 02:35:14 +0000 (22:35 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 18 Jun 2016 03:32:34 +0000 (20:32 -0700)
Fix all multiple assignments on lustre/llite directory.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/llite/llite_lib.c
drivers/staging/lustre/lustre/llite/namei.c
drivers/staging/lustre/lustre/llite/vvp_io.c

index 96c7e9fc6e5f7bdf4c2e6a7bce7461fa815c3d4a..b260f60e87cf27ace2a7ab2cacc1aaebac20f02f 100644 (file)
@@ -864,7 +864,8 @@ int ll_fill_super(struct super_block *sb, struct vfsmount *mnt)
        try_module_get(THIS_MODULE);
 
        /* client additional sb info */
-       lsi->lsi_llsbi = sbi = ll_init_sbi(sb);
+       sbi = ll_init_sbi(sb);
+       lsi->lsi_llsbi = sbi;
        if (!sbi) {
                module_put(THIS_MODULE);
                kfree(cfg);
index 5eba0ebae10f1be9cbe2ddddf29caaa4297666ce..95643bc6cc976c2d7301ab8cfd642dbe251da084 100644 (file)
@@ -318,7 +318,8 @@ static struct dentry *ll_find_alias(struct inode *inode, struct dentry *dentry)
        if (hlist_empty(&inode->i_dentry))
                return NULL;
 
-       discon_alias = invalid_alias = NULL;
+       discon_alias = NULL;
+       invalid_alias = NULL;
 
        ll_lock_dcache(inode);
        hlist_for_each_entry(alias, &inode->i_dentry, d_u.d_alias) {
index e26e0f8e69a26d66ebe1a442d5381bde20db649c..763d3361d46e9ad6b00084b42d99f3d69a7b06b6 100644 (file)
@@ -954,7 +954,8 @@ static int vvp_io_write_start(const struct lu_env *env,
                 * out-of-order writes.
                 */
                ll_merge_attr(env, inode);
-               pos = io->u.ci_wr.wr.crw_pos = i_size_read(inode);
+               pos = i_size_read(inode);
+               io->u.ci_wr.wr.crw_pos = pos;
                vio->vui_iocb->ki_pos = pos;
        } else {
                LASSERT(vio->vui_iocb->ki_pos == pos);