Skip to contentSkip to conversation

S3 freezes on wake on NC6000 laptop

DISCUSSION Lorenzo Colitti 6 participants 15 messages Feb 7, 2005 – Feb 8, 2005 9 messages not in the archive ACPI

lore
Share & tools
lore
#0 lore raw

Hi,

I am trying to get S3 (suspend to RAM) to work on an HP NC6000 laptop with no success. The system seems to enter the S3 state correctly, but when I turn back on it freezes completely.

I tried booting with no modules and no processes loaded (init=/bin/sh) and with a serial console, but I can't see anything helpful. What I see is this:

Quoted 11 lines

kjournald starting. Commit interval 5 seconds
sh-3.00# mount -t proc proc /proc
sh-3.00# mount -t sysfs sys /sys
sh-3.00# echo C057 > /proc/acpi/wakeup
sh-3.00# cat /proc/acpi/wakeup
Device Sleep state Status
C057 5 enabled
sh-3.00# echo mem > /sys/power/state
radeonfb (0000:01:00.0): suspending to state: 2...
PM: Entering state.
hwsleep-0307 [04] acpi_enter_sleep_state: Entering sleep state [S3]

After that, it seems that the system goes to sleep. There is nothing on the screen, the HD stops, and the power light starts blinking.

However, when I turn the machine back on it freezes completely. The HD starts, the power light comes on, but the serial console is unresponsive, the keyboard doesn't seem to work, and it won't turn off again, even if I hold the power button for 5 seconds.

I am using a vanilla 2.6.11-rc3 kernel with the swsusp2 patch. Is there anything I can do to help debug this? I have acpi debugging compiled into the kernel, but I don't know how to use it.

Any info would be appreciated!

Cheers,
Lorenzo

-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl

#2 lore raw
In reply to a message not in the archive

Hi,

Quoted 19 lines · Lorenzo Colitti

Hi,

I am trying to get S3 (suspend to RAM) to work on an HP NC6000 laptop with no success. The system seems to enter the S3 state correctly, but when I turn back on it freezes completely.

I tried booting with no modules and no processes loaded (init=/bin/sh) and with a serial console, but I can't see anything helpful. What I see is this:

Quoted 9 lines

kjournald starting. Commit interval 5 seconds sh-3.00# mount -t proc proc /proc
sh-3.00# mount -t sysfs sys /sys
sh-3.00# echo C057 > /proc/acpi/wakeup sh-3.00# cat /proc/acpi/wakeup
Device Sleep state Status
C057 5 enabled
sh-3.00# echo mem > /sys/power/state radeonfb (0000:01:00.0): suspending to state: 2...

Ah, radeonfb. Please don't use radeonfb if you want to have any chance in resuming. Don't use any framebuffer on systems with radeon cards. It will freeze your machine completely. Actually, any graphics activity (framebuffer or X or svga access) will freeze it.

Without framebuffer, your machine will come back from sleep, but you won't get any video. We're currently busy to write code which will help radeon users (I'm one of them).

Quoted 11 lines
Quoted 2 lines

PM: Entering state.
hwsleep-0307 [04] acpi_enter_sleep_state: Entering sleep state [S3]

After that, it seems that the system goes to sleep. There is nothing on the screen, the HD stops, and the power light starts blinking.

However, when I turn the machine back on it freezes completely. The HD starts, the power light comes on, but the serial console is unresponsive, the keyboard doesn't seem to work, and it won't turn off again, even if I hold the power button for 5 seconds.

Regards,
Carl-Daniel

Signature · 8 lines
http://www.hailfinger.org/


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
#4 lore raw
In reply to a message not in the archive

Thus wrote Carl-Daniel Hailfinger:

Quoted 4 lines

Ah, radeonfb. Please don't use radeonfb if you want to have any chance in resuming. Don't use any framebuffer on systems with radeon cards. It will freeze your machine completely. Actually, any graphics activity (framebuffer or X or svga access) will freeze it.

That's sort of incorrect, I've used radeonfb since late 2.5.X builds and I don't remember it causing any problems resuming (of course, I need acpi_sleep=s3_bios, but that's another thing). Radeonfb will resume just fine, provided the underlying hardware is in a sane state. Granted, it may cause freezes, but it's definitely not so that removing it will magically cause your video to work or that it does always hang the machine. Best regards,

