diff options
author | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2016-06-27 21:01:09 -0300 |
---|---|---|
committer | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2016-06-27 21:01:09 -0300 |
commit | b907a8622e39eecfc4b243f3be3ad26559d1faee (patch) | |
tree | b99ead386fccde5ea8252b5b5ebff8ffd83cd03d /fs/aufs/branch.c | |
parent | 68f052d01b53b858897d80beb0095920abe5868e (diff) |
Linux-libre 4.6.3-gnupck-4.6.3-gnu
Diffstat (limited to 'fs/aufs/branch.c')
-rw-r--r-- | fs/aufs/branch.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/fs/aufs/branch.c b/fs/aufs/branch.c index 5259d30d1..07c842d14 100644 --- a/fs/aufs/branch.c +++ b/fs/aufs/branch.c @@ -300,7 +300,7 @@ static int au_br_init_wh(struct super_block *sb, struct au_branch *br, bindex = au_br_index(sb, br->br_id); if (0 <= bindex) { hdir = au_hi(d_inode(sb->s_root), bindex); - au_hn_imtx_lock_nested(hdir, AuLsc_I_PARENT); + au_hn_inode_lock_nested(hdir, AuLsc_I_PARENT); } else { h_dentry = au_br_dentry(br); h_inode = d_inode(h_dentry); @@ -314,7 +314,7 @@ static int au_br_init_wh(struct super_block *sb, struct au_branch *br, wbr_wh_write_unlock(wbr); } if (hdir) - au_hn_imtx_unlock(hdir); + au_hn_inode_unlock(hdir); else inode_unlock(h_inode); vfsub_mnt_drop_write(au_br_mnt(br)); @@ -425,7 +425,7 @@ static void au_br_do_add_hdp(struct au_dinfo *dinfo, aufs_bindex_t bindex, AuRwMustWriteLock(&dinfo->di_rwsem); - hdp = dinfo->di_hdentry + bindex; + hdp = au_hdentry(dinfo, bindex); memmove(hdp + 1, hdp, sizeof(*hdp) * amount); au_h_dentry_init(hdp); dinfo->di_bbot++; @@ -900,14 +900,13 @@ static void au_br_do_del_hdp(struct au_dinfo *dinfo, const aufs_bindex_t bindex, AuRwMustWriteLock(&dinfo->di_rwsem); - hdp = dinfo->di_hdentry; + hdp = au_hdentry(dinfo, bindex); if (bindex < bbot) - memmove(hdp + bindex, hdp + bindex + 1, - sizeof(*hdp) * (bbot - bindex)); - hdp[0 + bbot].hd_dentry = NULL; + memmove(hdp, hdp + 1, sizeof(*hdp) * (bbot - bindex)); + /* au_h_dentry_init(au_hdentry(dinfo, bbot); */ dinfo->di_bbot--; - p = krealloc(hdp, sizeof(*p) * bbot, AuGFP_SBILIST); + p = krealloc(dinfo->di_hdentry, sizeof(*p) * bbot, AuGFP_SBILIST); if (p) dinfo->di_hdentry = p; /* harmless error */ @@ -1115,7 +1114,7 @@ static int au_ibusy(struct super_block *sb, struct aufs_ibusy __user *arg) inode = ilookup(sb, ibusy.ino); if (!inode || inode->i_ino == AUFS_ROOT_INO - || is_bad_inode(inode)) + || au_is_bad_inode(inode)) goto out_unlock; ii_read_lock_child(inode); |