[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Suspicious QOM types without instance/class size
From: |
Cornelia Huck |
Subject: |
Re: Suspicious QOM types without instance/class size |
Date: |
Fri, 21 Aug 2020 11:43:35 +0200 |
On Thu, 20 Aug 2020 17:55:29 -0400
Eduardo Habkost <ehabkost@redhat.com> wrote:
> While trying to convert TypeInfo declarations to the new
> OBJECT_DECLARE* macros, I've stumbled on a few suspicious cases
> where instance_size or class_size is not set, despite having type
> checker macros that use a specific type.
>
> The ones with "WARNING" are abstract types (maybe not serious if
> subclasses set the appropriate sizes). The ones with "ERROR"
> don't seem to be abstract types.
>
> ERROR: hw/s390x/virtio-ccw.c:1237:1: class_size should be set to
> sizeof(VirtioCcwBusClass)?
> ERROR: hw/virtio/virtio-pci.c:2101:1: class_size should be set to
> sizeof(VirtioPCIBusClass)?
VirtioCcwBusClass and VirtioPCIBusClass are both simple typedefs of
VirtioBusClass (it's likely that I copied the ccw definition from the
pci one). virtio-mmio instead uses VirtioBusClass directly in its
checker macros.
I don't see a real reason for the typedefs, maybe ccw and pci should
use the mmio approach as well?
- Suspicious QOM types without instance/class size, Eduardo Habkost, 2020/08/20
- Re: Suspicious QOM types without instance/class size, David Gibson, 2020/08/20
- Re: Suspicious QOM types without instance/class size, Peter Maydell, 2020/08/21
- Re: Suspicious QOM types without instance/class size, David Hildenbrand, 2020/08/21
- Re: Suspicious QOM types without instance/class size,
Cornelia Huck <=
- Re: Suspicious QOM types without instance/class size, Roman Bolshakov, 2020/08/21
- Re: Suspicious QOM types without instance/class size, Eduardo Habkost, 2020/08/21
- Re: Suspicious QOM types without instance/class size, Eduardo Habkost, 2020/08/21
- Re: Suspicious QOM types without instance/class size, Roman Bolshakov, 2020/08/24
- Re: Suspicious QOM types without instance/class size, Eduardo Habkost, 2020/08/24
- Re: Suspicious QOM types without instance/class size, Roman Bolshakov, 2020/08/24
- Re: Suspicious QOM types without instance/class size, Eduardo Habkost, 2020/08/24
Re: Suspicious QOM types without instance/class size, Alistair Francis, 2020/08/21