Signature · 9 lines
Karol 'sziwan' Kozimor
sziwan-DETuoxkZsSqrDJvtcaxF/[email protected]


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
#6 lore raw
In reply to a message not in the archive
Quoted 6 lines · Karol Kozimor

That's sort of incorrect, I've used radeonfb since late 2.5.X builds and I don't remember it causing any problems resuming (of course, I need acpi_sleep=s3_bios, but that's another thing). Radeonfb will resume just fine, provided the underlying hardware is in a sane state. Granted, it may cause freezes, but it's definitely not so that removing it will magically cause your video to work or that it does always hang the machine.

Do you have to press a key on resume to be able to come back?

Thats one of my major problems with ole's patch to get video back with radeonfb when s3_bios does not work.

Regards,
Stefan

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#9 lore raw
In reply to a message not in the archive

Hi!

Quoted 7 lines

I am trying to get S3 (suspend to RAM) to work on an HP NC6000 laptop with no success. The system seems to enter the S3 state correctly, but when I turn back on it freezes completely.

I tried booting with no modules and no processes loaded (init=/bin/sh) and with a serial console, but I can't see anything helpful. What I see is this:

Drop radeonfb, and drop swsusp2 patch. Apply this, and lets see if you can hear beep during wakeup.
Pavel

arch/i386/kernel/acpi/wakeup.S +17 -1
@@ -11,7 +11,22 @@
 #
 # 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,7 @@
 	wakeup_code_start = .
 	.code16
 
+	BEEP
  	movw	$0xb800, %ax
 	movw	%ax,%fs
 	movw	$0x0e00 + 'L', %fs:(0x10)
Signature · 9 lines
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
#11 lore raw
In reply to a message not in the archive

Hi.

Suspend2 doesn't touch wakeup.S; he should be able to test without reversing it if he wants to.

Regards,

Nigel

Quoted 48 lines · Pavel Machek

Hi!

Quoted 7 lines

I am trying to get S3 (suspend to RAM) to work on an HP NC6000 laptop with no success. The system seems to enter the S3 state correctly, but when I turn back on it freezes completely.

I tried booting with no modules and no processes loaded (init=/bin/sh) and with a serial console, but I can't see anything helpful. What I see is this:

Drop radeonfb, and drop swsusp2 patch. Apply this, and lets see if you can hear beep during wakeup.
Pavel

arch/i386/kernel/acpi/wakeup.S +17 -1
@@ -11,7 +11,22 @@
 #
 # 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,7 @@
 	wakeup_code_start = .
 	.code16
 
+	BEEP
  	movw	$0xb800, %ax
 	movw	%ax,%fs
 	movw	$0x0e00 + 'L', %fs:(0x10)
Signature · 13 lines
Nigel Cunningham
Software Engineer, Canberra, Australia
http://www.cyclades.com

Ph: +61 (2) 6292 8028      Mob: +61 (417) 100 574



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
#12 lore raw
In reply to a message not in the archive
Quoted 4 lines · Pavel Machek
Quoted 2 lines

I tried booting with no modules and no processes loaded (init=/bin/sh) and with a serial console, but I can't see anything helpful. What I see is this:

Drop radeonfb, and drop swsusp2 patch.

Done: the machine wakes up. Video does not work, but pressing caps lock toggles the led and typing "find /" starts the hard disk grinding. If I pass acpi_sleep=s3_bios on the command line, even video works.

Summary:

- radeonfb on its own freezes the machine on wakeup
- swsusp2 on its own also freezes on wakeup (but even worse:
you can't even power off by holding the power button)
- With no radeonfb and no swsusp2, the machine wakes up
- If I also use acpi_sleep=s3_bios, the machine wakes up, and I get video too

Quoted 1 line

Apply this, and lets see if you can hear beep during wakeup.

I didn't apply it because things already seemed to be working without it (using acpi_sleep=s3_bios I get video, without it I don't but the machine wakes up all the same). Do you want me to test with the patch as well? What do I need to do?

Cheers,
Lorenzo

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#23 lore raw
In reply to a message not in the archive
Quoted 1 line · Pavel Machek

Apply this, and lets see if you can hear beep during wakeup.

Doh! I just realized that the only function of the patch is to give a beep on startup. Please ignore my "should I test this patch anyway" question. :)

Cheers,
Lorenzo

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#14 lore raw
In reply to a message not in the archive

Hi.

Quoted 4 lines · Lorenzo Colitti

