summaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorzhong jiang <zhongjiang@huawei.com>2019-11-30 17:57:35 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2019-12-01 12:59:09 -0800
commit35e3d566df5ff86d19488d2cd9b49b2d9389780e (patch)
tree957d40a05af6f296536207135d9258062cac7420 /mm
parenta818f5363a0eba04bcff986c64c919d3f44b8017 (diff)
downloadlinux-35e3d566df5ff86d19488d2cd9b49b2d9389780e.tar.gz
linux-35e3d566df5ff86d19488d2cd9b49b2d9389780e.tar.bz2
linux-35e3d566df5ff86d19488d2cd9b49b2d9389780e.zip
mm/hwpoison-inject: use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs fops
It is more clear to use DEFINE_DEBUGFS_ATTRIBUTE to define debugfs file operation rather than DEFINE_SIMPLE_ATTRIBUTE. Link: http://lkml.kernel.org/r/1572403660-44718-1-git-send-email-zhongjiang@huawei.com Signed-off-by: zhong jiang <zhongjiang@huawei.com> Acked-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r--mm/hwpoison-inject.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mm/hwpoison-inject.c b/mm/hwpoison-inject.c
index 5b7430bd83a6..e488876b168a 100644
--- a/mm/hwpoison-inject.c
+++ b/mm/hwpoison-inject.c
@@ -67,8 +67,8 @@ static int hwpoison_unpoison(void *data, u64 val)
return unpoison_memory(val);
}
-DEFINE_SIMPLE_ATTRIBUTE(hwpoison_fops, NULL, hwpoison_inject, "%lli\n");
-DEFINE_SIMPLE_ATTRIBUTE(unpoison_fops, NULL, hwpoison_unpoison, "%lli\n");
+DEFINE_DEBUGFS_ATTRIBUTE(hwpoison_fops, NULL, hwpoison_inject, "%lli\n");
+DEFINE_DEBUGFS_ATTRIBUTE(unpoison_fops, NULL, hwpoison_unpoison, "%lli\n");
static void pfn_inject_exit(void)
{