Skip to contentSkip to conversation

acpi double resume and fail

BUG Christian Leber 9 participants 28 messages May 18, 2007 – Aug 12, 2007 1 message not in the archive ACPI

lore
Share & tools
lore
#0 lore raw

Hello,

i hit a problem with suspend to ram and especially resume.
Hardware: Dell Latitude D810 (some Intel 915 with Intel Pentium M)

With 2.6.19.7 suspend to ram works reliable, but with 2.6.20-rc4 it stopped working reliable.
I still can suspend, but after the first resume it goes back to sleep directly again, when resuming again it works.
After the second suspend it won't resume at all.

The problem is that i can't try out the kernel versions <rc4, because rc1, rc2 and rc3 doesn't boot at all, so git-bisect also won't help.

Has somebody an idea what i could try out?

(the distribution is in this case ubuntu feisty)

Regards
Christian Leber

Signature · 1 line
http://rettetdieti.vde-uni-mannheim.de/
#1 lore raw
Quoted 7 lines · On Fri, 18 May 2007 23:37:01 +0200 Christian Leber <[email protected]> wrote:

Hello,

i hit a problem with suspend to ram and especially resume.
Hardware: Dell Latitude D810 (some Intel 915 with Intel Pentium M)

With 2.6.19.7 suspend to ram works reliable, but with 2.6.20-rc4 it stopped working reliable.

argh, that sounds like an ACPI regression.

Quoted 11 lines

I still can suspend, but after the first resume it goes back to sleep directly again, when resuming again it works.
After the second suspend it won't resume at all.

The problem is that i can't try out the kernel versions <rc4, because rc1, rc2 and rc3 doesn't boot at all, so git-bisect also won't help.

Has somebody an idea what i could try out?

(the distribution is in this case ubuntu feisty)

The fact that bisection broke really does make it hard. What you would need to do is to find the patch which fixed that doesn't-boot problem, then reapply it each time you perform an iteration. That's all doable, if you have the time. Use git-bisect for it.

Have you tested 2.6.21 and/or 2.6.22-rc1?

We had one other report earlier today that 2.6.22-rc1 does an immediate resume after suspend-to-RAM - perhaps that is related.

Of course the alternative way of debugging this is just to debug it, rather than the difficult bisecting. Perhaps an ACPI developer can help with that.

#2 lore raw
Quoted 3 lines · Andrew Morton
Quoted 3 lines

I still can suspend, but after the first resume it goes back to sleep directly again, when resuming again it works.
After the second suspend it won't resume at all.

I should add, that it goes from the suspend state to "on" and back to suspend, when i press power again it goes "on", but the screen stays black, but network doesn't work and most likely linux isn't running, because the laptop sucks max_power. (2.6.20-rc4)

Quoted 11 lines
Quoted 6 lines

The problem is that i can't try out the kernel versions <rc4, because rc1, rc2 and rc3 doesn't boot at all, so git-bisect also won't help.

Has somebody an idea what i could try out?

(the distribution is in this case ubuntu feisty)

The fact that bisection broke really does make it hard. What you would need to do is to find the patch which fixed that doesn't-boot problem, then reapply it each time you perform an iteration. That's all doable, if you have the time. Use git-bisect for it.

I'll try, unfortunatelly the problem is that PCI doesn't work with this versions.

Quoted 1 line

Have you tested 2.6.21 and/or 2.6.22-rc1?

I just have tried 2.6.22-rc2 and it's a bit different, I still have to resume 2 times and X does only work the "first" resume correctly, but it somewhat works.

Quoted 2 lines

We had one other report earlier today that 2.6.22-rc1 does an immediate resume after suspend-to-RAM - perhaps that is related.

no

Regards
Christian Leber

Signature · 1 line
http://rettetdieti.vde-uni-mannheim.de/
#3 lore raw
In reply to Christian Leber

Hi!

Quoted 8 lines

i hit a problem with suspend to ram and especially resume.
Hardware: Dell Latitude D810 (some Intel 915 with Intel Pentium M)

With 2.6.19.7 suspend to ram works reliable, but with 2.6.20-rc4 it stopped working reliable.
I still can suspend, but after the first resume it goes back to sleep directly again, when resuming again it works.
After the second suspend it won't resume at all.

