[PATCH] mm/gup_benchmark: mark gup_benchmark_init as __init function

From: Barry Song
Date: Tue Nov 03 2020 - 03:14:30 EST


gup_benchmark_init() is only called during initialization, mark it as
__init to save some memory.

Cc: John Hubbard <jhubbard@xxxxxxxxxx>
Cc: Jan Kara <jack@xxxxxxx>
Cc: Jérôme Glisse <jglisse@xxxxxxxxxx>
Cc: "Matthew Wilcox (Oracle)" <willy@xxxxxxxxxxxxx>
Cc: Al Viro <viro@xxxxxxxxxxxxxxxxxx>
Cc: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Cc: Dan Williams <dan.j.williams@xxxxxxxxx>
Cc: Dave Chinner <david@xxxxxxxxxxxxx>
Cc: Jason Gunthorpe <jgg@xxxxxxxx>
Cc: Jonathan Corbet <corbet@xxxxxxx>
Cc: Michal Hocko <mhocko@xxxxxxxx>
Cc: Mike Kravetz <mike.kravetz@xxxxxxxxxx>
Cc: Shuah Khan <shuah@xxxxxxxxxx>
Cc: Vlastimil Babka <vbabka@xxxxxxx>
Signed-off-by: Barry Song <song.bao.hua@xxxxxxxxxxxxx>
---
mm/gup_benchmark.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/gup_benchmark.c b/mm/gup_benchmark.c
index 8b3e5b5..1d10553 100644
--- a/mm/gup_benchmark.c
+++ b/mm/gup_benchmark.c
@@ -199,7 +199,7 @@ static const struct file_operations gup_benchmark_fops = {
.unlocked_ioctl = gup_benchmark_ioctl,
};

-static int gup_benchmark_init(void)
+static int __init gup_benchmark_init(void)
{
debugfs_create_file_unsafe("gup_benchmark", 0600, NULL, NULL,
&gup_benchmark_fops);
--
2.7.4