*参照元 [#r883ca9b] #backlinks *説明 [#od34fcc7] -パス: [[linux-4.4.1/mm/page_isolation.c]] -FIXME: これは何? --説明 **引数 [#x8952a6e] -struct page *page -- --[[linux-4.4.1/page]] -unsigned long private -- -int **resultp -- **返り値 [#k6397032] -struct page * -- --[[linux-4.4.1/page]] **参考 [#n7a1c5b5] *実装 [#qc81d5c3] struct page *alloc_migrate_target(struct page *page, unsigned long private, int **resultp) { gfp_t gfp_mask = GFP_USER | __GFP_MOVABLE; - --[[linux-4.4.1/gfp_t]] --[[linux-4.4.1/GFP_USER]] --[[linux-4.4.1/__GFP_MOVABLE]] /* * TODO: allocate a destination hugepage from a nearest neighbor node, * accordance with memory policy of the user process if possible. For * now as a simple work-around, we use the next node for destination. */ if (PageHuge(page)) { nodemask_t src = nodemask_of_node(page_to_nid(page)); nodemask_t dst; nodes_complement(dst, src); return alloc_huge_page_node(page_hstate(compound_head(page)), next_node(page_to_nid(page), dst)); } - --[[linux-4.4.1/PageHuge()]] --[[linux-4.4.1/nodemask_of_node()]] --[[linux-4.4.1/page_to_nid()]] --[[linux-4.4.1/nodes_complement()]] --[[linux-4.4.1/alloc_huge_page_node()]] --[[linux-4.4.1/page_hstate()]] --[[linux-4.4.1/compound_head()]] --[[linux-4.4.1/next_node()]] if (PageHighMem(page)) gfp_mask |= __GFP_HIGHMEM; - --[[linux-4.4.1/PageHighMem()]] return alloc_page(gfp_mask); - --[[linux-4.4.1/alloc_page()]] } *コメント [#dc5d7cc0]