[Qemu-devel] [PATCH v2 0/2] hw: provide error checking of disable-legacy/modern property usage

Daniel P. Berrangé posted 2 patches 5 years, 2 months ago
Test docker-mingw@fedora passed
Test asan passed
Test docker-clang@ubuntu failed
Test checkpatch passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20190215103239.28640-1-berrange@redhat.com
Maintainers: Gonglei <arei.gonglei@huawei.com>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, "Andreas Färber" <afaerber@suse.de>, Gerd Hoffmann <kraxel@redhat.com>, "Michael S. Tsirkin" <mst@redhat.com>, Eduardo Habkost <ehabkost@redhat.com>
hw/core/machine.c             | 23 ++++++++++++++++++++---
hw/display/virtio-gpu-pci.c   |  4 +++-
hw/display/virtio-vga.c       |  4 +++-
hw/virtio/virtio-crypto-pci.c |  4 +++-
hw/virtio/virtio-input-pci.c  |  4 +++-
hw/virtio/virtio-pci.c        | 26 ++++++++++++++++----------
hw/virtio/virtio-pci.h        | 31 +++++++++++++++++++++++++------
include/hw/qdev-core.h        |  3 ---
qom/object.c                  |  3 ---
9 files changed, 73 insertions(+), 29 deletions(-)
[Qemu-devel] [PATCH v2 0/2] hw: provide error checking of disable-legacy/modern property usage
Posted by Daniel P. Berrangé 5 years, 2 months ago
Changed in v2:

 - Fix properties set for v2.6 machine type compat so that it
   only affects the virtio devices which support both legacy
   and modern modes.
 - Revert unneccessary patch allowing optional properties in
   machine prop back compat

Daniel P. Berrangé (2):
  hw: report invalid disable-legacy|modern usage for virtio-1-only devs
  Revert "globals: Allow global properties to be optional"

 hw/core/machine.c             | 23 ++++++++++++++++++++---
 hw/display/virtio-gpu-pci.c   |  4 +++-
 hw/display/virtio-vga.c       |  4 +++-
 hw/virtio/virtio-crypto-pci.c |  4 +++-
 hw/virtio/virtio-input-pci.c  |  4 +++-
 hw/virtio/virtio-pci.c        | 26 ++++++++++++++++----------
 hw/virtio/virtio-pci.h        | 31 +++++++++++++++++++++++++------
 include/hw/qdev-core.h        |  3 ---
 qom/object.c                  |  3 ---
 9 files changed, 73 insertions(+), 29 deletions(-)

-- 
2.20.1


Re: [Qemu-devel] [PATCH v2 0/2] hw: provide error checking of disable-legacy/modern property usage
Posted by Michael S. Tsirkin 5 years, 1 month ago
On Fri, Feb 15, 2019 at 10:32:37AM +0000, Daniel P. Berrangé wrote:
> Changed in v2:
> 
>  - Fix properties set for v2.6 machine type compat so that it
>    only affects the virtio devices which support both legacy
>    and modern modes.
>  - Revert unneccessary patch allowing optional properties in
>    machine prop back compat


Eduardo can you review this please? Seems to revert your
patch :)

> Daniel P. Berrangé (2):
>   hw: report invalid disable-legacy|modern usage for virtio-1-only devs
>   Revert "globals: Allow global properties to be optional"
> 
>  hw/core/machine.c             | 23 ++++++++++++++++++++---
>  hw/display/virtio-gpu-pci.c   |  4 +++-
>  hw/display/virtio-vga.c       |  4 +++-
>  hw/virtio/virtio-crypto-pci.c |  4 +++-
>  hw/virtio/virtio-input-pci.c  |  4 +++-
>  hw/virtio/virtio-pci.c        | 26 ++++++++++++++++----------
>  hw/virtio/virtio-pci.h        | 31 +++++++++++++++++++++++++------
>  include/hw/qdev-core.h        |  3 ---
>  qom/object.c                  |  3 ---
>  9 files changed, 73 insertions(+), 29 deletions(-)
> 
> -- 
> 2.20.1

Re: [Qemu-devel] [PATCH v2 0/2] hw: provide error checking of disable-legacy/modern property usage
Posted by Eduardo Habkost 5 years, 1 month ago
On Tue, Mar 12, 2019 at 09:19:37PM -0400, Michael S. Tsirkin wrote:
> On Fri, Feb 15, 2019 at 10:32:37AM +0000, Daniel P. Berrangé wrote:
> > Changed in v2:
> > 
> >  - Fix properties set for v2.6 machine type compat so that it
> >    only affects the virtio devices which support both legacy
> >    and modern modes.
> >  - Revert unneccessary patch allowing optional properties in
> >    machine prop back compat
> 
> 
> Eduardo can you review this please? Seems to revert your
> patch :)

That's exactly the approach I had used in my first attempt[1] to
fix the bug introduced by commit f6e501a28ef9, so I have no
complaints.  :)

Daniel, I'm assuming this isn't necessary to fix a bug and can
wait after 4.0 is released.  Is that OK?

[1] https://www.mail-archive.com/qemu-devel@nongnu.org/msg584488.html

-- 
Eduardo

Re: [Qemu-devel] [PATCH v2 0/2] hw: provide error checking of disable-legacy/modern property usage
Posted by Daniel P. Berrangé 5 years, 1 month ago
On Mon, Mar 18, 2019 at 04:11:21PM -0300, Eduardo Habkost wrote:
> On Tue, Mar 12, 2019 at 09:19:37PM -0400, Michael S. Tsirkin wrote:
> > On Fri, Feb 15, 2019 at 10:32:37AM +0000, Daniel P. Berrangé wrote:
> > > Changed in v2:
> > > 
> > >  - Fix properties set for v2.6 machine type compat so that it
> > >    only affects the virtio devices which support both legacy
> > >    and modern modes.
> > >  - Revert unneccessary patch allowing optional properties in
> > >    machine prop back compat
> > 
> > 
> > Eduardo can you review this please? Seems to revert your
> > patch :)
> 
> That's exactly the approach I had used in my first attempt[1] to
> fix the bug introduced by commit f6e501a28ef9, so I have no
> complaints.  :)
> 
> Daniel, I'm assuming this isn't necessary to fix a bug and can
> wait after 4.0 is released.  Is that OK?

Fine with me.

Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|