lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 27 Jan 2022 09:52:59 +0100
From:   Michal Hocko <mhocko@...nel.org>
To:     Andrew Morton <akpm@...ux-foundation.org>
Cc:     <linux-mm@...ck.org>, LKML <linux-kernel@...r.kernel.org>,
        David Hildenbrand <david@...hat.com>,
        Alexey Makhalov <amakhalov@...are.com>,
        Dennis Zhou <dennis@...nel.org>,
        Eric Dumazet <eric.dumazet@...il.com>,
        Oscar Salvador <osalvador@...e.de>, Tejun Heo <tj@...nel.org>,
        Christoph Lameter <cl@...ux.com>,
        Nico Pache <npache@...hat.com>,
        Wei Yang <richard.weiyang@...il.com>,
        Rafael Aquini <raquini@...hat.com>
Subject: [PATCH 0/6] mm, memory_hotplug: handle unitialized numa node gracefully

Hi,
the previous version of this patchset has been posted her:
http://lkml.kernel.org/r/20211214100732.26335-1-mhocko@kernel.org

I have ended up with 6 patches in the end. The core of the fix is patch
2 which also links existing bug reports. The high level goal is to have
all possible numa nodes have their pgdat allocated and initialized so 
	for_each_possible_node(nid)
		NODE_DATA(nid)
will never return a garbage. This has proven to be problem in several
places when an offline numa node is used for an allocation just to
realize that node_data and therefore allocation fallback zonelists are
not initialized and such an allocation request blows up.

There were attempts to address that by checking node_online in several
places including the page allocator. This patchset approaches the
problem from a different perspective and instead of special casing,
which just adds a runtime overhead, it allocates pglist_data for each
possible node. This can add some memory overhead for platforms with high
number of possible nodes if they do not contain any memory. This should
be a rather rare configuration though.

How to test this? David has provided and excellent howto:
http://lkml.kernel.org/r/6e5ebc19-890c-b6dd-1924-9f25c441010d@redhat.com

Patches 1 and 3-6 are mostly cleanups. The patchset has been reviewed by
Rafael (thanks!) and the core fix tested by Rafael and Alexey (thanks to
both). David has tested as per instructions above and hasn't found any
fallouts in the memory hotplug scenarios.

Please consider for inclusion.

Thanks!

Diffstat:
 arch/ia64/mm/discontig.c       |  11 +---
 include/linux/memory_hotplug.h | 118 ++++++++++++++++++++---------------------
 mm/memcontrol.c                |  14 +----
 mm/memory_hotplug.c            |  55 ++++---------------
 mm/page_alloc.c                |  70 +++++++++++++++++++++---
 5 files changed, 133 insertions(+), 135 deletions(-)


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