[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190610165642.GB5643@linux>
Date: Mon, 10 Jun 2019 18:56:43 +0200
From: Oscar Salvador <osalvador@...e.de>
To: David Hildenbrand <david@...hat.com>
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
linux-ia64@...r.kernel.org, linuxppc-dev@...ts.ozlabs.org,
linux-s390@...r.kernel.org, linux-sh@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, akpm@...ux-foundation.org,
Dan Williams <dan.j.williams@...el.com>,
Wei Yang <richard.weiyang@...il.com>,
Igor Mammedov <imammedo@...hat.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"Rafael J. Wysocki" <rafael@...nel.org>,
Alex Deucher <alexander.deucher@....com>,
"David S. Miller" <davem@...emloft.net>,
Mark Brown <broonie@...nel.org>,
Chris Wilson <chris@...is-wilson.co.uk>,
Jonathan Cameron <Jonathan.Cameron@...wei.com>
Subject: Re: [PATCH v3 10/11] mm/memory_hotplug: Make
unregister_memory_block_under_nodes() never fail
On Mon, May 27, 2019 at 01:11:51PM +0200, David Hildenbrand wrote:
> We really don't want anything during memory hotunplug to fail.
> We always pass a valid memory block device, that check can go. Avoid
> allocating memory and eventually failing. As we are always called under
> lock, we can use a static piece of memory. This avoids having to put
> the structure onto the stack, having to guess about the stack size
> of callers.
>
> Patch inspired by a patch from Oscar Salvador.
>
> In the future, there might be no need to iterate over nodes at all.
> mem->nid should tell us exactly what to remove. Memory block devices
> with mixed nodes (added during boot) should properly fenced off and never
> removed.
>
> Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
> Cc: "Rafael J. Wysocki" <rafael@...nel.org>
> Cc: Alex Deucher <alexander.deucher@....com>
> Cc: "David S. Miller" <davem@...emloft.net>
> Cc: Mark Brown <broonie@...nel.org>
> Cc: Chris Wilson <chris@...is-wilson.co.uk>
> Cc: David Hildenbrand <david@...hat.com>
> Cc: Oscar Salvador <osalvador@...e.de>
> Cc: Andrew Morton <akpm@...ux-foundation.org>
> Cc: Jonathan Cameron <Jonathan.Cameron@...wei.com>
> Signed-off-by: David Hildenbrand <david@...hat.com>
Reviewed-by: Oscar Salvador <osalvador@...e.de>
--
Oscar Salvador
SUSE L3
Powered by blists - more mailing lists