mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 09:43:56 -06:00
include/hw/qdev-properties: Remove DEFINE_PROP_END_OF_LIST
Now that all of the Property arrays are counted, we can remove the terminator object from each array. Update the assertions in device_class_set_props to match. With struct Property being 88 bytes, this was a rather large form of terminator. Saves 30k from qemu-system-aarch64. Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Tested-by: Lei Yang <leiyang@redhat.com> Link: https://lore.kernel.org/r/20241218134251.4724-21-richard.henderson@linaro.org Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
ebe9685f12
commit
5fcabe628b
556 changed files with 7 additions and 624 deletions
|
@ -811,7 +811,6 @@ static const VMStateDescription vmstate_allwinner_sdhost = {
|
|||
static const Property allwinner_sdhost_properties[] = {
|
||||
DEFINE_PROP_LINK("dma-memory", AwSdHostState, dma_mr,
|
||||
TYPE_MEMORY_REGION, MemoryRegion *),
|
||||
DEFINE_PROP_END_OF_LIST(),
|
||||
};
|
||||
|
||||
static void allwinner_sdhost_init(Object *obj)
|
||||
|
|
|
@ -206,7 +206,6 @@ static const VMStateDescription vmstate_aspeed_sdhci = {
|
|||
|
||||
static const Property aspeed_sdhci_properties[] = {
|
||||
DEFINE_PROP_UINT8("num-slots", AspeedSDHCIState, num_slots, 0),
|
||||
DEFINE_PROP_END_OF_LIST(),
|
||||
};
|
||||
|
||||
static void aspeed_sdhci_class_init(ObjectClass *classp, void *data)
|
||||
|
|
|
@ -2800,19 +2800,16 @@ static void emmc_realize(DeviceState *dev, Error **errp)
|
|||
|
||||
static const Property sdmmc_common_properties[] = {
|
||||
DEFINE_PROP_DRIVE("drive", SDState, blk),
|
||||
DEFINE_PROP_END_OF_LIST()
|
||||
};
|
||||
|
||||
static const Property sd_properties[] = {
|
||||
DEFINE_PROP_UINT8("spec_version", SDState,
|
||||
spec_version, SD_PHY_SPECv3_01_VERS),
|
||||
DEFINE_PROP_END_OF_LIST()
|
||||
};
|
||||
|
||||
static const Property emmc_properties[] = {
|
||||
DEFINE_PROP_UINT64("boot-partition-size", SDState, boot_part_size, 0),
|
||||
DEFINE_PROP_UINT8("boot-config", SDState, boot_config, 0x0),
|
||||
DEFINE_PROP_END_OF_LIST()
|
||||
};
|
||||
|
||||
static void sdmmc_common_class_init(ObjectClass *klass, void *data)
|
||||
|
|
|
@ -24,7 +24,6 @@
|
|||
|
||||
static const Property sdhci_pci_properties[] = {
|
||||
DEFINE_SDHCI_COMMON_PROPERTIES(SDHCIState),
|
||||
DEFINE_PROP_END_OF_LIST(),
|
||||
};
|
||||
|
||||
static void sdhci_pci_realize(PCIDevice *dev, Error **errp)
|
||||
|
|
|
@ -1550,7 +1550,6 @@ static const Property sdhci_sysbus_properties[] = {
|
|||
false),
|
||||
DEFINE_PROP_LINK("dma", SDHCIState,
|
||||
dma_mr, TYPE_MEMORY_REGION, MemoryRegion *),
|
||||
DEFINE_PROP_END_OF_LIST(),
|
||||
};
|
||||
|
||||
static void sdhci_sysbus_init(Object *obj)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue