All of lore.kernel.org
 help / color / mirror / Atom feed
From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: "Sven Köhler" <sven.koehler@gmail.com>
Cc: xen-devel@lists.xensource.com
Subject: Re: xen 4.1.0 + 3.0-rc3 pvops: virtualbox doesn't power off
Date: Wed, 15 Jun 2011 08:41:42 -0400	[thread overview]
Message-ID: <20110615124142.GB5512@dumpdata.com> (raw)
In-Reply-To: <it8uke$dun$1@dough.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 628 bytes --]

On Wed, Jun 15, 2011 at 02:33:28AM +0200, Sven Köhler wrote:
> Hi,
> 
> I'm running xen 4.1.0 and 3.0-rc3 pvops dom0 with vga text console patch
> inside virtualbox (both xen and dom0 kernel 64bit).
> 
> It doesn't power off. I see the "Power down." message by the kernel,
> then nothing happens. Reboot works fine. Same kernel on bare metal
> (still inside virtalbox) powers off fine. Also 2.6.39.x from konrad's
> tree power's off fine, with or without xen.

You probably need the patch titled "xen: When calling power_off, don't call the halt function."

see attached patch and please tell me whether it works.

[-- Attachment #2: 9734ef061dacd34c12015032261566e72a5b0e95.patch --]
[-- Type: text/x-diff, Size: 1213 bytes --]

commit 9734ef061dacd34c12015032261566e72a5b0e95
Author: Tom Goetz <tom.goetz@virtualcomputer.com>
Date:   Mon May 16 15:06:26 2011 -0400

    xen: When calling power_off, don't call the halt function.
    
    .. As it won't actually power off the machine.
    
    Signed-off-by: Tom Goetz <tom.goetz@virtualcomputer.com>
    Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>

diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
index e3c6a06..5584fb1 100644
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -1033,6 +1033,13 @@ static void xen_machine_halt(void)
 	xen_reboot(SHUTDOWN_poweroff);
 }
 
+static void xen_machine_power_off(void)
+{
+	if (pm_power_off)
+		pm_power_off();
+	xen_reboot(SHUTDOWN_poweroff);
+}
+
 static void xen_crash_shutdown(struct pt_regs *regs)
 {
 	xen_reboot(SHUTDOWN_crash);
@@ -1058,7 +1065,7 @@ int xen_panic_handler_init(void)
 static const struct machine_ops __initdata xen_machine_ops = {
 	.restart = xen_restart,
 	.halt = xen_machine_halt,
-	.power_off = xen_machine_halt,
+	.power_off = xen_machine_power_off,
 	.shutdown = xen_machine_halt,
 	.crash_shutdown = xen_crash_shutdown,
 	.emergency_restart = xen_emergency_restart,

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

  reply	other threads:[~2011-06-15 12:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-15  0:33 xen 4.1.0 + 3.0-rc3 pvops: virtualbox doesn't power off Sven Köhler
2011-06-15 12:41 ` Konrad Rzeszutek Wilk [this message]
2011-06-15 18:14   ` Sven Köhler
2011-06-15 19:21     ` Konrad Rzeszutek Wilk
2011-06-15 20:04       ` Sven Köhler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110615124142.GB5512@dumpdata.com \
    --to=konrad.wilk@oracle.com \
    --cc=sven.koehler@gmail.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.