Try with minimal modules. Try beeping patch to see if we reach linux on second resume.

Andrew: I have debugging hack that beeps the speaker as the first thing in acpi resume (real mode) routine. It provides some useful info. Maybe it is even worth including in mainline?
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

A message that is not in the archive (sent off-list or not yet received): 20070602182014.GB29546@core

#5 lore raw

beeping patch for debugging acpi sleep

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

arch/i386/kernel/acpi/wakeup.S +19 -1
index b781b38..cbf136e 100644
@@ -11,7 +11,22 @@ # Do we need to deal with A20? It is oka
 #
 # If physical address of wakeup_code is 0x12345, BIOS should call us with
 # cs = 0x1234, eip = 0x05
-# 
+#
+
+#define BEEP \
+	inb	$97, %al; 	\
+	outb	%al, $0x80; 	\
+	movb	$3, %al; 	\
+	outb	%al, $97; 	\
+	outb	%al, $0x80; 	\
+	movb	$-74, %al; 	\
+	outb	%al, $67; 	\
+	outb	%al, $0x80; 	\
+	movb	$-119, %al; 	\
+	outb	%al, $66; 	\
+	outb	%al, $0x80; 	\
+	movb	$15, %al; 	\
+	outb	%al, $66;
 
 ALIGN
 	.align	4096
@@ -20,6 +35,9 @@ wakeup_code:
 	wakeup_code_start = .
 	.code16
 
+# Uncomment this to make your computer start producing ugly noise as soon
+# as BIOS returns to this real-mode entry point.
+#	BEEP
  	movw	$0xb800, %ax
 	movw	%ax,%fs
 	movw	$0x0e00 + 'L', %fs:(0x10)
Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#6 lore raw

Re: beeping patch for debugging acpi sleep

Quoted 4 lines · Pavel Machek

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

I'd even go so far and implement it unconditionally.

MfG, JBG

Signature · 3 lines
      Jan-Benedict Glaw      [email protected]              +49-172-7608481
Signature of:                     Eine Freie Meinung in einem Freien Kopf
the second  :                   für einen Freien Staat voll Freier Bürger.
#7 lore raw

Re: beeping patch for debugging acpi sleep

Quoted 7 lines · Jan-Benedict Glaw
Quoted 4 lines · Pavel Machek

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

I'd even go so far and implement it unconditionally.

Well, try it; it is too annoying to be unconditional.
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#8 lore raw

Re: beeping patch for debugging acpi sleep

Hi.

Quoted 10 lines · Pavel Machek
Quoted 7 lines · Jan-Benedict Glaw
Quoted 4 lines · Pavel Machek

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

I'd even go so far and implement it unconditionally.

Well, try it; it is too annoying to be unconditional.

Could you modify the pitch or the length then, to make it less annoying? It sounds like a really good idea to me.

Regards,

Nigel

#9 lore raw

Re: beeping patch for debugging acpi sleep

Quoted 10 lines · Nigel Cunningham

Hi.

Quoted 7 lines · Pavel Machek
Quoted 6 lines · Jan-Benedict Glaw
Quoted 4 lines · Pavel Machek

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

Quoted 6 lines
Quoted 3 lines
Quoted 1 line

I'd even go so far and implement it unconditionally.

Well, try it; it is too annoying to be unconditional.

Could you modify the pitch or the length then, to make it less annoying? It sounds like a really good idea to me.

Modifying length is non-trivial, AFAICT, but feel free to submit a patch...

Actually, *any* tone will be annoying in quiet room, and kernel should not really be making sounds on its own, so scratch that idea.

Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#10 lore raw

Re: beeping patch for debugging acpi sleep

In reply to Pavel Machek

On Sat, Jun 09, 2007 at 03:08:17PM +0200, Pavel Machek wrote:

