[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsecti
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off |
Date: |
Tue, 27 Mar 2018 18:07:53 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 |
On 27/03/2018 13:34, Dr. David Alan Gilbert (git) wrote:
> From: "Dr. David Alan Gilbert" <address@hidden>
>
> Turn the newly added subsection off for old machine types
>
> Signed-off-by: Dr. David Alan Gilbert <address@hidden>
> ---
> include/hw/compat.h | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/include/hw/compat.h b/include/hw/compat.h
> index bc9e3a6627..13242b831a 100644
> --- a/include/hw/compat.h
> +++ b/include/hw/compat.h
> @@ -14,6 +14,10 @@
> .driver = "vhost-user-blk-pci",\
> .property = "vectors",\
> .value = "2",\
> + },{\
> + .driver = "e1000",\
> + .property = "migrate_tso_props",\
> + .value = "off",\
> },
>
> #define HW_COMPAT_2_10 \
>
Unfortunately it's not that easy, because on old machine types
tx.tso_props was stored in tx.props. So if the subsection is absent you
have to migrate either tx.tso_props or tx.props, depending on s->tx.cptse.
Likewise if you migrate from older versions: if s->tx.props.tse &&
s->tx.cptse, you have to copy s->tx.props to s->tx.tso_props and clear
s->tx.props. My understanding is that s->tx.tso_props.tse will be 1 if
and only if the source sent s->tx.tso_props.
This seems most easily done with a new field (e.g. vmstate_fixed_props)
that is written in pre_save and set in post_load.
Paolo
- [Qemu-devel] [PATCH 0/3] e1000 migration changes for 2.12, Dr. David Alan Gilbert (git), 2018/03/27
- [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off, Dr. David Alan Gilbert (git), 2018/03/27
- Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off,
Paolo Bonzini <=
- Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off, Dr. David Alan Gilbert, 2018/03/27
- Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off, Paolo Bonzini, 2018/03/27
- Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off, Dr. David Alan Gilbert, 2018/03/27
- Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off, Paolo Bonzini, 2018/03/27
- Re: [Qemu-devel] [PATCH 3/3] e1000: Old machine types, turn new subsection off, Ed Swierk, 2018/03/27
[Qemu-devel] [PATCH 2/3] e1000: wire new subsection to property, Dr. David Alan Gilbert (git), 2018/03/27
[Qemu-devel] [PATCH 1/3] e1000: Convert v3 fields to subsection, Dr. David Alan Gilbert (git), 2018/03/27
Re: [Qemu-devel] [PATCH 0/3] e1000 migration changes for 2.12, Jason Wang, 2018/03/27