Bug 4020 - Reboot no longer works after suspend
Summary: Reboot no longer works after suspend
Status: REJECTED DUPLICATE of bug 6655
Alias: None
Product: ACPI
Classification: Unclassified
Component: Power-Sleep-Wake (show other bugs)
Hardware: i386 Linux
: P2 normal
Assignee: Shaohua
Depends on:
Reported: 2005-01-11 04:26 UTC by Pedro C
Modified: 2006-06-12 00:10 UTC (History)
1 user (show)

See Also:
Kernel Version: 2.6.10-ac8
Regression: ---
Bisected commit-id:


Description Pedro C 2005-01-11 04:26:52 UTC
Distribution: Debian Sid
Hardware Environment: Asus M2400N Centrino laptop
Software Environment: Any kernel capable of suspending and resuming (>= 2.6.9)
Problem Description:

After one cycle of S3 sleep-wake, if I reboot the machine it won't actually
reboot when it finishes shutting down. If I haven't suspended the machine reboot
works fine. This has been like this since I got suspend-resume working in 2.6.9.

Steps to reproduce:

1. Boot kernel
2. Go to S3 suspend
3. Return from S3 suspend
4. Reboot
Comment 1 Shaohua 2005-01-11 17:09:13 UTC
Is there any message in the screen when reboot?
Comment 2 Pedro C 2005-01-12 03:42:06 UTC
The system shuts down normally and the last message says it is going to reboot.
It just doesn't.
Comment 3 Venkatesh Pallipadi 2005-01-12 18:40:28 UTC
can you try rebooting multiple times without S3. And check whether it works 
Comment 4 Pedro C 2005-01-14 11:12:31 UTC
It had always worked fine before S3, with every kernel. And when I don't do S3 I
don't remember any time it didn't work. If you need an actual extensive test,
I'll  do it.
Comment 5 Pedro C 2005-01-17 05:46:39 UTC
By the way, this is the log of a suspend-resume cycle:

PM: Preparing system for suspend
Stopping tasks:
PM: Entering state.
Back to C!
Warning: CPU frequency is 1300000, cpufreq assumed 600000 kHz.
PM: Finishing up.
ACPI: PCI interrupt 0000:00:02.0[A] -> GSI 5 (level, low) -> IRQ 5
PCI: Setting latency timer of device 0000:00:1d.0 to 64
PCI: Setting latency timer of device 0000:00:1d.1 to 64
PCI: Setting latency timer of device 0000:00:1d.2 to 64
ACPI: PCI interrupt 0000:00:1f.1[A] -> GSI 5 (level, low) -> IRQ 5
ACPI: PCI interrupt 0000:00:1f.5[B] -> GSI 4 (level, low) -> IRQ 4
PCI: Setting latency timer of device 0000:00:1f.5 to 64
MCE: The hardware reports a non fatal, correctable incident occurred on CPU 0.
Bank 1: f200000000000115
ACPI: PCI interrupt 0000:01:03.2[C] -> GSI 5 (level, low) -> IRQ 5
eth0: link down
ipw2100: eth1: ipw2100_verify failed: -5
ipw2100: eth1: Failed to power on the adapter.
ipw2100: eth1: Failed to start the firmware.
eth0: link up, 100Mbps, full-duplex, lpa 0x45E1
Restarting tasks... done

If I have PCMCIA on it will give some warnings about socket power. But I don't
Comment 6 Shaohua 2005-01-17 17:51:05 UTC
So you actually look at 'Restarting system.' on the screen, right?
Did deleting the line of 'lapic_shutdown' in machine_restart 
(i386/kernel/reboot.c) help?
Comment 7 Pedro C 2005-03-13 16:47:52 UTC
2.6.11 still has this bug.

'Restarting system.' shows up on the screen, but the system doesn't actually reboot.