How about (WARNING! I never have written i386 assembly, my last assembly experience was 20 years ago on Z80, so this is basically just copy'n paste, but i hope you get the idea):

arch/i386/kernel/acpi/wakeup.S wakeup_code: · line 39

Quoted 9 lines
arch/i386/kernel/acpi/wakeup.S +2 -0
@@ -20,6 +35,9 @@ wakeup_code:
 	wakeup_code_start = .
 	.code16
 
+# Uncomment this to make your computer start producing ugly noise as soon
+# as BIOS returns to this real-mode entry point.

testl $4, video_flags - wakeup_code
jz 1f

arch/i386/kernel/acpi/wakeup.S wakeup_code: · line 40

Quoted 1 line
arch/i386/kernel/acpi/wakeup.S +1 -0
+	BEEP

1:

arch/i386/kernel/acpi/wakeup.S wakeup_code: · line 43

Quoted 3 lines
arch/i386/kernel/acpi/wakeup.S +0 -0
  	movw	$0xb800, %ax
 	movw	%ax,%fs
 	movw	$0x0e00 + 'L', %fs:(0x10)

IIUC, then this should make "echo 4 > /proc/sys/kernel/acpi_video_flags" enable the beep at run-time.

Yes, i know, it is not a video flag. And not ACPI. Just add another sysctl if you care.

Signature · 6 lines
Stefan Seyfried
QA / R&D Team Mobile Devices        |              "Any ideas, John?"
SUSE LINUX Products GmbH, Nürnberg  | "Well, surrounding them's out." 

This footer brought to you by insane German lawmakers:
SUSE Linux Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
#11 lore raw

Re: beeping patch for debugging acpi sleep

Hi!

Quoted 3 lines

How about (WARNING! I never have written i386 assembly, my last assembly experience was 20 years ago on Z80, so this is basically just copy'n paste, but i hope you get the idea):

We probably can do that, if there's big enough demand.

Quoted 7 lines
Quoted 7 lines
arch/i386/kernel/acpi/wakeup.S +0 -0
@@ -20,6 +35,9 @@ wakeup_code:
 	wakeup_code_start = .
 	.code16
 
Quoted 7 lines

arch/i386/kernel/acpi/wakeup.S wakeup_code: · line 39

Quoted 2 lines
arch/i386/kernel/acpi/wakeup.S +2 -0
+# Uncomment this to make your computer start producing ugly noise as soon
+# as BIOS returns to this real-mode entry point.

testl $4, video_flags - wakeup_code
jz 1f

arch/i386/kernel/acpi/wakeup.S wakeup_code: · line 40

Quoted 1 line
arch/i386/kernel/acpi/wakeup.S +1 -0
+	BEEP

1:

Heh, I'd say you learn quickly :-). But for now, I'd like to have basic patch in, and as reliable as possible.
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#12 lore raw

Re: beeping patch for debugging acpi sleep

In reply to Pavel Machek
Quoted 37 lines · On Sat, 9 Jun 2007 15:08:17 +0200 Pavel Machek <[email protected]> wrote:

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

arch/i386/kernel/acpi/wakeup.S +16 -1
index b781b38..cbf136e 100644
@@ -11,7 +11,22 @@ # Do we need to deal with A20? It is oka
 #
 # If physical address of wakeup_code is 0x12345, BIOS should call us with
 # cs = 0x1234, eip = 0x05
-# 
+#
+
+#define BEEP \
+	inb	$97, %al; 	\
+	outb	%al, $0x80; 	\
+	movb	$3, %al; 	\
+	outb	%al, $97; 	\
+	outb	%al, $0x80; 	\
+	movb	$-74, %al; 	\
+	outb	%al, $67; 	\
+	outb	%al, $0x80; 	\
+	movb	$-119, %al; 	\
+	outb	%al, $66; 	\
+	outb	%al, $0x80; 	\
+	movb	$15, %al; 	\
+	outb	%al, $66;
 
 ALIGN
 	.align	4096

arch/i386/kernel/acpi/wakeup.S wakeup_code: · line 43

Quoted 9 lines
arch/i386/kernel/acpi/wakeup.S +3 -0
@@ -20,6 +35,9 @@ wakeup_code:
 	wakeup_code_start = .
 	.code16
 
+# Uncomment this to make your computer start producing ugly noise as soon
+# as BIOS returns to this real-mode entry point.
+#	BEEP
  	movw	$0xb800, %ax
 	movw	%ax,%fs
 	movw	$0x0e00 + 'L', %fs:(0x10)

How does the beep get turned off again?

Should the BEEP line be uncommented (in -mm at least)?

#13 lore raw

Re: beeping patch for debugging acpi sleep

Hi,

Quoted 6 lines · Andrew Morton

On Sat, 9 Jun 2007 15:08:17 +0200
Pavel Machek <[email protected]> wrote:

How does the beep get turned off again?

May be it is turn off by the speaker driver.

BTW can't we do something with led ? This way it can be always enabled without anoying people

Matthieu

#14 lore raw

Re: beeping patch for debugging acpi sleep

Hi!

(please group reply)

Quoted 6 lines
Quoted 1 line

How does the beep get turned off again?

May be it is turn off by the speaker driver.

BTW can't we do something with led ? This way it can be always enabled without anoying people

It would be more complex code, afaict, and ps/2 keyboard may be absent. But feel free to try, I'm not even sure beeping works everywhere, so another hack would be nice...

Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#15 lore raw

Re: beeping patch for debugging acpi sleep

Quoted 8 lines · Pavel Machek

Hi!

(please group reply)

Quoted 4 lines
Quoted 1 line

How does the beep get turned off again?

May be it is turn off by the speaker driver.

Quoted 6 lines
Quoted 2 lines

BTW can't we do something with led ? This way it can be always enabled without anoying people

It would be more complex code, afaict, and ps/2 keyboard may be absent. But feel free to try, I'm not even sure beeping works everywhere, so another hack would be nice...

Many machines / keyboards blink the LEDs on power up and on resume anyway, so it is hard to see if the blink was from the BIOS or from Linux. And don't we need to resume the keyboard controller before we can start blinking the LEDs?

Signature · 6 lines
Stefan Seyfried
QA / R&D Team Mobile Devices        |              "Any ideas, John?"
SUSE LINUX Products GmbH, Nürnberg  | "Well, surrounding them's out." 

This footer brought to you by insane German lawmakers:
SUSE Linux Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
#16 lore raw

Re: beeping patch for debugging acpi sleep

In reply to Andrew Morton

Hi!

Quoted 38 lines
Quoted 38 lines

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

arch/i386/kernel/acpi/wakeup.S +16 -1
index b781b38..cbf136e 100644
@@ -11,7 +11,22 @@ # Do we need to deal with A20? It is oka
 #
 # If physical address of wakeup_code is 0x12345, BIOS should call us with
 # cs = 0x1234, eip = 0x05
-# 
+#
+
+#define BEEP \
+	inb	$97, %al; 	\
+	outb	%al, $0x80; 	\
+	movb	$3, %al; 	\
+	outb	%al, $97; 	\
+	outb	%al, $0x80; 	\
+	movb	$-74, %al; 	\
+	outb	%al, $67; 	\
+	outb	%al, $0x80; 	\
+	movb	$-119, %al; 	\
+	outb	%al, $66; 	\
+	outb	%al, $0x80; 	\
+	movb	$15, %al; 	\
+	outb	%al, $66;
 
 ALIGN
 	.align	4096
@@ -20,6 +35,9 @@ wakeup_code:
 	wakeup_code_start = .
 	.code16
 
Quoted 9 lines

arch/i386/kernel/acpi/wakeup.S wakeup_code: · line 43

Quoted 7 lines
arch/i386/kernel/acpi/wakeup.S +3 -0
+# Uncomment this to make your computer start producing ugly noise as soon
+# as BIOS returns to this real-mode entry point.
+#	BEEP
  	movw	$0xb800, %ax
 	movw	%ax,%fs
 	movw	$0x0e00 + 'L', %fs:(0x10)

How does the beep get turned off again?

Typically, pcmcia beeps after resume, making it quiet. If not, echo ^G does it.

Quoted 1 line

Should the BEEP line be uncommented (in -mm at least)?

It's too gross a hack, I'd say. It is only ever useful if machine is completely dead after s2ram.
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#17 lore raw

Re: beeping patch for debugging acpi sleep

In reply to Andrew Morton

Hi.

Wouldn't it be much more useful if it was unconditionally compiled in and controlled instead by a sysfs entry? That way it will be far more useful to $user who doesn't know or want to know how to compile and install a kernel, but wants to do what they can to get provide helpful debugging info and perhaps even get it going.

Yes, Pavel, I'll supply a patch if you (plural) agree.

Regards,

Nigel

#18 lore raw

Re: beeping patch for debugging acpi sleep

Hi,

Quoted 7 lines · Nigel Cunningham

Hi.

Wouldn't it be much more useful if it was unconditionally compiled in and controlled instead by a sysfs entry? That way it will be far more useful to $user who doesn't know or want to know how to compile and install a kernel, but wants to do what they can to get provide helpful debugging info and perhaps even get it going.

I like this idea.

Quoted 1 line

Yes, Pavel, I'll supply a patch if you (plural) agree.

I agree. :-)

Greetings,
Rafael

Signature · 1 line
"Premature optimization is the root of all evil." - Donald Knuth
#19 lore raw

Re: beeping patch for debugging acpi sleep

Hi.

Quoted 11 lines · Rafael J. Wysocki

Hi,

Quoted 7 lines · Nigel Cunningham

Hi.

Wouldn't it be much more useful if it was unconditionally compiled in and controlled instead by a sysfs entry? That way it will be far more useful to $user who doesn't know or want to know how to compile and install a kernel, but wants to do what they can to get provide helpful debugging info and perhaps even get it going.

Quoted 5 lines

I like this idea.

Quoted 1 line

Yes, Pavel, I'll supply a patch if you (plural) agree.

I agree. :-)

