From: Marcelo Tosatti <mtosatti@redhat.com>
To: Glauber Costa <glommer@redhat.com>
Cc: kvm@vger.kernel.org, qemu-devel@nongnu.org, avi@redhat.com
Subject: Re: [PATCH v2 1/2] Do not register kvmclock savevm section if kvmclock is disabled.
Date: Wed, 8 Dec 2010 17:31:28 -0200 [thread overview]
Message-ID: <20101208193128.GA13021@amt.cnet> (raw)
In-Reply-To: <1291741956.28598.17.camel@mothafucka.localdomain>
On Tue, Dec 07, 2010 at 03:12:36PM -0200, Glauber Costa wrote:
> On Mon, 2010-12-06 at 19:04 -0200, Marcelo Tosatti wrote:
> > On Mon, Dec 06, 2010 at 09:03:46AM -0500, Glauber Costa wrote:
> > > Usually nobody usually thinks about that scenario (me included and specially),
> > > but kvmclock can be actually disabled in the host.
> > >
> > > It happens in two scenarios:
> > > 1. host too old.
> > > 2. we passed -kvmclock to our -cpu parameter.
> > >
> > > In both cases, we should not register kvmclock savevm section. This patch
> > > achives that by registering this section only if kvmclock is actually
> > > currently enabled in cpuid.
> > >
> > > The only caveat is that we have to register the savevm section a little bit
> > > later, since we won't know the final kvmclock state before cpuid gets parsed.
> >
> > What is the problem of registering the section? Restoring the value if
> > the host does not support it returns an error?
> >
> > Can't you ignore the error if kvmclock is not reported in cpuid, in the
> > restore handler?
>
> We can change the restore handler, but not the restore handler of
> binaries that are already out there. The motivation here is precisely to
> address migration to hosts without kvmclock, so it's better to have
> a way to disable, than to count on the fact that the other side will be
> able to ignore it.
OK. Can't you register conditionally on kvmclock cpuid bit at the end of
kvm_arch_init_vcpu, in target-i386/kvm.c?
WARNING: multiple messages have this Message-ID (diff)
From: Marcelo Tosatti <mtosatti@redhat.com>
To: Glauber Costa <glommer@redhat.com>
Cc: qemu-devel@nongnu.org, kvm@vger.kernel.org, avi@redhat.com
Subject: [Qemu-devel] Re: [PATCH v2 1/2] Do not register kvmclock savevm section if kvmclock is disabled.
Date: Wed, 8 Dec 2010 17:31:28 -0200 [thread overview]
Message-ID: <20101208193128.GA13021@amt.cnet> (raw)
In-Reply-To: <1291741956.28598.17.camel@mothafucka.localdomain>
On Tue, Dec 07, 2010 at 03:12:36PM -0200, Glauber Costa wrote:
> On Mon, 2010-12-06 at 19:04 -0200, Marcelo Tosatti wrote:
> > On Mon, Dec 06, 2010 at 09:03:46AM -0500, Glauber Costa wrote:
> > > Usually nobody usually thinks about that scenario (me included and specially),
> > > but kvmclock can be actually disabled in the host.
> > >
> > > It happens in two scenarios:
> > > 1. host too old.
> > > 2. we passed -kvmclock to our -cpu parameter.
> > >
> > > In both cases, we should not register kvmclock savevm section. This patch
> > > achives that by registering this section only if kvmclock is actually
> > > currently enabled in cpuid.
> > >
> > > The only caveat is that we have to register the savevm section a little bit
> > > later, since we won't know the final kvmclock state before cpuid gets parsed.
> >
> > What is the problem of registering the section? Restoring the value if
> > the host does not support it returns an error?
> >
> > Can't you ignore the error if kvmclock is not reported in cpuid, in the
> > restore handler?
>
> We can change the restore handler, but not the restore handler of
> binaries that are already out there. The motivation here is precisely to
> address migration to hosts without kvmclock, so it's better to have
> a way to disable, than to count on the fact that the other side will be
> able to ignore it.
OK. Can't you register conditionally on kvmclock cpuid bit at the end of
kvm_arch_init_vcpu, in target-i386/kvm.c?
next prev parent reply other threads:[~2010-12-08 19:31 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-06 14:03 [PATCH v2 0/2] savevm odness related to kvmclock Glauber Costa
2010-12-06 14:03 ` [Qemu-devel] " Glauber Costa
2010-12-06 14:03 ` [PATCH v2 1/2] Do not register kvmclock savevm section if kvmclock is disabled Glauber Costa
2010-12-06 14:03 ` [Qemu-devel] " Glauber Costa
2010-12-06 21:04 ` Marcelo Tosatti
2010-12-06 21:04 ` [Qemu-devel] " Marcelo Tosatti
2010-12-06 21:55 ` Marcelo Tosatti
2010-12-06 21:55 ` [Qemu-devel] " Marcelo Tosatti
2010-12-07 17:12 ` Glauber Costa
2010-12-07 17:12 ` [Qemu-devel] " Glauber Costa
2010-12-08 19:31 ` Marcelo Tosatti [this message]
2010-12-08 19:31 ` Marcelo Tosatti
2010-12-13 13:40 ` Glauber Costa
2010-12-13 13:40 ` [Qemu-devel] " Glauber Costa
2010-12-06 14:03 ` [PATCH v2 2/2] make kvmclock value idempotent for stopped machine Glauber Costa
2010-12-06 14:03 ` [Qemu-devel] " Glauber Costa
2010-12-06 14:10 ` [PATCH v2 0/2] savevm odness related to kvmclock Paolo Bonzini
2010-12-06 14:10 ` [Qemu-devel] " Paolo Bonzini
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=20101208193128.GA13021@amt.cnet \
--to=mtosatti@redhat.com \
--cc=avi@redhat.com \
--cc=glommer@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=qemu-devel@nongnu.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 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.