Skip to content

Commit b908243

Browse files
tixxdztorvalds
authored andcommitted
fs/proc/kcore.c: make get_sparsemem_vmemmap_info() static
get_sparsemem_vmemmap_info() is only used inside fs/proc/kcore.c Signed-off-by: Djalal Harouni <tixxdz@opendz.org> Reviewed-by: WANG Cong <xiyou.wangcong@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent accb61f commit b908243

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎fs/proc/kcore.c‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,8 @@ static int kcore_update_ram(void)
157157

158158
#ifdef CONFIG_SPARSEMEM_VMEMMAP
159159
/* calculate vmemmap's address from given system ram pfn and register it */
160-
int get_sparsemem_vmemmap_info(struct kcore_list *ent, struct list_head *head)
160+
static int
161+
get_sparsemem_vmemmap_info(struct kcore_list *ent, struct list_head *head)
161162
{
162163
unsigned long pfn = __pa(ent->addr) >> PAGE_SHIFT;
163164
unsigned long nr_pages = ent->size >> PAGE_SHIFT;
@@ -189,7 +190,8 @@ int get_sparsemem_vmemmap_info(struct kcore_list *ent, struct list_head *head)
189190

190191
}
191192
#else
192-
int get_sparsemem_vmemmap_info(struct kcore_list *ent, struct list_head *head)
193+
static int
194+
get_sparsemem_vmemmap_info(struct kcore_list *ent, struct list_head *head)
193195
{
194196
return 1;
195197
}

0 commit comments

Comments
 (0)