Ok. I'll take Pavel's silence as agreement too. I'll be a little slow (as usual, nowadays!), but will try to get it done next week. I think I can in clear conscience do it on Redhat time if I don't manage it beforehand.

Regards,

Nigel

#20 lore raw

Re: beeping patch for debugging acpi sleep

Hi!

Quoted 8 lines
Quoted 8 lines
Quoted 5 lines

Wouldn't it be much more useful if it was unconditionally compiled in and controlled instead by a sysfs entry? That way it will be far more useful to $user who doesn't know or want to know how to compile and install a kernel, but wants to do what they can to get provide helpful debugging info and perhaps even get it going.

I like this idea.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line

Yes, Pavel, I'll supply a patch if you (plural) agree.

I agree. :-)

Ok. I'll take Pavel's silence as agreement too. I'll be a little slow (as usual, nowadays!), but will try to get it done next week. I think I can in clear conscience do it on Redhat time if I don't manage it beforehand.

Well, everyone wants it so what can I do... Stefan basically posted 3 liner to do that, and that one will probably work... so just test it.

Oh, and please keep the macro, so it can be moved around .S file for finding out where it crashes.
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#21 lore raw

Re: beeping patch for debugging acpi sleep

Hi.

Quoted 14 lines · Pavel Machek

Hi!

