2.6.9-rc1-mm4: swsusp + AMD64 = LOCKUP on CPU0
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): 20040908102652.GA2921@atrey.karlin.mff.cuni.cz.suse.lists.linux.kernel
Quoted 11 lines · Pavel Machek
Hi!
Quoted 1 line
One for you guys on lkml ;)
It simply takes long to count pages (O(n^2) algorithm), so watchdog triggers. I have better algorithm locally, but would like merge to linus first. (I posted it to lkml some days ago, I can attach the bigdiff).
Just disable the watchdog. Suspend *is* going to take time with disabled interrupts.
As a short term workaround you could also add touch_nmi_watchdog()s in that loop.
-Andi
Quoted 11 lines · Andi Kleen
Quoted 9 lines · Pavel Machek
Hi!
Quoted 1 line
One for you guys on lkml ;)
It simply takes long to count pages (O(n^2) algorithm), so watchdog triggers. I have better algorithm locally, but would like merge to linus first. (I posted it to lkml some days ago, I can attach the bigdiff).
Quoted 6 lines
Quoted 2 lines
Just disable the watchdog. Suspend *is* going to take time with disabled interrupts.
As a short term workaround you could also add touch_nmi_watchdog()s in that loop.
You mean like that:
swsusp.c renamed from swsusp.c.orig +3 -0
@@ -38,6 +38,7 @@#include <linux/module.h> #include <linux/mm.h> +#include <linux/nmi.h> #include <linux/suspend.h> #include <linux/smp_lock.h> #include <linux/file.h>
@@ -561,6 +562,7 @@for_each_zone (zone) {if (!is_highmem (zone)) { +touch_nmi_watchdog ();for (zone_pfn =0 ; zone_pfn < zone->spanned_pages; ++zone_pfn) nr_copy_pages +=saveable (zone, &zone_pfn); }
@@ -576,6 +578,7 @@for_each_zone (zone) {if (!is_highmem (zone)) +touch_nmi_watchdog ();for (zone_pfn =0 ; zone_pfn < zone->spanned_pages; ++zone_pfn) {if (saveable (zone, &zone_pfn)) {struct page * page;
---
Just guessing. :-)
Greets,
RJW
Signature · 3 lines
- Would you tell me, please, which way I ought to go from here? - That depends a good deal on where you want to get to. -- Lewis Carroll "Alice's Adventures in Wonderland"
Quoted 12 lines · Rafael J. Wysocki
Quoted 11 lines · Andi Kleen
Quoted 9 lines · Pavel Machek
Hi!
Quoted 1 line
One for you guys on lkml ;)
It simply takes long to count pages (O(n^2) algorithm), so watchdog triggers. I have better algorithm locally, but would like merge to linus first. (I posted it to lkml some days ago, I can attach the bigdiff).
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines
Just disable the watchdog. Suspend *is* going to take time with disabled interrupts.
As a short term workaround you could also add touch_nmi_watchdog()s in that loop.
You mean like that:
I doubt this will help, because the number of zones is quite small.
Better check every N pages, e.g. N=100
-Andi
Quoted 17 lines · Andi Kleen
Quoted 16 lines · Rafael J. Wysocki
Quoted 15 lines · Andi Kleen
Quoted 11 lines · Pavel Machek
Hi!
Quoted 1 line
One for you guys on lkml ;)
It simply takes long to count pages (O(n^2) algorithm), so watchdog triggers. I have better algorithm locally, but would like merge to linus first. (I posted it to lkml some days ago, I can attach the bigdiff).
Just disable the watchdog. Suspend *is* going to take time with disabled interrupts.
Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
As a short term workaround you could also add touch_nmi_watchdog()s in that loop.
You mean like that:
I doubt this will help, because the number of zones is quite small.
Better check every N pages, e.g. N=100
I've done something like that:
swsusp.c renamed from swsusp.c.orig +9 -3
@@ -38,6 +38,7 @@#include <linux/module.h> #include <linux/mm.h> +#include <linux/nmi.h> #include <linux/suspend.h> #include <linux/smp_lock.h> #include <linux/file.h>
@@ -556,14 +557,19 @@ {struct zone *zone;unsigned long zone_pfn; +unsigned nmi_cnt =0 ; nr_copy_pages =0 ;for_each_zone (zone) { -if (!is_highmem (zone)) { -for (zone_pfn =0 ; zone_pfn < zone->spanned_pages; ++zone_pfn) +if (!is_highmem (zone)) +for (zone_pfn =0 ; zone_pfn < zone->spanned_pages; ++zone_pfn) { nr_copy_pages +=saveable (zone, &zone_pfn); - } +if (nmi_cnt++ >=100 ) { +touch_nmi_watchdog (); + nmi_cnt =0 ; + } + } } }
and it works, but it seems to me that something similar is necessary for resuming (I get an NMI watchdog report if it's not disabled).
Greets,
RJW
Signature · 3 lines
- Would you tell me, please, which way I ought to go from here? - That depends a good deal on where you want to get to. -- Lewis Carroll "Alice's Adventures in Wonderland"
Hi!
Quoted 21 lines
Quoted 11 lines
Quoted 11 lines
Quoted 11 lines
Quoted 9 lines
Quoted 1 line
One for you guys on lkml ;)
It simply takes long to count pages (O(n^2) algorithm), so watchdog triggers. I have better algorithm locally, but would like merge to linus first. (I posted it to lkml some days ago, I can attach the bigdiff).
Just disable the watchdog. Suspend *is* going to take time with disabled interrupts.
Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
As a short term workaround you could also add touch_nmi_watchdog()s in that loop.
You mean like that:
I doubt this will help, because the number of zones is quite small.
Better check every N pages, e.g. N=100
I've done something like that:
...
Quoted 1 line
swsusp.c renamed from swsusp.c.orig +1
-0+ nmi_cnt =0 ;
...
Quoted 2 lines
and it works, but it seems to me that something similar is necessary for resuming (I get an NMI watchdog report if it's not disabled).
Actually, it can not be solved like that. If some memory is actually modified by nmi watchdog, you might get inconsistent snapshot; bad.
Pavel