Messages in this thread | | | From | Joonsoo Kim <> | Date | Mon, 6 Jul 2020 17:44:16 +0900 | Subject | Re: [PATCH v3 8/8] mm/page_alloc: remove a wrapper for alloc_migration_target() |
| |
2020년 7월 4일 (토) 오전 1:18, Vlastimil Babka <vbabka@suse.cz>님이 작성: > > On 6/23/20 8:13 AM, js1304@gmail.com wrote: > > From: Joonsoo Kim <iamjoonsoo.kim@lge.com> > > > > There is a well-defined standard migration target callback. > > Use it directly. > > > > Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> > > Acked-by: Vlastimil Babka <vbabka@suse.cz> > > But you could move this to patch 5/8 to reduce churn. And do the same with
Yes, I now realize that it is possible to make this change earlier. However, reordering the patches would cause additional change so I will not change the order in the next version. Result would be the same. :)
> mm/memory-failure.c new_page() there really, to drop the simple wrappers. Only
Okay. As you suggested below, with NUMA_NO_NODE handling, we can remove the more wrappers. I will do it.
> new_node_page() is complex enough. > Hm wait, new_node_page() is only called by do_migrate_range() which is only > called by __offline_pages() with explicit test that all pages are from a single > zone, so the nmask could also be setup just once and not per each page, making > it possible to remove the wrapper.
I have tried this suggestion and found that code is not simpler than before. However, there would be minor performance benefit so I will include this change, too.
> But for new_page() you would have to define that mtc->nid == NUMA_NO_NODE means > alloc_migrate_target() does page_to_nid(page) by itself.
Yes, I will use this suggestion.
Thanks.
| |