Quoted 12 lines
Quoted 11 lines
Quoted 5 lines

Wouldn't it be much more useful if it was unconditionally compiled in and controlled instead by a sysfs entry? That way it will be far more useful to $user who doesn't know or want to know how to compile and install a kernel, but wants to do what they can to get provide helpful debugging info and perhaps even get it going.

I like this idea.

Quoted 1 line

Yes, Pavel, I'll supply a patch if you (plural) agree.

I agree. :-)

Quoted 7 lines
Quoted 4 lines

Ok. I'll take Pavel's silence as agreement too. I'll be a little slow (as usual, nowadays!), but will try to get it done next week. I think I can in clear conscience do it on Redhat time if I don't manage it beforehand.

Well, everyone wants it so what can I do... Stefan basically posted 3 liner to do that, and that one will probably work... so just test it.

As he admitted, it's a quick and dirty hack. I'd like to try something nicer.

Quoted 2 lines

Oh, and please keep the macro, so it can be moved around .S file for finding out where it crashes.

Are there other points you'd like to nominate? It would defeat the logic for implementing a nice interface if you still have to recompile your kernel to test beeping in another place.

Regards,

Nigel

#22 lore raw

Re: beeping patch for debugging acpi sleep

Hi!

Quoted 10 lines
Quoted 7 lines
Quoted 4 lines

Ok. I'll take Pavel's silence as agreement too. I'll be a little slow (as usual, nowadays!), but will try to get it done next week. I think I can in clear conscience do it on Redhat time if I don't manage it beforehand.

