Messages in this thread Patch in this message |  | | Date | Tue, 21 Oct 2014 16:15:07 -0700 | Subject | Re: Machine crashes right *after* ~successful resume | From | Yinghai Lu <> |
| |
On Tue, Oct 21, 2014 at 2:40 PM, Wilmer van der Gaast <wilmer@gaast.net> wrote: > Hello, > > Sorry for the delay, finally poked at this again. It looks like the > no_console_suspend flag was causing troubles, which I didn't really need > anyway with logging going to my serial port. > > This is what I get now on the failing resume: > > [ 112.879390] PM: resume of devices complete after 2239.905 msecs > [ 112.880068] r8169 0000:07:00.0 eth0: link up > [ 112.880078] Switched to clocksource hpet > [ 116.069248] PM: Finishing wakeup. > [ 116.072574] Restarting tasks ... done. > [ 116.076664] PM: calling nb rcu_pm_notify+0x0/0x60 > [ 116.081439] PM: ... nb rcu_pm_notify+0x0/0x60 done > [ 116.086267] PM: calling nb cpu_hotplug_pm_callback+0x0/0x50 > [ 116.088526] systemd[1]: Got notification message for unit > systemd-journald.service > [ 116.099442] PM: ... nb cpu_hotplug_pm_callback+0x0/0x50 done > [ 116.105099] PM: calling nb fw_pm_notify+0x0/0x150 > [ 116.109812] PM: ... nb fw_pm_notify+0x0/0x150 done > [ 116.114623] PM: calling nb bsp_pm_callback+0x0/0x50 > [ 116.119504] PM: ... nb bsp_pm_callback+0x0/0x50 done > > And then nothing, and it's hung. Looks the same to me (apart from the tsc > issues + hpet switch) as a successful resume:
then it stuck in pm_restore_console()?
Please check attached debut patch.
Thanks
Yinghai --- kernel/power/console.c | 9 +++++++++ 1 file changed, 9 insertions(+)
Index: linux-2.6/kernel/power/console.c =================================================================== --- linux-2.6.orig/kernel/power/console.c +++ linux-2.6/kernel/power/console.c @@ -51,6 +51,7 @@ void pm_vt_switch_required(struct device if (tmp->dev == dev) { /* already registered, update requirement */ tmp->required = required; + dev_info(dev, "pm_vt_switch_required() update %d\n", required); goto out; } } @@ -61,6 +62,7 @@ void pm_vt_switch_required(struct device entry->required = required; entry->dev = dev; + dev_info(dev, "pm_vt_switch_required() added %d\n", required); list_add(&entry->head, &pm_vt_switch_list); out: @@ -81,6 +83,7 @@ void pm_vt_switch_unregister(struct devi mutex_lock(&vt_switch_mutex); list_for_each_entry(tmp, &pm_vt_switch_list, head) { if (tmp->dev == dev) { + dev_info(dev, "pm_vt_switch_required() removed %d\n", tmp->required); list_del(&tmp->head); kfree(tmp); break; @@ -131,11 +134,14 @@ int pm_prepare_console(void) if (!pm_vt_switch()) return 0; + pr_info("pm_prepare_console() before move\n"); orig_fgconsole = vt_move_to_console(SUSPEND_CONSOLE, 1); if (orig_fgconsole < 0) return 1; + pr_info("pm_prepare_console() before redirect\n"); orig_kmsg = vt_kmsg_redirect(SUSPEND_CONSOLE); + pr_info("pm_prepare_console() done\n"); return 0; } @@ -145,7 +151,10 @@ void pm_restore_console(void) return; if (orig_fgconsole >= 0) { + pr_info("pm_restore_console() before move\n"); vt_move_to_console(orig_fgconsole, 0); + pr_info("pm_restore_console() before redirect\n"); vt_kmsg_redirect(orig_kmsg); + pr_info("pm_restore_console() done\n"); } } |  |