提交 922cc38a 编写于 作者: J Jeremy Fitzhardinge

xen: don't call dpm_resume_noirq() with interrupts disabled.

dpm_resume_noirq() takes a mutex, so it can't be called from a no-interrupt
context.  Don't call it from within the stop-machine function, but just
afterwards, since we're resuming anyway, regardless of what happened.
Signed-off-by: NJeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Cc: Stable Kernel <stable@kernel.org>
上级 499d19b8
...@@ -43,7 +43,6 @@ static int xen_suspend(void *data) ...@@ -43,7 +43,6 @@ static int xen_suspend(void *data)
if (err) { if (err) {
printk(KERN_ERR "xen_suspend: sysdev_suspend failed: %d\n", printk(KERN_ERR "xen_suspend: sysdev_suspend failed: %d\n",
err); err);
dpm_resume_noirq(PMSG_RESUME);
return err; return err;
} }
...@@ -69,7 +68,6 @@ static int xen_suspend(void *data) ...@@ -69,7 +68,6 @@ static int xen_suspend(void *data)
} }
sysdev_resume(); sysdev_resume();
dpm_resume_noirq(PMSG_RESUME);
return 0; return 0;
} }
...@@ -108,6 +106,9 @@ static void do_suspend(void) ...@@ -108,6 +106,9 @@ static void do_suspend(void)
} }
err = stop_machine(xen_suspend, &cancelled, cpumask_of(0)); err = stop_machine(xen_suspend, &cancelled, cpumask_of(0));
dpm_resume_noirq(PMSG_RESUME);
if (err) { if (err) {
printk(KERN_ERR "failed to start xen_suspend: %d\n", err); printk(KERN_ERR "failed to start xen_suspend: %d\n", err);
goto out; goto out;
...@@ -119,8 +120,6 @@ static void do_suspend(void) ...@@ -119,8 +120,6 @@ static void do_suspend(void)
} else } else
xs_suspend_cancel(); xs_suspend_cancel();
dpm_resume_noirq(PMSG_RESUME);
resume_devices: resume_devices:
dpm_resume_end(PMSG_RESUME); dpm_resume_end(PMSG_RESUME);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册