[GFS2] Align all labels against LH side
This makes everything consistent. Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
This commit is contained in:
@@ -67,7 +67,6 @@ int gfs2_acl_validate_set(struct gfs2_inode *ip, int access,
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
posix_acl_release(acl);
|
posix_acl_release(acl);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -139,11 +138,9 @@ static int acl_get(struct gfs2_inode *ip, int access, struct posix_acl **acl,
|
|||||||
*data = er.er_data;
|
*data = er.er_data;
|
||||||
*len = er.er_data_len;
|
*len = er.er_data_len;
|
||||||
}
|
}
|
||||||
|
|
||||||
out:
|
out:
|
||||||
if (error || el == &el_this)
|
if (error || el == &el_this)
|
||||||
brelse(el->el_bh);
|
brelse(el->el_bh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -307,7 +304,6 @@ int gfs2_acl_chmod(struct gfs2_inode *ip, struct iattr *attr)
|
|||||||
posix_acl_release(acl);
|
posix_acl_release(acl);
|
||||||
brelse(el.el_bh);
|
brelse(el.el_bh);
|
||||||
kfree(data);
|
kfree(data);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -172,10 +172,8 @@ int gfs2_unstuff_dinode(struct gfs2_inode *ip, struct page *page)
|
|||||||
|
|
||||||
out_brelse:
|
out_brelse:
|
||||||
brelse(dibh);
|
brelse(dibh);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
up_write(&ip->i_rw_mutex);
|
up_write(&ip->i_rw_mutex);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -644,7 +642,6 @@ static int recursive_scan(struct gfs2_inode *ip, struct buffer_head *dibh,
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
brelse(bh);
|
brelse(bh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -790,13 +787,10 @@ static int do_strip(struct gfs2_inode *ip, struct buffer_head *dibh,
|
|||||||
|
|
||||||
out_rg_gunlock:
|
out_rg_gunlock:
|
||||||
gfs2_glock_dq_m(rlist.rl_rgrps, rlist.rl_ghs);
|
gfs2_glock_dq_m(rlist.rl_rgrps, rlist.rl_ghs);
|
||||||
|
|
||||||
out_rlist:
|
out_rlist:
|
||||||
gfs2_rlist_free(&rlist);
|
gfs2_rlist_free(&rlist);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_glock_dq_uninit(&ip->i_alloc.al_ri_gh);
|
gfs2_glock_dq_uninit(&ip->i_alloc.al_ri_gh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -870,16 +864,12 @@ static int do_grow(struct gfs2_inode *ip, uint64_t size)
|
|||||||
|
|
||||||
out_end_trans:
|
out_end_trans:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
out_ipres:
|
out_ipres:
|
||||||
gfs2_inplace_release(ip);
|
gfs2_inplace_release(ip);
|
||||||
|
|
||||||
out_gunlock_q:
|
out_gunlock_q:
|
||||||
gfs2_quota_unlock(ip);
|
gfs2_quota_unlock(ip);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_alloc_put(ip);
|
gfs2_alloc_put(ip);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1000,7 +990,6 @@ static int trunc_start(struct gfs2_inode *ip, uint64_t size)
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1072,9 +1061,7 @@ static int trunc_end(struct gfs2_inode *ip)
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
up_write(&ip->i_rw_mutex);
|
up_write(&ip->i_rw_mutex);
|
||||||
|
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -1136,7 +1136,6 @@ static int dir_double_exhash(struct gfs2_inode *dip)
|
|||||||
|
|
||||||
fail:
|
fail:
|
||||||
kfree(buf);
|
kfree(buf);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1892,21 +1891,16 @@ static int leaf_dealloc(struct gfs2_inode *dip, uint32_t index, uint32_t len,
|
|||||||
|
|
||||||
out_end_trans:
|
out_end_trans:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
out_rg_gunlock:
|
out_rg_gunlock:
|
||||||
gfs2_glock_dq_m(rlist.rl_rgrps, rlist.rl_ghs);
|
gfs2_glock_dq_m(rlist.rl_rgrps, rlist.rl_ghs);
|
||||||
|
|
||||||
out_rlist:
|
out_rlist:
|
||||||
gfs2_rlist_free(&rlist);
|
gfs2_rlist_free(&rlist);
|
||||||
gfs2_glock_dq_uninit(&dip->i_alloc.al_ri_gh);
|
gfs2_glock_dq_uninit(&dip->i_alloc.al_ri_gh);
|
||||||
|
|
||||||
out_qs:
|
out_qs:
|
||||||
gfs2_quota_unhold(dip);
|
gfs2_quota_unhold(dip);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_alloc_put(dip);
|
gfs2_alloc_put(dip);
|
||||||
kfree(ht);
|
kfree(ht);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -154,7 +154,6 @@ static int ea_foreach(struct gfs2_inode *ip, ea_call_t ea_call, void *data)
|
|||||||
}
|
}
|
||||||
out:
|
out:
|
||||||
brelse(bh);
|
brelse(bh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -321,7 +320,6 @@ static int ea_dealloc_unstuffed(struct gfs2_inode *ip, struct buffer_head *bh,
|
|||||||
|
|
||||||
out_gunlock:
|
out_gunlock:
|
||||||
gfs2_glock_dq_uninit(&rg_gh);
|
gfs2_glock_dq_uninit(&rg_gh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -350,10 +348,8 @@ static int ea_remove_unstuffed(struct gfs2_inode *ip, struct buffer_head *bh,
|
|||||||
|
|
||||||
out_quota:
|
out_quota:
|
||||||
gfs2_quota_unhold(ip);
|
gfs2_quota_unhold(ip);
|
||||||
|
|
||||||
out_alloc:
|
out_alloc:
|
||||||
gfs2_alloc_put(ip);
|
gfs2_alloc_put(ip);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -508,7 +504,6 @@ static int ea_get_unstuffed(struct gfs2_inode *ip, struct gfs2_ea_header *ea,
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
kfree(bh);
|
kfree(bh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -749,16 +744,12 @@ static int ea_alloc_skeleton(struct gfs2_inode *ip, struct gfs2_ea_request *er,
|
|||||||
|
|
||||||
out_end_trans:
|
out_end_trans:
|
||||||
gfs2_trans_end(GFS2_SB(&ip->i_inode));
|
gfs2_trans_end(GFS2_SB(&ip->i_inode));
|
||||||
|
|
||||||
out_ipres:
|
out_ipres:
|
||||||
gfs2_inplace_release(ip);
|
gfs2_inplace_release(ip);
|
||||||
|
|
||||||
out_gunlock_q:
|
out_gunlock_q:
|
||||||
gfs2_quota_unlock(ip);
|
gfs2_quota_unlock(ip);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_alloc_put(ip);
|
gfs2_alloc_put(ip);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -886,7 +877,6 @@ static int ea_set_simple_noalloc(struct gfs2_inode *ip, struct buffer_head *bh,
|
|||||||
brelse(dibh);
|
brelse(dibh);
|
||||||
out:
|
out:
|
||||||
gfs2_trans_end(GFS2_SB(&ip->i_inode));
|
gfs2_trans_end(GFS2_SB(&ip->i_inode));
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1027,7 +1017,6 @@ static int ea_set_block(struct gfs2_inode *ip, struct gfs2_ea_request *er,
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
brelse(indbh);
|
brelse(indbh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1287,13 +1276,11 @@ static int ea_acl_chmod_unstuffed(struct gfs2_inode *ip,
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
kfree(bh);
|
kfree(bh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
kfree(bh);
|
kfree(bh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1444,13 +1431,10 @@ static int ea_dealloc_indirect(struct gfs2_inode *ip)
|
|||||||
|
|
||||||
out_gunlock:
|
out_gunlock:
|
||||||
gfs2_glock_dq_m(rlist.rl_rgrps, rlist.rl_ghs);
|
gfs2_glock_dq_m(rlist.rl_rgrps, rlist.rl_ghs);
|
||||||
|
|
||||||
out_rlist_free:
|
out_rlist_free:
|
||||||
gfs2_rlist_free(&rlist);
|
gfs2_rlist_free(&rlist);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
brelse(indbh);
|
brelse(indbh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1496,7 +1480,6 @@ static int ea_dealloc_block(struct gfs2_inode *ip)
|
|||||||
|
|
||||||
out_gunlock:
|
out_gunlock:
|
||||||
gfs2_glock_dq_uninit(&al->al_rgd_gh);
|
gfs2_glock_dq_uninit(&al->al_rgd_gh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1536,13 +1519,10 @@ int gfs2_ea_dealloc(struct gfs2_inode *ip)
|
|||||||
|
|
||||||
out_rindex:
|
out_rindex:
|
||||||
gfs2_glock_dq_uninit(&al->al_ri_gh);
|
gfs2_glock_dq_uninit(&al->al_ri_gh);
|
||||||
|
|
||||||
out_quota:
|
out_quota:
|
||||||
gfs2_quota_unhold(ip);
|
gfs2_quota_unhold(ip);
|
||||||
|
|
||||||
out_alloc:
|
out_alloc:
|
||||||
gfs2_alloc_put(ip);
|
gfs2_alloc_put(ip);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -2181,7 +2181,6 @@ static int dump_glock(struct gfs2_glock *gl)
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
spin_unlock(&gl->gl_spin);
|
spin_unlock(&gl->gl_spin);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -83,14 +83,12 @@ static int gfs2_drevalidate(struct dentry *dentry, struct nameidata *nd)
|
|||||||
|
|
||||||
valid_gunlock:
|
valid_gunlock:
|
||||||
gfs2_glock_dq_uninit(&d_gh);
|
gfs2_glock_dq_uninit(&d_gh);
|
||||||
|
|
||||||
valid:
|
valid:
|
||||||
dput(parent);
|
dput(parent);
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
invalid_gunlock:
|
invalid_gunlock:
|
||||||
gfs2_glock_dq_uninit(&d_gh);
|
gfs2_glock_dq_uninit(&d_gh);
|
||||||
|
|
||||||
invalid:
|
invalid:
|
||||||
if (inode && S_ISDIR(inode->i_mode)) {
|
if (inode && S_ISDIR(inode->i_mode)) {
|
||||||
if (have_submounts(dentry))
|
if (have_submounts(dentry))
|
||||||
@@ -98,13 +96,11 @@ static int gfs2_drevalidate(struct dentry *dentry, struct nameidata *nd)
|
|||||||
shrink_dcache_parent(dentry);
|
shrink_dcache_parent(dentry);
|
||||||
}
|
}
|
||||||
d_drop(dentry);
|
d_drop(dentry);
|
||||||
|
|
||||||
dput(parent);
|
dput(parent);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
fail_gunlock:
|
fail_gunlock:
|
||||||
gfs2_glock_dq_uninit(&d_gh);
|
gfs2_glock_dq_uninit(&d_gh);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
dput(parent);
|
dput(parent);
|
||||||
return 0;
|
return 0;
|
||||||
|
@@ -347,7 +347,6 @@ static int readdir_bad(struct file *file, void *dirent, filldir_t filldir)
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
kfree(fdb);
|
kfree(fdb);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -175,7 +175,6 @@ static int init_names(struct gfs2_sbd *sdp, int silent)
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
kfree(sb);
|
kfree(sb);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -246,22 +245,17 @@ static int init_locking(struct gfs2_sbd *sdp, struct gfs2_holder *mount_gh,
|
|||||||
|
|
||||||
fail_trans:
|
fail_trans:
|
||||||
gfs2_glock_put(sdp->sd_trans_gl);
|
gfs2_glock_put(sdp->sd_trans_gl);
|
||||||
|
|
||||||
fail_rename:
|
fail_rename:
|
||||||
gfs2_glock_put(sdp->sd_rename_gl);
|
gfs2_glock_put(sdp->sd_rename_gl);
|
||||||
|
|
||||||
fail_live:
|
fail_live:
|
||||||
gfs2_glock_dq_uninit(&sdp->sd_live_gh);
|
gfs2_glock_dq_uninit(&sdp->sd_live_gh);
|
||||||
|
|
||||||
fail_mount:
|
fail_mount:
|
||||||
gfs2_glock_dq_uninit(mount_gh);
|
gfs2_glock_dq_uninit(mount_gh);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
while (sdp->sd_glockd_num--)
|
while (sdp->sd_glockd_num--)
|
||||||
kthread_stop(sdp->sd_glockd_process[sdp->sd_glockd_num]);
|
kthread_stop(sdp->sd_glockd_process[sdp->sd_glockd_num]);
|
||||||
|
|
||||||
kthread_stop(sdp->sd_scand_process);
|
kthread_stop(sdp->sd_scand_process);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -453,23 +447,18 @@ static int init_journal(struct gfs2_sbd *sdp, int undo)
|
|||||||
|
|
||||||
fail_recoverd:
|
fail_recoverd:
|
||||||
kthread_stop(sdp->sd_recoverd_process);
|
kthread_stop(sdp->sd_recoverd_process);
|
||||||
|
|
||||||
fail_jinode_gh:
|
fail_jinode_gh:
|
||||||
if (!sdp->sd_args.ar_spectator)
|
if (!sdp->sd_args.ar_spectator)
|
||||||
gfs2_glock_dq_uninit(&sdp->sd_jinode_gh);
|
gfs2_glock_dq_uninit(&sdp->sd_jinode_gh);
|
||||||
|
|
||||||
fail_journal_gh:
|
fail_journal_gh:
|
||||||
if (!sdp->sd_args.ar_spectator)
|
if (!sdp->sd_args.ar_spectator)
|
||||||
gfs2_glock_dq_uninit(&sdp->sd_journal_gh);
|
gfs2_glock_dq_uninit(&sdp->sd_journal_gh);
|
||||||
|
|
||||||
fail_jindex:
|
fail_jindex:
|
||||||
gfs2_jindex_free(sdp);
|
gfs2_jindex_free(sdp);
|
||||||
if (jindex)
|
if (jindex)
|
||||||
gfs2_glock_dq_uninit(&ji_gh);
|
gfs2_glock_dq_uninit(&ji_gh);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
iput(sdp->sd_jindex);
|
iput(sdp->sd_jindex);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -534,14 +523,11 @@ static int init_inodes(struct gfs2_sbd *sdp, int undo)
|
|||||||
|
|
||||||
fail_qinode:
|
fail_qinode:
|
||||||
iput(sdp->sd_quota_inode);
|
iput(sdp->sd_quota_inode);
|
||||||
|
|
||||||
fail_rindex:
|
fail_rindex:
|
||||||
gfs2_clear_rgrpd(sdp);
|
gfs2_clear_rgrpd(sdp);
|
||||||
iput(sdp->sd_rindex);
|
iput(sdp->sd_rindex);
|
||||||
|
|
||||||
fail_statfs:
|
fail_statfs:
|
||||||
iput(sdp->sd_statfs_inode);
|
iput(sdp->sd_statfs_inode);
|
||||||
|
|
||||||
fail_inum:
|
fail_inum:
|
||||||
iput(sdp->sd_inum_inode);
|
iput(sdp->sd_inum_inode);
|
||||||
fail_journal:
|
fail_journal:
|
||||||
@@ -630,24 +616,16 @@ static int init_per_node(struct gfs2_sbd *sdp, int undo)
|
|||||||
|
|
||||||
fail_qc_gh:
|
fail_qc_gh:
|
||||||
gfs2_glock_dq_uninit(&sdp->sd_qc_gh);
|
gfs2_glock_dq_uninit(&sdp->sd_qc_gh);
|
||||||
|
|
||||||
fail_ut_gh:
|
fail_ut_gh:
|
||||||
|
|
||||||
gfs2_glock_dq_uninit(&sdp->sd_sc_gh);
|
gfs2_glock_dq_uninit(&sdp->sd_sc_gh);
|
||||||
|
|
||||||
fail_ir_gh:
|
fail_ir_gh:
|
||||||
gfs2_glock_dq_uninit(&sdp->sd_ir_gh);
|
gfs2_glock_dq_uninit(&sdp->sd_ir_gh);
|
||||||
|
|
||||||
fail_qc_i:
|
fail_qc_i:
|
||||||
iput(sdp->sd_qc_inode);
|
iput(sdp->sd_qc_inode);
|
||||||
|
|
||||||
fail_ut_i:
|
fail_ut_i:
|
||||||
|
|
||||||
iput(sdp->sd_sc_inode);
|
iput(sdp->sd_sc_inode);
|
||||||
|
|
||||||
fail_ir_i:
|
fail_ir_i:
|
||||||
iput(sdp->sd_ir_inode);
|
iput(sdp->sd_ir_inode);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
if (pn)
|
if (pn)
|
||||||
iput(pn);
|
iput(pn);
|
||||||
@@ -783,32 +761,24 @@ static int fill_super(struct super_block *sb, void *data, int silent)
|
|||||||
|
|
||||||
fail_threads:
|
fail_threads:
|
||||||
init_threads(sdp, UNDO);
|
init_threads(sdp, UNDO);
|
||||||
|
|
||||||
fail_per_node:
|
fail_per_node:
|
||||||
init_per_node(sdp, UNDO);
|
init_per_node(sdp, UNDO);
|
||||||
|
|
||||||
fail_inodes:
|
fail_inodes:
|
||||||
init_inodes(sdp, UNDO);
|
init_inodes(sdp, UNDO);
|
||||||
|
|
||||||
fail_sb:
|
fail_sb:
|
||||||
init_sb(sdp, 0, UNDO);
|
init_sb(sdp, 0, UNDO);
|
||||||
|
|
||||||
fail_locking:
|
fail_locking:
|
||||||
init_locking(sdp, &mount_gh, UNDO);
|
init_locking(sdp, &mount_gh, UNDO);
|
||||||
|
|
||||||
fail_lm:
|
fail_lm:
|
||||||
gfs2_gl_hash_clear(sdp, WAIT);
|
gfs2_gl_hash_clear(sdp, WAIT);
|
||||||
gfs2_lm_unmount(sdp);
|
gfs2_lm_unmount(sdp);
|
||||||
while (invalidate_inodes(sb))
|
while (invalidate_inodes(sb))
|
||||||
yield();
|
yield();
|
||||||
|
|
||||||
fail_sys:
|
fail_sys:
|
||||||
gfs2_sys_fs_del(sdp);
|
gfs2_sys_fs_del(sdp);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
vfree(sdp);
|
vfree(sdp);
|
||||||
sb->s_fs_info = NULL;
|
sb->s_fs_info = NULL;
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -852,6 +822,7 @@ static int fill_super_meta(struct super_block *sb, struct super_block *new,
|
|||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int set_bdev_super(struct super_block *s, void *data)
|
static int set_bdev_super(struct super_block *s, void *data)
|
||||||
{
|
{
|
||||||
s->s_bdev = data;
|
s->s_bdev = data;
|
||||||
|
@@ -228,32 +228,25 @@ static int gfs2_link(struct dentry *old_dentry, struct inode *dir,
|
|||||||
|
|
||||||
out_end_trans:
|
out_end_trans:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
out_ipres:
|
out_ipres:
|
||||||
if (alloc_required)
|
if (alloc_required)
|
||||||
gfs2_inplace_release(dip);
|
gfs2_inplace_release(dip);
|
||||||
|
|
||||||
out_gunlock_q:
|
out_gunlock_q:
|
||||||
if (alloc_required)
|
if (alloc_required)
|
||||||
gfs2_quota_unlock(dip);
|
gfs2_quota_unlock(dip);
|
||||||
|
|
||||||
out_alloc:
|
out_alloc:
|
||||||
if (alloc_required)
|
if (alloc_required)
|
||||||
gfs2_alloc_put(dip);
|
gfs2_alloc_put(dip);
|
||||||
|
|
||||||
out_gunlock:
|
out_gunlock:
|
||||||
gfs2_glock_dq_m(2, ghs);
|
gfs2_glock_dq_m(2, ghs);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_holder_uninit(ghs);
|
gfs2_holder_uninit(ghs);
|
||||||
gfs2_holder_uninit(ghs + 1);
|
gfs2_holder_uninit(ghs + 1);
|
||||||
|
|
||||||
if (!error) {
|
if (!error) {
|
||||||
atomic_inc(&inode->i_count);
|
atomic_inc(&inode->i_count);
|
||||||
d_instantiate(dentry, inode);
|
d_instantiate(dentry, inode);
|
||||||
mark_inode_dirty(inode);
|
mark_inode_dirty(inode);
|
||||||
}
|
}
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -493,11 +486,9 @@ static int gfs2_rmdir(struct inode *dir, struct dentry *dentry)
|
|||||||
|
|
||||||
out_gunlock:
|
out_gunlock:
|
||||||
gfs2_glock_dq_m(2, ghs);
|
gfs2_glock_dq_m(2, ghs);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_holder_uninit(ghs);
|
gfs2_holder_uninit(ghs);
|
||||||
gfs2_holder_uninit(ghs + 1);
|
gfs2_holder_uninit(ghs + 1);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -968,13 +959,10 @@ static int setattr_chown(struct inode *inode, struct iattr *attr)
|
|||||||
|
|
||||||
out_end_trans:
|
out_end_trans:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
out_gunlock_q:
|
out_gunlock_q:
|
||||||
gfs2_quota_unlock(ip);
|
gfs2_quota_unlock(ip);
|
||||||
|
|
||||||
out_alloc:
|
out_alloc:
|
||||||
gfs2_alloc_put(ip);
|
gfs2_alloc_put(ip);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1019,10 +1007,8 @@ static int gfs2_setattr(struct dentry *dentry, struct iattr *attr)
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_glock_dq_uninit(&i_gh);
|
gfs2_glock_dq_uninit(&i_gh);
|
||||||
|
|
||||||
if (!error)
|
if (!error)
|
||||||
mark_inode_dirty(inode);
|
mark_inode_dirty(inode);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -117,16 +117,12 @@ static int alloc_page_backing(struct gfs2_inode *ip, struct page *page)
|
|||||||
|
|
||||||
out_trans:
|
out_trans:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
out_ipres:
|
out_ipres:
|
||||||
gfs2_inplace_release(ip);
|
gfs2_inplace_release(ip);
|
||||||
|
|
||||||
out_gunlock_q:
|
out_gunlock_q:
|
||||||
gfs2_quota_unlock(ip);
|
gfs2_quota_unlock(ip);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_alloc_put(ip);
|
gfs2_alloc_put(ip);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -285,7 +285,6 @@ static int bh_get(struct gfs2_quota_data *qd)
|
|||||||
|
|
||||||
fail_brelse:
|
fail_brelse:
|
||||||
brelse(bh);
|
brelse(bh);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
qd->qd_bh_count--;
|
qd->qd_bh_count--;
|
||||||
mutex_unlock(&sdp->sd_quota_mutex);
|
mutex_unlock(&sdp->sd_quota_mutex);
|
||||||
@@ -427,7 +426,6 @@ static int qdsb_get(struct gfs2_sbd *sdp, int user, uint32_t id, int create,
|
|||||||
|
|
||||||
fail_slot:
|
fail_slot:
|
||||||
slot_put(*qdp);
|
slot_put(*qdp);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
qd_put(*qdp);
|
qd_put(*qdp);
|
||||||
return error;
|
return error;
|
||||||
@@ -485,7 +483,6 @@ int gfs2_quota_hold(struct gfs2_inode *ip, uint32_t uid, uint32_t gid)
|
|||||||
out:
|
out:
|
||||||
if (error)
|
if (error)
|
||||||
gfs2_quota_unhold(ip);
|
gfs2_quota_unhold(ip);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -730,24 +727,19 @@ static int do_sync(unsigned int num_qd, struct gfs2_quota_data **qda)
|
|||||||
|
|
||||||
out_end_trans:
|
out_end_trans:
|
||||||
gfs2_trans_end(sdp);
|
gfs2_trans_end(sdp);
|
||||||
|
|
||||||
out_ipres:
|
out_ipres:
|
||||||
if (nalloc)
|
if (nalloc)
|
||||||
gfs2_inplace_release(ip);
|
gfs2_inplace_release(ip);
|
||||||
|
|
||||||
out_alloc:
|
out_alloc:
|
||||||
if (nalloc)
|
if (nalloc)
|
||||||
gfs2_alloc_put(ip);
|
gfs2_alloc_put(ip);
|
||||||
|
|
||||||
out_gunlock:
|
out_gunlock:
|
||||||
gfs2_glock_dq_uninit(&i_gh);
|
gfs2_glock_dq_uninit(&i_gh);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
while (qx--)
|
while (qx--)
|
||||||
gfs2_glock_dq_uninit(&ghs[qx]);
|
gfs2_glock_dq_uninit(&ghs[qx]);
|
||||||
kfree(ghs);
|
kfree(ghs);
|
||||||
gfs2_log_flush(ip->i_gl->gl_sbd, ip->i_gl);
|
gfs2_log_flush(ip->i_gl->gl_sbd, ip->i_gl);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -814,10 +806,8 @@ static int do_glock(struct gfs2_quota_data *qd, int force_refresh,
|
|||||||
|
|
||||||
fail_gunlock:
|
fail_gunlock:
|
||||||
gfs2_glock_dq_uninit(&i_gh);
|
gfs2_glock_dq_uninit(&i_gh);
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
gfs2_glock_dq_uninit(q_gh);
|
gfs2_glock_dq_uninit(q_gh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1100,7 +1090,6 @@ int gfs2_quota_read(struct gfs2_sbd *sdp, int user, uint32_t id,
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
qd_put(qd);
|
qd_put(qd);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
#endif /* 0 */
|
#endif /* 0 */
|
||||||
|
@@ -535,7 +535,7 @@ int gfs2_make_fs_rw(struct gfs2_sbd *sdp)
|
|||||||
|
|
||||||
error = gfs2_quota_init(sdp);
|
error = gfs2_quota_init(sdp);
|
||||||
if (error)
|
if (error)
|
||||||
goto fail_unlinked;
|
goto fail;
|
||||||
|
|
||||||
set_bit(SDF_JOURNAL_LIVE, &sdp->sd_flags);
|
set_bit(SDF_JOURNAL_LIVE, &sdp->sd_flags);
|
||||||
|
|
||||||
@@ -543,8 +543,6 @@ int gfs2_make_fs_rw(struct gfs2_sbd *sdp)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
fail_unlinked:
|
|
||||||
|
|
||||||
fail:
|
fail:
|
||||||
t_gh.gh_flags |= GL_NOCACHE;
|
t_gh.gh_flags |= GL_NOCACHE;
|
||||||
gfs2_glock_dq_uninit(&t_gh);
|
gfs2_glock_dq_uninit(&t_gh);
|
||||||
@@ -627,10 +625,8 @@ int gfs2_statfs_init(struct gfs2_sbd *sdp)
|
|||||||
|
|
||||||
out_m_bh:
|
out_m_bh:
|
||||||
brelse(m_bh);
|
brelse(m_bh);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_glock_dq_uninit(&gh);
|
gfs2_glock_dq_uninit(&gh);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -717,13 +713,10 @@ int gfs2_statfs_sync(struct gfs2_sbd *sdp)
|
|||||||
|
|
||||||
out_bh2:
|
out_bh2:
|
||||||
brelse(l_bh);
|
brelse(l_bh);
|
||||||
|
|
||||||
out_bh:
|
out_bh:
|
||||||
brelse(m_bh);
|
brelse(m_bh);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
gfs2_glock_dq_uninit(&gh);
|
gfs2_glock_dq_uninit(&gh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -855,7 +848,6 @@ int gfs2_statfs_slow(struct gfs2_sbd *sdp, struct gfs2_statfs_change *sc)
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
kfree(gha);
|
kfree(gha);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -932,7 +924,6 @@ static int gfs2_lock_fs_check_clean(struct gfs2_sbd *sdp,
|
|||||||
kfree(lfcc);
|
kfree(lfcc);
|
||||||
}
|
}
|
||||||
gfs2_glock_dq_uninit(&ji_gh);
|
gfs2_glock_dq_uninit(&ji_gh);
|
||||||
|
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user