mirror of
https://github.com/qemu/qemu.git
synced 2024-12-14 15:03:33 +08:00
30b5707c26
One of the goals of having less boilerplate on QOM declarations is to avoid human error. Requiring an extra argument that is never used is an opportunity for mistakes. Remove the unused argument from OBJECT_DECLARE_TYPE and OBJECT_DECLARE_SIMPLE_TYPE. Coccinelle patch used to convert all users of the macros: @@ declarer name OBJECT_DECLARE_TYPE; identifier InstanceType, ClassType, lowercase, UPPERCASE; @@ OBJECT_DECLARE_TYPE(InstanceType, ClassType, - lowercase, UPPERCASE); @@ declarer name OBJECT_DECLARE_SIMPLE_TYPE; identifier InstanceType, lowercase, UPPERCASE; @@ OBJECT_DECLARE_SIMPLE_TYPE(InstanceType, - lowercase, UPPERCASE); Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Cédric Le Goater <clg@kaod.org> Acked-by: Cornelia Huck <cohuck@redhat.com> Acked-by: Igor Mammedov <imammedo@redhat.com> Acked-by: Paul Durrant <paul@xen.org> Acked-by: Thomas Huth <thuth@redhat.com> Message-Id: <20200916182519.415636-4-ehabkost@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
30 lines
582 B
C
30 lines
582 B
C
#ifndef VIRTIO_VGA_H
|
|
#define VIRTIO_VGA_H
|
|
|
|
#include "hw/virtio/virtio-gpu-pci.h"
|
|
#include "vga_int.h"
|
|
#include "qom/object.h"
|
|
|
|
/*
|
|
* virtio-vga-base: This extends VirtioPCIProxy.
|
|
*/
|
|
#define TYPE_VIRTIO_VGA_BASE "virtio-vga-base"
|
|
OBJECT_DECLARE_TYPE(VirtIOVGABase, VirtIOVGABaseClass,
|
|
VIRTIO_VGA_BASE)
|
|
|
|
struct VirtIOVGABase {
|
|
VirtIOPCIProxy parent_obj;
|
|
|
|
VirtIOGPUBase *vgpu;
|
|
VGACommonState vga;
|
|
MemoryRegion vga_mrs[3];
|
|
};
|
|
|
|
struct VirtIOVGABaseClass {
|
|
VirtioPCIClass parent_class;
|
|
|
|
DeviceReset parent_reset;
|
|
};
|
|
|
|
#endif /* VIRTIO_VGA_H */
|