aboutsummaryrefslogtreecommitdiffstats
path: root/fs/gfs2/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/gfs2/main.c')
-rw-r--r--fs/gfs2/main.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/fs/gfs2/main.c b/fs/gfs2/main.c
index 3eea03c78534..e3f6f1844a21 100644
--- a/fs/gfs2/main.c
+++ b/fs/gfs2/main.c
@@ -93,6 +93,12 @@ static int __init init_gfs2_fs(void)
93 if (!gfs2_rgrpd_cachep) 93 if (!gfs2_rgrpd_cachep)
94 goto fail; 94 goto fail;
95 95
96 gfs2_quotad_cachep = kmem_cache_create("gfs2_quotad",
97 sizeof(struct gfs2_quota_data),
98 0, 0, NULL);
99 if (!gfs2_quotad_cachep)
100 goto fail;
101
96 error = register_filesystem(&gfs2_fs_type); 102 error = register_filesystem(&gfs2_fs_type);
97 if (error) 103 if (error)
98 goto fail; 104 goto fail;
@@ -112,6 +118,9 @@ fail_unregister:
112fail: 118fail:
113 gfs2_glock_exit(); 119 gfs2_glock_exit();
114 120
121 if (gfs2_quotad_cachep)
122 kmem_cache_destroy(gfs2_quotad_cachep);
123
115 if (gfs2_rgrpd_cachep) 124 if (gfs2_rgrpd_cachep)
116 kmem_cache_destroy(gfs2_rgrpd_cachep); 125 kmem_cache_destroy(gfs2_rgrpd_cachep);
117 126
@@ -140,6 +149,7 @@ static void __exit exit_gfs2_fs(void)
140 unregister_filesystem(&gfs2_fs_type); 149 unregister_filesystem(&gfs2_fs_type);
141 unregister_filesystem(&gfs2meta_fs_type); 150 unregister_filesystem(&gfs2meta_fs_type);
142 151
152 kmem_cache_destroy(gfs2_quotad_cachep);
143 kmem_cache_destroy(gfs2_rgrpd_cachep); 153 kmem_cache_destroy(gfs2_rgrpd_cachep);
144 kmem_cache_destroy(gfs2_bufdata_cachep); 154 kmem_cache_destroy(gfs2_bufdata_cachep);
145 kmem_cache_destroy(gfs2_inode_cachep); 155 kmem_cache_destroy(gfs2_inode_cachep);