Merge branch 'work.mount0' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
[linux-2.6-microblaze.git] / mm / zsmalloc.c
index 910d040..57fbb7c 100644 (file)
@@ -576,8 +576,6 @@ static void __init zs_stat_init(void)
        }
 
        zs_stat_root = debugfs_create_dir("zsmalloc", NULL);
-       if (!zs_stat_root)
-               pr_warn("debugfs 'zsmalloc' stat dir creation failed\n");
 }
 
 static void __exit zs_stat_exit(void)
@@ -648,29 +646,15 @@ DEFINE_SHOW_ATTRIBUTE(zs_stats_size);
 
 static void zs_pool_stat_create(struct zs_pool *pool, const char *name)
 {
-       struct dentry *entry;
-
        if (!zs_stat_root) {
                pr_warn("no root stat dir, not creating <%s> stat dir\n", name);
                return;
        }
 
-       entry = debugfs_create_dir(name, zs_stat_root);
-       if (!entry) {
-               pr_warn("debugfs dir <%s> creation failed\n", name);
-               return;
-       }
-       pool->stat_dentry = entry;
-
-       entry = debugfs_create_file("classes", S_IFREG | 0444,
-                                   pool->stat_dentry, pool,
-                                   &zs_stats_size_fops);
-       if (!entry) {
-               pr_warn("%s: debugfs file entry <%s> creation failed\n",
-                               name, "classes");
-               debugfs_remove_recursive(pool->stat_dentry);
-               pool->stat_dentry = NULL;
-       }
+       pool->stat_dentry = debugfs_create_dir(name, zs_stat_root);
+
+       debugfs_create_file("classes", S_IFREG | 0444, pool->stat_dentry, pool,
+                           &zs_stats_size_fops);
 }
 
 static void zs_pool_stat_destroy(struct zs_pool *pool)