HWPOISON: add fs/device filters
[linux-2.6.git] / mm / hwpoison-inject.c
index 6e35e56..ac692a9 100644 (file)
@@ -3,6 +3,7 @@
 #include <linux/debugfs.h>
 #include <linux/kernel.h>
 #include <linux/mm.h>
+#include "internal.h"
 
 static struct dentry *hwpoison_dir;
 
@@ -54,6 +55,16 @@ static int pfn_inject_init(void)
        if (!dentry)
                goto fail;
 
+       dentry = debugfs_create_u32("corrupt-filter-dev-major", 0600,
+                                   hwpoison_dir, &hwpoison_filter_dev_major);
+       if (!dentry)
+               goto fail;
+
+       dentry = debugfs_create_u32("corrupt-filter-dev-minor", 0600,
+                                   hwpoison_dir, &hwpoison_filter_dev_minor);
+       if (!dentry)
+               goto fail;
+
        return 0;
 fail:
        pfn_inject_exit();