@@ -83,7 +83,7 @@ static inline unsigned int get_physical_block_exp(BlockConf *conf)
_conf.account_failed, ON_OFF_AUTO_AUTO), \
DEFINE_PROP_ARRAY("stats-intervals", _state, \
_conf.num_stats_intervals, _conf.stats_intervals, \
- qdev_prop_uint32, uint32_t)
+ qdev_prop_uint32)
#define DEFINE_BLOCK_PROPERTIES(_state, _conf) \
DEFINE_PROP_DRIVE("drive", _state, _conf.blk), \
@@ -144,17 +144,15 @@ extern const PropertyInfo qdev_prop_link_array;
* @_name: name of the array
* @_state: name of the device state structure type
* @_field: uint32_t field in @_state to hold the array length
- * @_arrayfield: field in @_state (of type '@_arraytype *') which
- * will point to the array
+ * @_arrayfield: field in @_state which will point to the array
* @_arrayprop: PropertyInfo for the array elements (e.g. qdev_prop_uint32);
* a corresponding array PropertyInfo named @_arrayprop##_array
* must exist
- * @_arraytype: C type of the array elements
*
* Define device properties for a variable-length array _name. The array is
* represented as a list in the visitor interface.
*
- * @_arraytype is required to be movable with memcpy().
+ * The element type must be movable with memcpy().
*
* When the array property is set, the @_field member of the device
* struct is set to the array length, and @_arrayfield is set to point
@@ -164,7 +162,7 @@ extern const PropertyInfo qdev_prop_link_array;
* @_arrayfield memory.
*/
#define DEFINE_PROP_ARRAY(_name, _state, _field, \
- _arrayfield, _arrayprop, _arraytype) \
+ _arrayfield, _arrayprop) \
DEFINE_PROP(_name, _state, _field, _arrayprop##_array, uint32_t, \
.set_default = true, \
.defval.u = 0, \
@@ -179,10 +177,8 @@ extern const PropertyInfo qdev_prop_link_array;
* @_name: name of the array
* @_state: name of the device state structure type
* @_field: uint32_t field in @_state to hold the array length
- * @_arrayfield: field in @_state (of type '@_arraytype *') which
- * will point to the array
+ * @_arrayfield: field in @_state which will point to the array
* @_linktype: QOM type name of the link type
- * @_arraytype: C type of the array elements
*
* Define device properties for a variable-length array _name of links
* (i.e. this is the array version of DEFINE_PROP_LINK).
@@ -191,7 +187,7 @@ extern const PropertyInfo qdev_prop_link_array;
* where each string is the QOM path of the object to be linked.
*/
#define DEFINE_PROP_LINK_ARRAY(_name, _state, _field, _arrayfield, \
- _linktype, _arraytype) \
+ _linktype) \
DEFINE_PROP(_name, _state, _field, qdev_prop_link_array, uint32_t, \
.set_default = true, \
.defval.u = 0, \
@@ -80,7 +80,7 @@ static void stellaris_gamepad_reset_enter(Object *obj, ResetType type)
static const Property stellaris_gamepad_properties[] = {
DEFINE_PROP_ARRAY("keycodes", StellarisGamepad, num_buttons,
- keycodes, qdev_prop_uint32, uint32_t),
+ keycodes, qdev_prop_uint32),
};
static void stellaris_gamepad_class_init(ObjectClass *klass, const void *data)
@@ -615,7 +615,7 @@ static const Property arm_gicv3_common_properties[] = {
*/
DEFINE_PROP_BOOL("force-8-bit-prio", GICv3State, force_8bit_prio, 0),
DEFINE_PROP_ARRAY("redist-region-count", GICv3State, nb_redist_regions,
- redist_region_count, qdev_prop_uint32, uint32_t),
+ redist_region_count, qdev_prop_uint32),
DEFINE_PROP_LINK("sysmem", GICv3State, dma, TYPE_MEMORY_REGION,
MemoryRegion *),
DEFINE_PROP_UINT32("first-cpu-index", GICv3State, first_cpu_idx, 0),
@@ -191,9 +191,9 @@ static void gicv5_common_realize(DeviceState *dev, Error **errp)
static const Property arm_gicv5_common_properties[] = {
DEFINE_PROP_LINK_ARRAY("cpus", GICv5Common, num_cpus,
- cpus, TYPE_ARM_CPU, ARMCPU *),
+ cpus, TYPE_ARM_CPU),
DEFINE_PROP_ARRAY("cpu-iaffids", GICv5Common, num_cpu_iaffids,
- cpu_iaffids, qdev_prop_uint32, uint32_t),
+ cpu_iaffids, qdev_prop_uint32),
DEFINE_PROP_UINT32("irsid", GICv5Common, irsid, 0),
DEFINE_PROP_UINT32("spi-range", GICv5Common, spi_range, 0),
DEFINE_PROP_UINT32("spi-base", GICv5Common, spi_base, 0),
@@ -356,9 +356,9 @@ static const VMStateDescription vmstate_rxicu = {
static const Property rxicu_properties[] = {
DEFINE_PROP_ARRAY("ipr-map", RXICUState, nr_irqs, map,
- qdev_prop_uint8, uint8_t),
+ qdev_prop_uint8),
DEFINE_PROP_ARRAY("trigger-level", RXICUState, nr_sense, init_sense,
- qdev_prop_uint8, uint8_t),
+ qdev_prop_uint8),
};
static void rxicu_class_init(ObjectClass *klass, const void *data)
@@ -626,10 +626,10 @@ static const Property arm_sysctl_properties[] = {
DEFINE_PROP_UINT32("proc_id", arm_sysctl_state, proc_id, 0),
/* Daughterboard power supply voltages (as reported via SYS_CFG) */
DEFINE_PROP_ARRAY("db-voltage", arm_sysctl_state, db_num_vsensors,
- db_voltage, qdev_prop_uint32, uint32_t),
+ db_voltage, qdev_prop_uint32),
/* Daughterboard clock reset values (as reported via SYS_CFG) */
DEFINE_PROP_ARRAY("db-clock", arm_sysctl_state, db_num_clocks,
- db_clock_reset, qdev_prop_uint32, uint32_t),
+ db_clock_reset, qdev_prop_uint32),
};
static void arm_sysctl_class_init(ObjectClass *klass, const void *data)
@@ -464,7 +464,7 @@ static const Property mps2_scc_properties[] = {
* motherboard configuration controller to suit the FPGA image.
*/
DEFINE_PROP_ARRAY("oscclk", MPS2SCC, num_oscclk, oscclk_reset,
- qdev_prop_uint32, uint32_t),
+ qdev_prop_uint32),
};
static void mps2_scc_class_init(ObjectClass *klass, const void *data)
@@ -1466,7 +1466,7 @@ static const Property rocker_properties[] = {
DEFINE_PROP_UINT64("switch_id", Rocker,
switch_id, 0),
DEFINE_PROP_ARRAY("ports", Rocker, fp_ports,
- fp_ports_peers, qdev_prop_netdev, NICPeers),
+ fp_ports_peers, qdev_prop_netdev),
};
static const VMStateDescription rocker_vmsd = {
@@ -4380,7 +4380,7 @@ static const Property virtio_net_properties[] = {
DEFINE_PROP_BIT64("hash", VirtIONet, host_features,
VIRTIO_NET_F_HASH_REPORT, false),
DEFINE_PROP_ARRAY("ebpf-rss-fds", VirtIONet, nr_ebpf_rss_fds,
- ebpf_rss_fds, qdev_prop_string, char*),
+ ebpf_rss_fds, qdev_prop_string),
DEFINE_PROP_BIT64("guest_rsc_ext", VirtIONet, host_features,
VIRTIO_NET_F_RSC_EXT, false),
DEFINE_PROP_UINT32("rsc_interval", VirtIONet, rsc_timeout,
@@ -267,7 +267,7 @@ static const Property efuse_properties[] = {
DEFINE_PROP_UINT32("efuse-size", XlnxEFuse, efuse_size, 64 * 32),
DEFINE_PROP_BOOL("init-factory-tbits", XlnxEFuse, init_tbits, true),
DEFINE_PROP_ARRAY("read-only", XlnxEFuse, ro_bits_cnt, ro_bits,
- qdev_prop_uint32, uint32_t),
+ qdev_prop_uint32),
};
static void efuse_class_init(ObjectClass *klass, const void *data)
@@ -740,7 +740,7 @@ static const Property efuse_ctrl_props[] = {
TYPE_XLNX_EFUSE, XlnxEFuse *),
DEFINE_PROP_ARRAY("pg0-lock",
XlnxVersalEFuseCtrl, extra_pg0_lock_n16,
- extra_pg0_lock_spec, qdev_prop_uint16, uint16_t),
+ extra_pg0_lock_spec, qdev_prop_uint16),
};
static void efuse_ctrl_class_init(ObjectClass *klass, const void *data)
@@ -48,11 +48,9 @@ static const Property riscv_harts_props[] = {
* defined by "rnmi-exception-vector".
*/
DEFINE_PROP_ARRAY("rnmi-interrupt-vector", RISCVHartArrayState,
- num_rnmi_irqvec, rnmi_irqvec, qdev_prop_uint64,
- uint64_t),
+ num_rnmi_irqvec, rnmi_irqvec, qdev_prop_uint64),
DEFINE_PROP_ARRAY("rnmi-exception-vector", RISCVHartArrayState,
- num_rnmi_excpvec, rnmi_excpvec, qdev_prop_uint64,
- uint64_t),
+ num_rnmi_excpvec, rnmi_excpvec, qdev_prop_uint64),
DEFINE_PROP_LINK("memory", RISCVHartArrayState, memory,
TYPE_MEMORY_REGION, MemoryRegion *),
};
@@ -38,7 +38,7 @@ static const Property virtio_iommu_pci_properties[] = {
DEFINE_PROP_UINT32("class", VirtIOPCIProxy, class_code, 0),
DEFINE_PROP_ARRAY("reserved-regions", VirtIOIOMMUPCI,
vdev.nr_prop_resv_regions, vdev.prop_resv_regions,
- qdev_prop_reserved_region, ReservedRegion),
+ qdev_prop_reserved_region),
};
static void virtio_iommu_pci_realize(VirtIOPCIProxy *vpci_dev, Error **errp)
@@ -23,7 +23,7 @@ static const Property my_dev_props[] = {
DEFINE_PROP_UINT32("u32", MyDev, prop_u32, 100),
DEFINE_PROP_STRING("string", MyDev, prop_string),
DEFINE_PROP_ARRAY("array-u32", MyDev, prop_array_u32_nb, prop_array_u32,
- qdev_prop_uint32, uint32_t),
+ qdev_prop_uint32),
};
static void my_dev_class_init(ObjectClass *oc, const void *data)
@@ -258,7 +258,7 @@ static void apple_gfx_mmio_reset(Object *obj, ResetType type)
static const Property apple_gfx_mmio_properties[] = {
DEFINE_PROP_ARRAY("display-modes", AppleGFXMMIOState,
common.num_display_modes, common.display_modes,
- qdev_prop_apple_gfx_display_mode, AppleGFXDisplayMode),
+ qdev_prop_apple_gfx_display_mode),
};
static void apple_gfx_mmio_class_init(ObjectClass *klass, const void *data)
@@ -118,7 +118,7 @@ static void apple_gfx_pci_reset(Object *obj, ResetType type)
static const Property apple_gfx_pci_properties[] = {
DEFINE_PROP_ARRAY("display-modes", AppleGFXPCIState,
common.num_display_modes, common.display_modes,
- qdev_prop_apple_gfx_display_mode, AppleGFXDisplayMode),
+ qdev_prop_apple_gfx_display_mode),
};
static void apple_gfx_pci_class_init(ObjectClass *klass, const void *data)