Well, everyone wants it so what can I do... Stefan basically posted 3 liner to do that, and that one will probably work... so just test it.

As he admitted, it's a quick and dirty hack. I'd like to try something nicer.

Well, his hack + rename one variable and there's one very nice solution.

Quoted 6 lines
Quoted 2 lines

Oh, and please keep the macro, so it can be moved around .S file for finding out where it crashes.

Are there other points you'd like to nominate? It would defeat the logic for implementing a nice interface if you still have to recompile your kernel to test beeping in another place.

Just before entering C would be another interesting point.
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#23 lore raw

Re: beeping patch for debugging acpi sleep

Quoted 15 lines · Pavel Machek

Hi!

Quoted 10 lines
Quoted 7 lines
Quoted 4 lines

Ok. I'll take Pavel's silence as agreement too. I'll be a little slow (as usual, nowadays!), but will try to get it done next week. I think I can in clear conscience do it on Redhat time if I don't manage it beforehand.

Well, everyone wants it so what can I do... Stefan basically posted 3 liner to do that, and that one will probably work... so just test it.

As he admitted, it's a quick and dirty hack. I'd like to try something nicer.

Well, his hack + rename one variable and there's one very nice solution.

Quoted 8 lines
Quoted 6 lines
Quoted 2 lines

Oh, and please keep the macro, so it can be moved around .S file for finding out where it crashes.

Are there other points you'd like to nominate? It would defeat the logic for implementing a nice interface if you still have to recompile your kernel to test beeping in another place.

Just before entering C would be another interesting point.

Well, x86_64 version would be nice to have too. ;-)

Greetings,
Rafael

Signature · 1 line
"Premature optimization is the root of all evil." - Donald Knuth
#24 lore raw

Re: beeping patch for debugging acpi sleep

In reply to Pavel Machek
Quoted 3 lines · Pavel Machek

Starting beeper as soon as ACPI sleep returns is very useful in debugging "apparently dead" machines. If it beeps at all, it makes sense to start playing with CMOS tracer.

thank you very much Pavel

The results are a bit unclear, I took a 2.6.22-rc4 with beep. Logged into KDE.
(hardware: Dell Latitude D810)

S = successfull resume
D = had to resume 2 times, that means when pressing the power button the LED goes from blinking to on and after a few seconds it goes back to blinking, but without a beep in between; after pressing the power button a second time resume is successfull
F = resume failes, NO beep

-run 1: D D F
-run 2: D D D(some X garbadge) F
-run 3: S S S S S S F
-run 4: S S F
-run 5: D F

Very odd, nothing was changed in between and after each F i switched it off... because it was dead.

With 2.6.19.7 i have never seen it fail.

Christian Leber

Signature · 1 line
http://rettetdieti.vde-uni-mannheim.de/
#25 lore raw

Re: beeping patch for debugging acpi sleep

Quoted 11 lines · Christian Leber

The results are a bit unclear, I took a 2.6.22-rc4 with beep. Logged into KDE.
(hardware: Dell Latitude D810)

S = successfull resume
D = had to resume 2 times, that means when pressing the power button the LED goes from blinking to on and after a few seconds it goes back to blinking, but without a beep in between; after pressing the power button a second time resume is successfull
F = resume failes, NO beep

Review

Quoted 5 lines
(quoted diff) +0 -5
-run 1: D D F
-run 2: D D D(some X garbadge) F
-run 3: S S S S S S F
-run 4: S S F
-run 5: D F

I tracked the problem halfway down, with 2.6.20-rc1-ubuntu1 [1] it works and with 2.6.20-rc2-ubuntu2 [2] not.

The diff is here, unfortunately the acpi changes are about 100kb.
http://debian.christian-leber.de/2.2-3.4.patch

