qemu-patch-raspberry4/hw/net
Markus Armbruster 1b53ecd909 memory: Fix type of IOMMUMemoryRegionClass member @parent_class
TYPE_IOMMU_MEMORY_REGION is a direct subtype of TYPE_MEMORY_REGION.
Its instance struct is IOMMUMemoryRegion, and its first member is a
MemoryRegion.  Correct.  Its class struct is IOMMUMemoryRegionClass,
and its first member is a DeviceClass.  Wrong.  Messed up when commit
1221a47467 introduced the QOM type.  It even included hw/qdev-core.h
just for that.

TYPE_MEMORY_REGION doesn't bother to define a class struct.  This is
fine, it simply defaults to its super-type TYPE_OBJECT's class struct
ObjectClass.  Changing IOMMUMemoryRegionClass's first member's type to
ObjectClass would be a minimal fix, if a bit brittle: if
TYPE_MEMORY_REGION ever acquired own class struct, we'd have to update
IOMMUMemoryRegionClass to use it.

Fix it the clean and robust way instead: give TYPE_MEMORY_REGION its
own class struct MemoryRegionClass now, and use it for
IOMMUMemoryRegionClass's first member.

Revert the include of hw/qdev-core.h, and fix the few files that have
come to rely on it.

Cc: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20190812052359.30071-5-armbru@redhat.com>
2019-08-16 13:31:51 +02:00
..
can Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
fsl_etsec Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
rocker Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
allwinner_emac.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
cadence_gem.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
dp8393x.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
e1000.c e1000: don't raise interrupt in pre_save() 2019-07-29 16:29:30 +08:00
e1000_regs.h e1000: Rename the SEC symbol to SEQEC 2017-09-08 08:17:37 +08:00
e1000e.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
e1000e_core.c e1000e: Prevent MSI/MSI-X storms 2018-07-20 08:30:48 +08:00
e1000e_core.h Supply missing header guards 2019-06-12 13:20:21 +02:00
e1000x_common.c hw/net: Use the IEC binary prefix definitions 2018-07-02 15:41:16 +02:00
e1000x_common.h Supply missing header guards 2019-06-12 13:20:21 +02:00
eepro100.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
etraxfs_eth.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
ftgmac100.c ftgmac100: do not link to netdev 2019-07-02 10:21:06 +08:00
imx_fec.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
Kconfig hw/net/ne2000: Extract the PCI device from the chipset common code 2019-05-17 15:19:39 +02:00
lan9118.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
lance.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
Makefile.objs hw/net/ne2000: Extract the PCI device from the chipset common code 2019-05-17 15:19:39 +02:00
mcf_fec.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
milkymist-minimac2.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
mipsnet.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
ne2000-isa.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
ne2000-pci.c hw/net/ne2000: Extract the PCI device from the chipset common code 2019-05-17 15:19:39 +02:00
ne2000.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
ne2000.h hw/net: Use the IEC binary prefix definitions 2018-07-02 15:41:16 +02:00
net_rx_pkt.c net: Transmit zero UDP checksum as 0xFFFF 2017-11-20 11:08:00 +08:00
net_rx_pkt.h net_pkt: Extend packet abstraction as required by e1000e functionality 2016-06-02 10:42:28 +08:00
net_tx_pkt.c net: fix misaligned member access 2018-03-02 18:44:00 +00:00
net_tx_pkt.h clean-includes: run it once more 2016-06-16 18:39:03 +02:00
opencores_eth.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
pcnet-pci.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
pcnet.c hw/net/pcnet: Use qemu_log_mask(GUEST_ERROR) instead of printf 2019-05-02 18:12:58 +02:00
pcnet.h memory: Fix type of IOMMUMemoryRegionClass member @parent_class 2019-08-16 13:31:51 +02:00
rtl8139.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
smc91c111.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
spapr_llan.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
stellaris_enet.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
sungem.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
sunhme.c sunhme: ensure that RX descriptor ring overflow is indicated to client driver 2019-07-02 22:49:08 +01:00
trace-events sunhme: ensure that RX descriptor ring overflow is indicated to client driver 2019-07-02 22:49:08 +01:00
vhost_net-stub.c vhost-net: move stubs to a separate file 2019-02-21 12:28:01 -05:00
vhost_net.c vhost_net: don't set backend for the uninitialized virtqueue 2019-05-17 17:00:12 +08:00
virtio-net.c net/announce: Add optional ID 2019-07-02 10:21:06 +08:00
vmware_utils.h hw/net/vmxnet3: Fix code to work on big endian hosts, too 2017-11-20 11:08:00 +08:00
vmxnet3.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
vmxnet3.h hw/net/vmxnet3: Fix code to work on big endian hosts, too 2017-11-20 11:08:00 +08:00
vmxnet3_defs.h Supply missing header guards 2019-06-12 13:20:21 +02:00
vmxnet_debug.h Clean up ill-advised or unusual header guards 2016-07-12 16:20:46 +02:00
xen_nic.c xen: Import other xen/io/*.h 2019-06-24 10:42:30 +01:00
xgmac.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
xilinx_axienet.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00
xilinx_ethlite.c Include qemu/module.h where needed, drop it from qemu-common.h 2019-06-12 13:18:33 +02:00