Could you send me a patch for that lapic_shutdown change if you still want me to
test that?
Comment 8 Shaohua 2005-08-25 00:05:35 UTC
Could we have an update with latest kernel on the system? Thanks!
Comment 9 Pedro C 2005-08-28 15:25:11 UTC
2.6.12 still has the problem.
Comment 10 Shaohua 2005-08-28 18:36:17 UTC
Does keyboard work after resume?
can you try boot option 'reboot=bc'?
Comment 11 Pedro C 2005-09-02 10:08:39 UTC
2.6.13 shows the same problem. The keyboard as well as everything else except
IrDA (bug #3928) works fine. Using "reboot=bc" as a boot option made no difference.
Comment 12 Shaohua 2005-09-20 19:04:03 UTC
Can you narrow the bug down to see which step the system hang?
You can add some print something in arch/i386/kernel/reboot.c::machine_restart.
Comment 13 Pedro C 2005-09-27 15:24:39 UTC
Here's my new machine_restart:

void machine_restart(char * __unused)
        printk("REBOOT DEBUG: Before shutdown\n");
        printk("REBOOT DEBUG: After shutdown, Before restart\n");
        printk("REBOOT DEBUG: After restart\n");

None of this got triggered on a restart after suspend. It just didn't restart
and showed no extra messages that I could see. On a regular restart when I
didn't suspend I didn't see the messages but it scrolls pretty fast so I'm not sure.

Was this what you meant with the print stuff? Did I do something wrong?
Comment 14 Shaohua 2005-09-27 19:34:25 UTC
No, you did the right thing. It's strange you looked at the 'Restarting 
system.' but didn't looked at the message you added. This message is printed 
in 'kernel_restart' and just before calling 'machine_restart'. Does changing 
printk(...) to printk(KERN_EMERG...) show the message?
Comment 15 Pedro C 2005-09-29 06:47:38 UTC
My machine_restart is now:

void machine_restart(char * __unused)
	printk(KERN_EMERG "REBOOT DEBUG: Before shutdown\n");
	printk(KERN_EMERG "REBOOT DEBUG: After shutdown, Before restart\n");
	printk(KERN_EMERG "REBOOT DEBUG: After restart\n");

With this I see the first two messages but not the third and last.
Comment 16 Shaohua 2005-09-29 17:53:52 UTC
That's great! Could you please also do the same thing 
in 'machine_emergency_restart()'? Lets look at which step it 
failed. 'machine_emergency_restart' is in arch/i386/kernel/reboot.c. I would 
suppose machine_restart caused the hang.
Comment 17 Shaohua 2005-09-29 17:54:42 UTC
That's great! Could you please also do the same thing 
in 'machine_emergency_restart()'? Lets look at which step it 
failed. 'machine_emergency_restart' is in arch/i386/kernel/reboot.c. I would 
suppose mach_restart caused the hang.
Comment 18 Pedro C 2005-10-08 17:02:26 UTC
It's hanging inside mach_reboot().
Comment 19 Shaohua 2005-10-08 18:29:13 UTC
Does keyboard work in your system after resume?
Also could you please try the patch at http://lkml.org/lkml/2005/8/23/16?
Comment 20 Andrea Vettorello 2006-01-31 00:14:55 UTC
I'm not the original submitter, but i'm experience the same with different HW.

Distribution: Debian Sid
Hardware Environment: MSI S260 Centrino notebook
Software Environment: confirmed with kernel 2.6.14 and 2.6.15

Seems that 2.6.15 includes the http://lkml.org/lkml/2005/8/23/16 patch.

After resume keyboard (and all the system) works flawlessy, only reboot hangs,
shutdown instead works ok.

Ask freely if you need other info.
Comment 21 Pedro C 2006-01-31 07:30:35 UTC
But my problem is just that, reboot hanging. My keyboard and rest has always
worked fine.
Comment 22 Luming Yu 2006-06-12 00:10:31 UTC
Please reopen if patch at Bug 6655 cannot help.

*** This bug has been marked as a duplicate of 6655 ***

Note You need to log in before you can comment on or make changes to this bug.