summaryrefslogtreecommitdiff
path: root/fs/aufs/sbinfo.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/aufs/sbinfo.c')
-rw-r--r--fs/aufs/sbinfo.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/fs/aufs/sbinfo.c b/fs/aufs/sbinfo.c
index aa970593a..25f60549c 100644
--- a/fs/aufs/sbinfo.c
+++ b/fs/aufs/sbinfo.c
@@ -20,7 +20,7 @@ void au_si_free(struct kobject *kobj)
sbinfo = container_of(kobj, struct au_sbinfo, si_kobj);
for (i = 0; i < AuPlink_NHASH; i++)
AuDebugOn(!hlist_empty(&sbinfo->si_plink[i].head));
- au_nwt_fin(&sbinfo->si_nowait);
+ AuDebugOn(atomic_read(&sbinfo->si_nowait.nw_len));
AuDebugOn(percpu_counter_sum(&sbinfo->si_ninodes));
percpu_counter_destroy(&sbinfo->si_ninodes);
@@ -31,14 +31,15 @@ void au_si_free(struct kobject *kobj)
au_br_free(sbinfo);
au_rw_write_unlock(&sbinfo->si_rwsem);
- kfree(sbinfo->si_branch);
+ au_delayed_kfree(sbinfo->si_branch);
for (i = 0; i < AU_NPIDMAP; i++)
- kfree(sbinfo->au_si_pid.pid_bitmap[i]);
+ if (sbinfo->au_si_pid.pid_bitmap[i])
+ au_delayed_kfree(sbinfo->au_si_pid.pid_bitmap[i]);
mutex_destroy(&sbinfo->au_si_pid.pid_mtx);
mutex_destroy(&sbinfo->si_xib_mtx);
AuRwDestroy(&sbinfo->si_rwsem);
- kfree(sbinfo);
+ au_delayed_kfree(sbinfo);
}
int au_si_alloc(struct super_block *sb)
@@ -110,9 +111,9 @@ int au_si_alloc(struct super_block *sb)
return 0; /* success */
out_br:
- kfree(sbinfo->si_branch);
+ au_delayed_kfree(sbinfo->si_branch);
out_sbinfo:
- kfree(sbinfo);
+ au_delayed_kfree(sbinfo);
out:
return err;
}