Skip to content

Commit a52149f

Browse files
johnhubbardtorvalds
authored andcommitted
mm/memory_hotplug.c: remove unused local zone_type from __remove_zone()
__remove_zone() sets up up zone_type, but never uses it for anything. This does not cause a warning, due to the (necessary) use of -Wno-unused-but-set-variable. However, it's noise, so just delete it. Link: http://lkml.kernel.org/r/20170624043421.24465-2-jhubbard@nvidia.com Signed-off-by: John Hubbard <jhubbard@nvidia.com> Acked-by: Michal Hocko <mhocko@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent d09b646 commit a52149f

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

‎mm/memory_hotplug.c‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -580,11 +580,8 @@ static void __remove_zone(struct zone *zone, unsigned long start_pfn)
580580
{
581581
struct pglist_data *pgdat = zone->zone_pgdat;
582582
int nr_pages = PAGES_PER_SECTION;
583-
int zone_type;
584583
unsigned long flags;
585584

586-
zone_type = zone - pgdat->node_zones;
587-
588585
pgdat_resize_lock(zone->zone_pgdat, &flags);
589586
shrink_zone_span(zone, start_pfn, start_pfn + nr_pages);
590587
shrink_pgdat_span(pgdat, start_pfn, start_pfn + nr_pages);

0 commit comments

Comments
 (0)