Done: the machine wakes up. Video does not work, but pressing caps lock toggles the led and typing "find /" starts the hard disk grinding. If I pass acpi_sleep=s3_bios on the command line, even video works.

Quoted 9 lines

Summary:

- radeonfb on its own freezes the machine on wakeup
- swsusp2 on its own also freezes on wakeup (but even worse:
you can't even power off by holding the power button)
- With no radeonfb and no swsusp2, the machine wakes up
- If I also use acpi_sleep=s3_bios, the machine wakes up, and I get video too

If that's the case, something is broken in Suspend2. Can you confirm that please by removing Radeon but adding Suspend2?

Nigel

Signature · 13 lines
Nigel Cunningham
Software Engineer, Canberra, Australia
http://www.cyclades.com

Ph: +61 (2) 6292 8028      Mob: +61 (417) 100 574



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
#16 lore raw
In reply to a message not in the archive
Quoted 5 lines · Nigel Cunningham
Quoted 2 lines

- swsusp2 on its own also freezes on wakeup (but even worse:
you can't even power off by holding the power button)

If that's the case, something is broken in Suspend2. Can you confirm that please by removing Radeon but adding Suspend2?

Actually it's not swsusp2's fault. The working kernel has a rather stripped-down config, and the non-working kernel has a much more complicated configuration. If I add swsusp2 to the stripped-down kernel, S3 sleep still works.

I'm currently trying to find out what it is wrong in the other .config that breaks S3; I suspect preemption, but I'm not sure yet.

Cheers,
Lorenzo

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#18 lore raw
In reply to a message not in the archive

Hi.

Quoted 11 lines · Lorenzo Colitti
Quoted 5 lines · Nigel Cunningham
Quoted 2 lines

- swsusp2 on its own also freezes on wakeup (but even worse:
you can't even power off by holding the power button)

If that's the case, something is broken in Suspend2. Can you confirm that please by removing Radeon but adding Suspend2?

Actually it's not swsusp2's fault. The working kernel has a rather stripped-down config, and the non-working kernel has a much more complicated configuration. If I add swsusp2 to the stripped-down kernel, S3 sleep still works.

Okay. From my perspective, that's good :>

Regards,

Nigel

Signature · 13 lines
Nigel Cunningham
Software Engineer, Canberra, Australia
http://www.cyclades.com

Ph: +61 (2) 6292 8028      Mob: +61 (417) 100 574



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
#8 lore raw
In reply to a message not in the archive

Thus wrote Stefan Schweizer:

Quoted 11 lines
Quoted 6 lines

That's sort of incorrect, I've used radeonfb since late 2.5.X builds and I don't remember it causing any problems resuming (of course, I need acpi_sleep=s3_bios, but that's another thing). Radeonfb will resume just fine, provided the underlying hardware is in a sane state. Granted, it may cause freezes, but it's definitely not so that removing it will magically cause your video to work or that it does always hang the machine.

Do you have to press a key on resume to be able to come back?

Thats one of my major problems with ole's patch to get video back with radeonfb when s3_bios does not work.

I don't really understand. I resume the usual way, by pressing a random key or the power button. No additional presses needed.
Best regards,

Signature · 9 lines
Karol 'sziwan' Kozimor
sziwan-DETuoxkZsSqrDJvtcaxF/[email protected]


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
#19 lore raw
In reply to a message not in the archive

Thus wrote Lorenzo Colitti:

Quoted 1 line

- radeonfb on its own freezes the machine on wakeup

Is it modular? Try building into the kernel if so. Best regards,

Signature · 9 lines
Karol 'sziwan' Kozimor
sziwan-DETuoxkZsSqrDJvtcaxF/[email protected]


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
#21 lore raw
In reply to a message not in the archive
Quoted 3 lines · Karol Kozimor
Quoted 1 line

- radeonfb on its own freezes the machine on wakeup

Is it modular? Try building into the kernel if so.

Actually, it was builtin.
I think I tried it as a module too and it crashed in the same way...

Cheers,
Lorenzo

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#22 lore raw
In reply to a message not in the archive

Hi!

Quoted 6 lines
Quoted 1 line

Apply this, and lets see if you can hear beep during wakeup.

I didn't apply it because things already seemed to be working without it (using acpi_sleep=s3_bios I get video, without it I don't but the machine wakes up all the same). Do you want me to test with the patch as well? What do I need to do?

Ignore the patch; it works for you -- no need add beeps.
Pavel

Signature · 9 lines
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click