(the problem is a bit different, it suspends, when trying to resume it goes back to suspend and when i try again it's dead)

For some reason that i don't get vanilla 2.6.20-rc1 doesn't boot because ata_piix doesn't work "PCI: Unable to reserve I/O region...." no remote idea why it works with the ubuntu kernel.
So i can't bisect it.

Christian Leber

[1] https://launchpad.net/ubuntu/+source/linux-source-2.6.20/2.6.20-2.2
[2] https://launchpad.net/ubuntu/+source/linux-source-2.6.20/2.6.20-3.4

Signature · 1 line
http://rettetdieti.vde-uni-mannheim.de/
#26 lore raw

Re: beeping patch for debugging acpi sleep

Hi!

Quoted 20 lines
Quoted 11 lines

The results are a bit unclear, I took a 2.6.22-rc4 with beep. Logged into KDE.
(hardware: Dell Latitude D810)

S = successfull resume
D = had to resume 2 times, that means when pressing the power button the LED goes from blinking to on and after a few seconds it goes back to blinking, but without a beep in between; after pressing the power button a second time resume is successfull
F = resume failes, NO beep

Review

Quoted 5 lines
(quoted diff) +0 -5
-run 1: D D F
-run 2: D D D(some X garbadge) F
-run 3: S S S S S S F
-run 4: S S F
-run 5: D F

I tracked the problem halfway down, with 2.6.20-rc1-ubuntu1 [1] it works and with 2.6.20-rc2-ubuntu2 [2] not.

Quoted 5 lines

The diff is here, unfortunately the acpi changes are about 100kb.
http://debian.christian-leber.de/2.2-3.4.patch

(the problem is a bit different, it suspends, when trying to resume it goes back to suspend and when i try again it's dead)

It may well be different problem :-(. 100KB diff and I'm not an acpi expert :-(.

I just discovered I have problems with s2ram, too, but it looks like usermodehelper is responsible.

Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#27 lore raw

Re: beeping patch for debugging acpi sleep

Quoted 16 lines · Pavel Machek
Quoted 16 lines
Quoted 16 lines

The results are a bit unclear, I took a 2.6.22-rc4 with beep. Logged into KDE.
(hardware: Dell Latitude D810)

S = successfull resume
D = had to resume 2 times, that means when pressing the power button the LED goes from blinking to on and after a few seconds it goes back to blinking, but without a beep in between; after pressing the power button a second time resume is successfull
F = resume failes, NO beep

(quoted diff) +0 -5
-run 1: D D F
-run 2: D D D(some X garbadge) F
-run 3: S S S S S S F
-run 4: S S F
-run 5: D F

[..]

Quoted 5 lines

It may well be different problem :-(. 100KB diff and I'm not an acpi expert :-(.

I just discovered I have problems with s2ram, too, but it looks like usermodehelper is responsible.

Now i think it is a userspace problem, more exactly something in KDE.

I got a new laptop(a Dell D830) and
discovered that suspend works with gnome and when i directly run /etc/acpi/sleep.sh. (with KDE running, from a xterm... but so somehow it can't interact with the KDE userspace stuff) (i have no remote idea what KDE is doing)

So i tried sleep.sh also on my old laptop (D810) once again and it works reliable, well at least for 13 times.

Directly afterwards i tried the suspend to ram button again and it failed again as stated above.

Can someone else with suspend problems and KDE verify this?

i filled a bug against KDE in ubuntu:
https://bugs.launchpad.net/ubuntu/+source/kubuntu-meta/+bug/131855

Christian Leber

Signature · 2 lines
You are searching some interesting studies?
http://www.ziti.uni-heidelberg.de/   :-)
#28 lore raw
In reply to Christian Leber
Quoted 11 lines · Christian Leber

Hello,

i hit a problem with suspend to ram and especially resume.
Hardware: Dell Latitude D810 (some Intel 915 with Intel Pentium M)

With 2.6.19.7 suspend to ram works reliable, but with 2.6.20-rc4 it stopped working reliable.
I still can suspend, but after the first resume it goes back to sleep directly again, when resuming again it works.
After the second suspend it won't resume at all.

Quoted 6 lines

The problem is that i can't try out the kernel versions <rc4, because rc1, rc2 and rc3 doesn't boot at all, so git-bisect also won't help.

Has somebody an idea what i could try out?

(the distribution is in this case ubuntu feisty)

I had that problem here with Feisty on a Dell i9300 (and on a Dell i9400). We fixed it by replacing the /etc/acpi/* scripts with my own script.

-ml