[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <155977190749.2443951.1028412998584791672.stgit@dwillia2-desk3.amr.corp.intel.com>
Date: Wed, 05 Jun 2019 14:58:27 -0700
From: Dan Williams <dan.j.williams@...el.com>
To: akpm@...ux-foundation.org
Cc: Michal Hocko <mhocko@...e.com>,
Logan Gunthorpe <logang@...tatee.com>,
Pavel Tatashin <pasha.tatashin@...een.com>,
David Hildenbrand <david@...hat.com>,
Oscar Salvador <osalvador@...e.de>, linux-mm@...ck.org,
linux-nvdimm@...ts.01.org, linux-kernel@...r.kernel.org,
osalvador@...e.de, mhocko@...e.com
Subject: [PATCH v9 05/12] mm/hotplug: Kill is_dev_zone() usage in
__remove_pages()
The zone type check was a leftover from the cleanup that plumbed altmap
through the memory hotplug path, i.e. commit da024512a1fa "mm: pass the
vmem_altmap to arch_remove_memory and __remove_pages".
Cc: Michal Hocko <mhocko@...e.com>
Cc: Logan Gunthorpe <logang@...tatee.com>
Cc: Pavel Tatashin <pasha.tatashin@...een.com>
Reviewed-by: David Hildenbrand <david@...hat.com>
Reviewed-by: Oscar Salvador <osalvador@...e.de>
Signed-off-by: Dan Williams <dan.j.williams@...el.com>
---
mm/memory_hotplug.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c
index 647859a1d119..4b882c57781a 100644
--- a/mm/memory_hotplug.c
+++ b/mm/memory_hotplug.c
@@ -535,11 +535,8 @@ void __remove_pages(struct zone *zone, unsigned long phys_start_pfn,
unsigned long map_offset = 0;
int sections_to_remove;
- /* In the ZONE_DEVICE case device driver owns the memory region */
- if (is_dev_zone(zone)) {
- if (altmap)
- map_offset = vmem_altmap_offset(altmap);
- }
+ if (altmap)
+ map_offset = vmem_altmap_offset(altmap);
clear_zone_contiguous(zone);
Powered by blists - more mailing lists