kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: kvm-devel <kvm@vger.kernel.org>
Subject: No kernel interface to reset a VCPU
Date: Fri, 25 Sep 2009 16:52:05 +0200	[thread overview]
Message-ID: <4ABCD915.5090503@siemens.com> (raw)

Hi all,

looks to me like there is no way to properly reset the boot processor.
The current pattern used by qemu[-kvm] is to reload all registers with
their reset values. But that does not affect the internal VCPU states
the KVM keeps in the kernel. They are only reset during VCPU setup or
after receiving a SIPI (and the latter only helps with secondary CPUs).

So the only way around it with the current kernel interface is to
destroy/recreate the BSP on reset, right? /me is looking into such an
approach now.


We stumbled over inconsistent VCPU states with our internal qemu-kvm
tree. We have a legacy watchdog emulation here that triggered but failed
to bring up the system again. I wasn't able to create a similar case
with a standard environment yet, but I think it is not unrealistic for
qemu-kvm as well. Hacking kvm_arch_vcpu_reset() into KVM that triggers
on the right register values "solved" the issue here.

Jan

-- 
Siemens AG, Corporate Technology, CT SE 2
Corporate Competence Center Embedded Linux

             reply	other threads:[~2009-09-25 14:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-25 14:52 Jan Kiszka [this message]
2009-09-25 17:13 ` No kernel interface to reset a VCPU Gleb Natapov
2009-09-25 18:54   ` Jan Kiszka

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=4ABCD915.5090503@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=kvm@vger.kernel.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).