[folded-merged] mm-disable-interrupts-while-initializing-deferred-pages-v6.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: mm-disable-interrupts-while-initializing-deferred-pages-v6
has been removed from the -mm tree.  Its filename was
     mm-disable-interrupts-while-initializing-deferred-pages-v6.patch

This patch was dropped because it was folded into mm-disable-interrupts-while-initializing-deferred-pages.patch

------------------------------------------------------
From: Pavel Tatashin <pasha.tatashin@xxxxxxxxxx>
Subject: mm-disable-interrupts-while-initializing-deferred-pages-v6

- Fixed issues found by Andrew Morton: replaced cond_resched() with
  touch_nmi_watchdog(), instead of simply deleting it.

- Removed useless pgdata_resize_lock_irq(), as regular
  pgdata_resize_lock() does exactly what is needed.

Link: http://lkml.kernel.org/r/20180313182355.17669-2-pasha.tatashin@xxxxxxxxxx
Signed-off-by: Pavel Tatashin <pasha.tatashin@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 include/linux/memory_hotplug.h |   20 --------------------
 mm/page_alloc.c                |   13 ++++++++-----
 2 files changed, 8 insertions(+), 25 deletions(-)

diff -puN include/linux/memory_hotplug.h~mm-disable-interrupts-while-initializing-deferred-pages-v6 include/linux/memory_hotplug.h
--- a/include/linux/memory_hotplug.h~mm-disable-interrupts-while-initializing-deferred-pages-v6
+++ a/include/linux/memory_hotplug.h
@@ -287,32 +287,12 @@ void pgdat_resize_init(struct pglist_dat
 {
 	spin_lock_init(&pgdat->node_size_lock);
 }
-
-/* Disable interrupts and save previous IRQ state in flags before locking */
-static inline
-void pgdat_resize_lock_irq(struct pglist_data *pgdat, unsigned long *flags)
-{
-	unsigned long tmp_flags;
-
-	local_irq_save(*flags);
-	local_irq_disable();
-	pgdat_resize_lock(pgdat, &tmp_flags);
-}
-
-static inline
-void pgdat_resize_unlock_irq(struct pglist_data *pgdat, unsigned long *flags)
-{
-	pgdat_resize_unlock(pgdat, flags);
-}
-
 #else /* !(CONFIG_MEMORY_HOTPLUG || CONFIG_DEFERRED_STRUCT_PAGE_INIT) */
 /*
  * Stub functions for when hotplug is off
  */
 static inline void pgdat_resize_lock(struct pglist_data *p, unsigned long *f) {}
 static inline void pgdat_resize_unlock(struct pglist_data *p, unsigned long *f) {}
-static inline void pgdat_resize_lock_irq(struct pglist_data *p, unsigned long *f) {}
-static inline void pgdat_resize_unlock_irq(struct pglist_data *p, unsigned long *f) {}
 static inline void pgdat_resize_init(struct pglist_data *pgdat) {}
 #endif /* !(CONFIG_MEMORY_HOTPLUG || CONFIG_DEFERRED_STRUCT_PAGE_INIT) */
 
diff -puN mm/page_alloc.c~mm-disable-interrupts-while-initializing-deferred-pages-v6 mm/page_alloc.c
--- a/mm/page_alloc.c~mm-disable-interrupts-while-initializing-deferred-pages-v6
+++ a/mm/page_alloc.c
@@ -1506,6 +1506,7 @@ static void __init deferred_free_pages(i
 		} else if (!(pfn & nr_pgmask)) {
 			deferred_free_range(pfn - nr_free, nr_free);
 			nr_free = 1;
+			touch_nmi_watchdog();
 		} else {
 			nr_free++;
 		}
@@ -1532,10 +1533,12 @@ static unsigned long  __init deferred_in
 		if (!deferred_pfn_valid(nid, pfn, &nid_init_state)) {
 			page = NULL;
 			continue;
-		} else if (!page || !(pfn & nr_pgmask))
+		} else if (!page || !(pfn & nr_pgmask)) {
 			page = pfn_to_page(pfn);
-		else
+			touch_nmi_watchdog();
+		} else {
 			page++;
+		}
 		__init_single_page(page, pfn, zid, nid, true);
 		nr_pages++;
 	}
@@ -1560,10 +1563,10 @@ static int __init deferred_init_memmap(v
 	if (!cpumask_empty(cpumask))
 		set_cpus_allowed_ptr(current, cpumask);
 
-	pgdat_resize_lock_irq(pgdat, &flags);
+	pgdat_resize_lock(pgdat, &flags);
 	first_init_pfn = pgdat->first_deferred_pfn;
 	if (first_init_pfn == ULONG_MAX) {
-		pgdat_resize_unlock_irq(pgdat, &flags);
+		pgdat_resize_unlock(pgdat, &flags);
 		pgdat_init_report_one_done();
 		return 0;
 	}
@@ -1597,7 +1600,7 @@ static int __init deferred_init_memmap(v
 		epfn = min_t(unsigned long, zone_end_pfn(zone), PFN_DOWN(epa));
 		deferred_free_pages(nid, zid, spfn, epfn);
 	}
-	pgdat_resize_unlock_irq(pgdat, &flags);
+	pgdat_resize_unlock(pgdat, &flags);
 
 	/* Sanity check that the next zone really is unpopulated */
 	WARN_ON(++zid < MAX_NR_ZONES && populated_zone(++zone));
_

Patches currently in -mm which might be from pasha.tatashin@xxxxxxxxxx are

mm-disable-interrupts-while-initializing-deferred-pages.patch
mm-initialize-pages-on-demand-during-boot.patch
mm-initialize-pages-on-demand-during-boot-fix-3.patch
mm-initialize-pages-on-demand-during-boot-fix-4.patch
mm-initialize-pages-on-demand-during-boot-v5.patch
mm-initialize-pages-on-demand-during-boot-v6.patch
mm-memory_hotplug-enforce-block-size-aligned-range-check.patch
x86-mm-memory_hotplug-determine-block-size-based-on-the-end-of-boot-memory.patch
x86-mm-memory_hotplug-determine-block-size-based-on-the-end-of-boot-memory-v4.patch
mm-uninitialized-struct-page-poisoning-sanity-checking.patch
mm-uninitialized-struct-page-poisoning-sanity-checking-v4.patch
mm-memory_hotplug-optimize-probe-routine.patch
mm-memory_hotplug-dont-read-nid-from-struct-page-during-hotplug.patch
mm-memory_hotplug-dont-read-nid-from-struct-page-during-hotplug-v5.patch
mm-memory_hotplug-optimize-memory-hotplug.patch
mm-memory_hotplug-optimize-memory-hotplug-v5.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux