diff for duplicates of <20180711104944.GG1969@MiWiFi-R3L-srv> diff --git a/a/1.txt b/N1/1.txt index 18ac2ef..15f6415 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -44,3 +44,35 @@ On 07/11/18 at 06:41pm, Baoquan He wrote: Sorry, I used wrong function. Please try this one: + +From 005435407a331ecf2803e5ebfdc44b8f5f8f9748 Mon Sep 17 00:00:00 2001 +From: Baoquan He <bhe@redhat.com> +Date: Wed, 11 Jul 2018 18:30:04 +0800 +Subject: [PATCH v2] mm, page_alloc: find movable zone after kernel text + +In find_zone_movable_pfns_for_nodes(), when try to find the starting +PFN movable zone begins in each node, kernel text position is not +considered. KASLR may put kernel after which movable zone begins. + +Fix it by finding movable zone after kernel text. + +Signed-off-by: Baoquan He <bhe@redhat.com> +--- + mm/page_alloc.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/mm/page_alloc.c b/mm/page_alloc.c +index 1521100..17584cc 100644 +--- a/mm/page_alloc.c ++++ b/mm/page_alloc.c +@@ -6678,6 +6678,8 @@ static void __init find_zone_movable_pfns_for_nodes(void) + unsigned long size_pages; + + start_pfn = max(start_pfn, zone_movable_pfn[nid]); ++ /* KASLR may put kernel after 'start_pfn', start after kernel */ ++ start_pfn = max(start_pfn, PFN_UP(_etext)); + if (start_pfn >= end_pfn) + continue; + +-- +2.1.0 diff --git a/a/content_digest b/N1/content_digest index 3b8c20c..adb086a 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -63,6 +63,38 @@ "\n" "Sorry, I used wrong function.\n" "\n" - Please try this one: + "Please try this one:\n" + "\n" + "From 005435407a331ecf2803e5ebfdc44b8f5f8f9748 Mon Sep 17 00:00:00 2001\n" + "From: Baoquan He <bhe@redhat.com>\n" + "Date: Wed, 11 Jul 2018 18:30:04 +0800\n" + "Subject: [PATCH v2] mm, page_alloc: find movable zone after kernel text\n" + "\n" + "In find_zone_movable_pfns_for_nodes(), when try to find the starting\n" + "PFN movable zone begins in each node, kernel text position is not\n" + "considered. KASLR may put kernel after which movable zone begins.\n" + "\n" + "Fix it by finding movable zone after kernel text.\n" + "\n" + "Signed-off-by: Baoquan He <bhe@redhat.com>\n" + "---\n" + " mm/page_alloc.c | 2 ++\n" + " 1 file changed, 2 insertions(+)\n" + "\n" + "diff --git a/mm/page_alloc.c b/mm/page_alloc.c\n" + "index 1521100..17584cc 100644\n" + "--- a/mm/page_alloc.c\n" + "+++ b/mm/page_alloc.c\n" + "@@ -6678,6 +6678,8 @@ static void __init find_zone_movable_pfns_for_nodes(void)\n" + " \t\t\tunsigned long size_pages;\n" + " \n" + " \t\t\tstart_pfn = max(start_pfn, zone_movable_pfn[nid]);\n" + "+\t\t\t/* KASLR may put kernel after 'start_pfn', start after kernel */\n" + "+\t\t\tstart_pfn = max(start_pfn, PFN_UP(_etext));\n" + " \t\t\tif (start_pfn >= end_pfn)\n" + " \t\t\t\tcontinue;\n" + " \n" + "-- \n" + 2.1.0 -127ca004bd465607c1eafc1b226b7ef98d68bd6c05f333a868c327db87f28ab4 +85011e8a0340bc4176f539236822ae12c0138bec24e43fcb64f5bd05a69a82eb
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.