2021-04-14 06:56:09

by Yang Shi

[permalink] [raw]
Subject: [v2 PATCH 2/7] mm: memory: make numa_migrate_prep() non-static

The numa_migrate_prep() will be used by huge NUMA fault as well in the following
patch, make it non-static.

Signed-off-by: Yang Shi <[email protected]>
---
mm/internal.h | 3 +++
mm/memory.c | 5 ++---
2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/mm/internal.h b/mm/internal.h
index f469f69309de..b6f889d9c22d 100644
--- a/mm/internal.h
+++ b/mm/internal.h
@@ -659,4 +659,7 @@ int vmap_pages_range_noflush(unsigned long addr, unsigned long end,

void vunmap_range_noflush(unsigned long start, unsigned long end);

+int numa_migrate_prep(struct page *page, struct vm_area_struct *vma,
+ unsigned long addr, int page_nid, int *flags);
+
#endif /* __MM_INTERNAL_H */
diff --git a/mm/memory.c b/mm/memory.c
index e0cbffeceb0b..bbb38066021a 100644
--- a/mm/memory.c
+++ b/mm/memory.c
@@ -4119,9 +4119,8 @@ static vm_fault_t do_fault(struct vm_fault *vmf)
return ret;
}

-static int numa_migrate_prep(struct page *page, struct vm_area_struct *vma,
- unsigned long addr, int page_nid,
- int *flags)
+int numa_migrate_prep(struct page *page, struct vm_area_struct *vma,
+ unsigned long addr, int page_nid, int *flags)
{
get_page(page);

--
2.26.2


2021-05-18 12:02:39

by Mel Gorman

[permalink] [raw]
Subject: Re: [v2 PATCH 2/7] mm: memory: make numa_migrate_prep() non-static

On Tue, Apr 13, 2021 at 02:24:11PM -0700, Yang Shi wrote:
> The numa_migrate_prep() will be used by huge NUMA fault as well in the following
> patch, make it non-static.
>
> Signed-off-by: Yang Shi <[email protected]>

Acked-by: Mel Gorman <[email protected]>

--
Mel Gorman
SUSE Labs