projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1c72871
)
x86/xen: Convert to DEFINE_SHOW_ATTRIBUTE
author
Qinglang Miao
<miaoqinglang@huawei.com>
Thu, 17 Sep 2020 12:55:47 +0000
(20:55 +0800)
committer
Juergen Gross
<jgross@suse.com>
Wed, 16 Dec 2020 06:53:53 +0000
(07:53 +0100)
Use DEFINE_SHOW_ATTRIBUTE macro to simplify the code.
Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
Link:
https://lore.kernel.org/r/20200917125547.104472-1-miaoqinglang@huawei.com
Signed-off-by: Juergen Gross <jgross@suse.com>
arch/x86/xen/p2m.c
patch
|
blob
|
history
diff --git
a/arch/x86/xen/p2m.c
b/arch/x86/xen/p2m.c
index be4151f42611f71bb1724b62f3ec9046848971bc..3301875dd1965da1c9de6312c9ff7bdf91e0502c 100644
(file)
--- a/
arch/x86/xen/p2m.c
+++ b/
arch/x86/xen/p2m.c
@@
-795,17
+795,7
@@
static int p2m_dump_show(struct seq_file *m, void *v)
return 0;
}
-static int p2m_dump_open(struct inode *inode, struct file *filp)
-{
- return single_open(filp, p2m_dump_show, NULL);
-}
-
-static const struct file_operations p2m_dump_fops = {
- .open = p2m_dump_open,
- .read = seq_read,
- .llseek = seq_lseek,
- .release = single_release,
-};
+DEFINE_SHOW_ATTRIBUTE(p2m_dump);
static struct dentry *d_mmu_debug;