Commit 99a19cf1 authored by Prarit Bhargava's avatar Prarit Bhargava Committed by Tony Luck

[IA64] Stop bogus NMI & softlockup warnings in ia64 show_mem

When dumping memory via sysrq-m it is possible to take a bogus NMI watchdog
or softlockup watchdog because the dump can take a long time on big memory
systems.

Occasionally tickle the watchdog when doing the dump.
Signed-off-by: default avatarPrarit Bhargava <prarit@redhat.com>
Signed-off-by: default avatarTony Luck <tony.luck@intel.com>
parent 6e9de181
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
#include <linux/bootmem.h> #include <linux/bootmem.h>
#include <linux/efi.h> #include <linux/efi.h>
#include <linux/mm.h> #include <linux/mm.h>
#include <linux/nmi.h>
#include <linux/swap.h> #include <linux/swap.h>
#include <asm/meminit.h> #include <asm/meminit.h>
...@@ -56,6 +57,8 @@ void show_mem(void) ...@@ -56,6 +57,8 @@ void show_mem(void)
present = pgdat->node_present_pages; present = pgdat->node_present_pages;
for(i = 0; i < pgdat->node_spanned_pages; i++) { for(i = 0; i < pgdat->node_spanned_pages; i++) {
struct page *page; struct page *page;
if (unlikely(i % MAX_ORDER_NR_PAGES == 0))
touch_nmi_watchdog();
if (pfn_valid(pgdat->node_start_pfn + i)) if (pfn_valid(pgdat->node_start_pfn + i))
page = pfn_to_page(pgdat->node_start_pfn + i); page = pfn_to_page(pgdat->node_start_pfn + i);
else { else {
......
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/mm.h> #include <linux/mm.h>
#include <linux/nmi.h>
#include <linux/swap.h> #include <linux/swap.h>
#include <linux/bootmem.h> #include <linux/bootmem.h>
#include <linux/acpi.h> #include <linux/acpi.h>
...@@ -533,6 +534,8 @@ void show_mem(void) ...@@ -533,6 +534,8 @@ void show_mem(void)
present = pgdat->node_present_pages; present = pgdat->node_present_pages;
for(i = 0; i < pgdat->node_spanned_pages; i++) { for(i = 0; i < pgdat->node_spanned_pages; i++) {
struct page *page; struct page *page;
if (unlikely(i % MAX_ORDER_NR_PAGES == 0))
touch_nmi_watchdog();
if (pfn_valid(pgdat->node_start_pfn + i)) if (pfn_valid(pgdat->node_start_pfn + i))
page = pfn_to_page(pgdat->node_start_pfn + i); page = pfn_to_page(pgdat->node_start_pfn + i);
else { else {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment