[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Dynamic instance properties in TYPE_ARM_CPU

From: Eduardo Habkost
Subject: Dynamic instance properties in TYPE_ARM_CPU
Date: Mon, 26 Oct 2020 13:22:19 -0400

I've been trying to clean up the qdev property code (to bridge
the gaps between qdev and QOM, and between QOM and QAPI), and
I've noticed that TYPE_ARM_CPU is the only remaining user of

qdev_property_add_static() has a misleading name: it won't
register a static property.  It is actually a hack to use a
static Property variable (defined using DEFINE_PROP*), but
register it as a dynamic instance property.

Dynamic instance properties make introspection hard.  What can we
do to get rid of them in TYPE_ARM_CPU?

Can we just register all the properties unconditionally, and
error out on realize if the requested CPU configuration is
incompatible with the available CPU features?

The following properties are registered as dynamic instance
properties at arm_cpu_post_init():
"cntfrq", "reset-cbar", "reset-hivecs", "rvbar", "has_el2",
"has_el3", "cfgend", "vfp", "neon", "dsp", "has-mpu",
"pmsav7-dregion", "secure-memory", "pmu", "idau", "init-svtor",
"tag-memory", "secure-tag-memory".


reply via email to

[Prev in Thread] Current Thread [Next in Thread]