xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: George Dunlap <george.dunlap@eu.citrix.com>
Cc: Ian Campbell <Ian.Campbell@citrix.com>,
	xen-devel@lists.xen.org, Paul Durrant <paul.durrant@citrix.com>,
	Stefano Stabellini <stefano.stabellini@citrix.com>,
	Alex Bligh <alex@alex.org.uk>,
	Anthony Perard <anthony.perard@citrix.com>,
	Diana Crisan <dcrisan@flexiant.com>,
	Dave Scott <Dave.Scott@eu.citrix.com>
Subject: Re: Early ACPI events prevent subsequent ACPI functionality on xen 4.3 + HVM domU
Date: Tue, 21 May 2013 12:45:31 -0400	[thread overview]
Message-ID: <20130521164531.GE3669@phenom.dumpdata.com> (raw)
In-Reply-To: <519B9801.3080901@eu.citrix.com>

On Tue, May 21, 2013 at 04:51:29PM +0100, George Dunlap wrote:
> On 05/21/2013 04:36 PM, George Dunlap wrote:
> >On 05/21/2013 04:17 PM, Alex Bligh wrote:
> >>
> >>
> >>--On 21 May 2013 15:34:34 +0100 George Dunlap
> >><george.dunlap@eu.citrix.com> wrote:
> >>
> >>>But the problem actually has nothing to do with ACPI -- it's the PV
> >>>shutdown command that is getting lost after the driver registers
> >>>HVM_PARAM_CALLBACK_IRQ but before something else comes up that starts
> >>>watching ../control/shutdown.
> >>
> >>I'm puzzled as to why you say that as the problem does not appear
> >>without ACPI in the xl.conf file.
> >
> >I can still get the same effect -- the only difference for me seems to
> >be that the "window" in which I can send a shutdown with no effect it is
> >shorter.  Maybe ACPI causes the extra few seconds at boot which makes it
> >more likely you're going to hit it?
> 
> If you can't trigger it manually, try something like this:
> 
> xl create dom.cfg ; while ! xl shutdown dom ; do sleep 1 ; done
> 
> Before PARAM_CALLBACK_IRQ is set, "xl shutdown dom" will fail, so
> this will keep trying every 1 second until it succeeds.  Since this
> is most likely within 1 second of PARAM_CALLBACK_IRQ being set, it
> should be within the window where the watch isn't set yet (or
> whatever it is that makes domU responsive to the PV shutdown
> commands).
> 
> It works reliably for me with acpi=0.

And with 'acpi=1' ?

>From the Linux side, there are three paths that can cause a shutdown.
Internally the user can invoke poweroff, which will end up calling the
shutdown procecedure.

PV path - which works on both PVHVM and PV. This is triggered by
watch firring on control/shutdown. Thought interestingly if you wrote
the initial value of "poweroff" there, the kernel would not read it unless
a trigger followed. A change can be done in there to read the value
at bootup and see if "poweroff" is present.

And the emulated path. I think this is ACPI S5, but I would have to
dig a bit in the QEMU to see if that is how it does it. This is the
same path that Windows or any HVM guests would shutdown.

For the emulated path I am not entirely sure how the ACPI path works 
when a guest hasn't initialized its ACPI machinery. I would think the
ACPI SCI would be triggered, but it might not be since the ACPI AML
has no way of running (as the OS hasn't even started reading it). In
which case the emulated path ought to use a fallback, whatever that is.
But I am not sure if there is a fallback except "yanking the power" - which
I think is what normal machines do if you hold the power off button for
more than 3 seconds.

  parent reply	other threads:[~2013-05-21 16:45 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1052133728.8634452.1368537175372.JavaMail.root@zimbra002>
2013-05-14 13:13 ` Early ACPI events prevent subsequent ACPI functionality on xen 4.3 + HVM domU Diana Crisan
2013-05-17 17:35   ` Ian Campbell
2013-05-18  9:55     ` Alex Bligh
2013-05-21 13:39       ` George Dunlap
2013-05-21 14:16         ` George Dunlap
2013-05-21 14:20           ` Ian Campbell
2013-05-21 14:34             ` George Dunlap
2013-05-21 14:42               ` Ian Campbell
2013-05-21 16:51                 ` Dave Scott
2013-05-21 19:58                   ` Ian Campbell
2013-05-21 15:17               ` Alex Bligh
2013-05-21 15:36                 ` George Dunlap
2013-05-21 15:51                   ` George Dunlap
2013-05-21 16:22                     ` Alex Bligh
2013-05-21 16:45                     ` Konrad Rzeszutek Wilk [this message]
2013-05-21 17:48                       ` Alex Bligh
2013-05-21 19:33                         ` Konrad Rzeszutek Wilk
2013-05-21 19:46                           ` Alex Bligh
2013-05-22  9:57                           ` Ian Campbell
2013-05-22  9:21                         ` George Dunlap
2013-05-22 10:08                           ` Alex Bligh
2013-05-22 10:45                             ` Diana Crisan
2013-05-22 10:55                               ` George Dunlap
2013-05-22 11:16                                 ` Alex Bligh
2013-05-22 11:50                                   ` George Dunlap
2013-05-22 14:43                                     ` Konrad Rzeszutek Wilk
2013-11-06 16:05                                       ` Konrad Rzeszutek Wilk
2013-11-06 16:14                                         ` Ian Campbell
2013-11-06 20:16                                           ` Konrad Rzeszutek Wilk
2013-11-07 11:24                                             ` Ian Campbell
2013-11-08 14:27                                               ` Konrad Rzeszutek Wilk
2013-11-06 16:18                                         ` Jan Beulich
2013-05-21 15:16         ` Alex Bligh
2013-05-21 15:23           ` George Dunlap
2013-05-21 15:59             ` Alex Bligh
2013-05-21 16:09               ` George Dunlap
2013-05-21 16:25                 ` Alex Bligh
2013-05-21 16:48                 ` Diana Crisan
2013-05-21 17:31                 ` Sander Eikelenboom
2013-06-27 14:04                   ` George Dunlap

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=20130521164531.GE3669@phenom.dumpdata.com \
    --to=konrad.wilk@oracle.com \
    --cc=Dave.Scott@eu.citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=alex@alex.org.uk \
    --cc=anthony.perard@citrix.com \
    --cc=dcrisan@flexiant.com \
    --cc=george.dunlap@eu.citrix.com \
    --cc=paul.durrant@citrix.com \
    --cc=stefano.stabellini@citrix.com \
    --cc=xen-devel@lists.xen.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).