All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Andreas Färber" <afaerber@suse.de>
To: Vincenzo Maffione <v.maffione@gmail.com>
Cc: Anthony Liguori <aliguori@us.ibm.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	Jason Wang <jasowang@redhat.com>,
	qemu-devel@nongnu.org, Stefan Hajnoczi <stefanha@redhat.com>,
	Paolo Bonzini <pbonzini@redhat.com>,
	Giuseppe Lettieri <g.lettieri@iet.unipi.it>,
	Luigi Rizzo <rizzo@iet.unipi.it>
Subject: Re: [Qemu-devel] [PATCH v2] e1000: add interrupt mitigation support
Date: Fri, 26 Jul 2013 16:14:14 +0200	[thread overview]
Message-ID: <51F28436.5050607@suse.de> (raw)
In-Reply-To: <CA+_eA9h=3APdR-n81RPdQ3PF2zWrjRnaCQvTpEL_Keu3JqY6XA@mail.gmail.com>

Am 26.07.2013 15:09, schrieb Vincenzo Maffione:
> 2013/7/26 Andreas Färber <afaerber@suse.de>:
>> Am 26.07.2013 12:14, schrieb Vincenzo Maffione:
>>>   I tried to support cross-version migration using version_id and
>>> VMState subsections.
>>
>> The point of using a subsection is to avoid incrementing version_id AFAIU.
> 
> Consider a migration from an older QEMU version to a newer one.
> AFAIU, the e1000_post_load() callback is passed "1" or "2" into the
> "version_id" parameter (i.e. the e1000 version of the older QEMU).
> If that is correct, in this scenario I have to zero-init the new
> fields I implemented, otherwise they would stay uninitialized.

The whole state struct is always zero-initialized as part of
object_new()/qdev_create(). So only non-zero fields need to be
initialized, and I assume that a zero flag will indicate no mitigation
feature.

> If I don't increment version_id to 3, how can I understand when we are
> in this scenario?
> 
> Or maybe I should assume that (in the same scenario) the new version
> QEMU instance MUST have been launched with the mitigation disabled? If
> I assume this it seems to me that incrementing version_id to 3 is not
> necessary.

You can assume that you have equivalent command lines on both source and
destination. -M pc-i440fx-1.5 and -M pc-q35-1.5 would simply never
receive your subsection. I'm sure Stefan can explain in more detail.

Regards,
Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

  reply	other threads:[~2013-07-26 14:14 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-26 10:14 [Qemu-devel] [PATCH v2] e1000: add interrupt mitigation support Vincenzo Maffione
2013-07-26 12:05 ` Andreas Färber
2013-07-26 13:09   ` Vincenzo Maffione
2013-07-26 14:14     ` Andreas Färber [this message]
2013-07-26 14:17       ` Vincenzo Maffione

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=51F28436.5050607@suse.de \
    --to=afaerber@suse.de \
    --cc=aliguori@us.ibm.com \
    --cc=g.lettieri@iet.unipi.it \
    --cc=jasowang@redhat.com \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=rizzo@iet.unipi.it \
    --cc=stefanha@redhat.com \
    --cc=v.maffione@gmail.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.