From: Michal Hocko <mhocko@kernel.org>
To: linux-mm@kvack.org
Cc: Andrew Morton <akpm@linux-foundation.org>,
Vlastimil Babka <vbabka@suse.cz>,
Naoya Horiguchi <n-horiguchi@ah.jp.nec.com>,
Xishi Qiu <qiuxishi@huawei.com>,
zhong jiang <zhongjiang@huawei.com>,
Joonsoo Kim <js1304@gmail.com>,
LKML <linux-kernel@vger.kernel.org>
Subject: [PATCH 0/4] more sensible hugetlb migration for hotplug/CMA
Date: Thu, 8 Jun 2017 09:45:49 +0200 [thread overview]
Message-ID: <20170608074553.22152-1-mhocko@kernel.org> (raw)
Hi,
I have received a bug report for memory hotplug triggered hugetlb
migration on a distribution kernel but the very same issue is still
present in the current upstream code. The bug is described in patch
2 but in short the issue is that new_node_page doesn't really try to
consume preallocated hugetlb pages in the pool on other than the next
node which is really suboptimal. This results in very likely failures of
memory hotremove even though there are many hugetlb pages in the pool.
I think it is fair to call this a bug.
Patches 1 and 3 are cleanups and the last patch is still a RFC because
I am not sure we really need/want to go that way. The thing is that the
page allocator relies on zonelists to do the proper allocation fallback
wrt. numa distances. We do not have anything like that for hugetlb
allocations because they are not zone aware in general. Making them
fully zonlist (or alternately nodelist) aware is quite a large project
I guess. Instead I admittedly went the path of least resistance and
instead provided a much simpler approach. More on that in patch 4. If
this doesn't seem good enough I will drop it from the series but to me
it looks like a reasonable compromise code wise.
Thoughts, ideas, objections?
Diffstat
include/linux/hugetlb.h | 3 +++
include/linux/migrate.h | 17 +++++++++++++++++
include/linux/nodemask.h | 20 ++++++++++++++++++++
mm/hugetlb.c | 30 ++++++++++++++++++++++++++++++
mm/memory_hotplug.c | 25 ++++++-------------------
mm/page_isolation.c | 18 ++----------------
6 files changed, 78 insertions(+), 35 deletions(-)
Shortlog
Michal Hocko (4):
mm, memory_hotplug: simplify empty node mask handling in new_node_page
hugetlb, memory_hotplug: prefer to use reserved pages for migration
mm: unify new_node_page and alloc_migrate_target
hugetlb: add support for preferred node to alloc_huge_page_nodemask
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next reply other threads:[~2017-06-08 7:46 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-08 7:45 Michal Hocko [this message]
2017-06-08 7:45 ` [PATCH 1/4] mm, memory_hotplug: simplify empty node mask handling in new_node_page Michal Hocko
2017-06-08 8:15 ` Vlastimil Babka
2017-06-08 7:45 ` [PATCH 2/4] hugetlb, memory_hotplug: prefer to use reserved pages for migration Michal Hocko
2017-06-08 8:22 ` Vlastimil Babka
2017-06-08 7:45 ` [PATCH 3/4] mm: unify new_node_page and alloc_migrate_target Michal Hocko
2017-06-08 8:36 ` Vlastimil Babka
2017-06-08 8:40 ` Michal Hocko
2017-06-08 7:45 ` [RFC PATCH 4/4] hugetlb: add support for preferred node to alloc_huge_page_nodemask Michal Hocko
2017-06-08 8:38 ` Vlastimil Babka
2017-06-12 9:06 ` Michal Hocko
2017-06-12 11:48 ` Michal Hocko
2017-06-12 11:53 ` Vlastimil Babka
2017-06-12 12:20 ` Michal Hocko
2017-06-12 15:21 ` Michal Hocko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170608074553.22152-1-mhocko@kernel.org \
--to=mhocko@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=js1304@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=n-horiguchi@ah.jp.nec.com \
--cc=qiuxishi@huawei.com \
--cc=vbabka@suse.cz \
--cc=zhongjiang@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).