mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 17:23:56 -06:00
Use OBJECT_DECLARE_SIMPLE_TYPE when possible
This converts existing DECLARE_INSTANCE_CHECKER usage to OBJECT_DECLARE_SIMPLE_TYPE when possible. $ ./scripts/codeconverter/converter.py -i \ --pattern=AddObjectDeclareSimpleType $(git grep -l '' -- '*.[ch]') Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Acked-by: Paul Durrant <paul@xen.org> Message-Id: <20200916182519.415636-6-ehabkost@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
This commit is contained in:
parent
a489d1951c
commit
8063396bf3
505 changed files with 609 additions and 1795 deletions
|
@ -29,9 +29,7 @@
|
|||
#include "qom/object.h"
|
||||
|
||||
#define TYPE_INTEGRATOR_CM "integrator_core"
|
||||
typedef struct IntegratorCMState IntegratorCMState;
|
||||
DECLARE_INSTANCE_CHECKER(IntegratorCMState, INTEGRATOR_CM,
|
||||
TYPE_INTEGRATOR_CM)
|
||||
OBJECT_DECLARE_SIMPLE_TYPE(IntegratorCMState, INTEGRATOR_CM)
|
||||
|
||||
struct IntegratorCMState {
|
||||
/*< private >*/
|
||||
|
@ -328,9 +326,7 @@ static void integratorcm_realize(DeviceState *d, Error **errp)
|
|||
/* Primary interrupt controller. */
|
||||
|
||||
#define TYPE_INTEGRATOR_PIC "integrator_pic"
|
||||
typedef struct icp_pic_state icp_pic_state;
|
||||
DECLARE_INSTANCE_CHECKER(icp_pic_state, INTEGRATOR_PIC,
|
||||
TYPE_INTEGRATOR_PIC)
|
||||
OBJECT_DECLARE_SIMPLE_TYPE(icp_pic_state, INTEGRATOR_PIC)
|
||||
|
||||
struct icp_pic_state {
|
||||
/*< private >*/
|
||||
|
@ -468,9 +464,7 @@ static void icp_pic_init(Object *obj)
|
|||
/* CP control registers. */
|
||||
|
||||
#define TYPE_ICP_CONTROL_REGS "icp-ctrl-regs"
|
||||
typedef struct ICPCtrlRegsState ICPCtrlRegsState;
|
||||
DECLARE_INSTANCE_CHECKER(ICPCtrlRegsState, ICP_CONTROL_REGS,
|
||||
TYPE_ICP_CONTROL_REGS)
|
||||
OBJECT_DECLARE_SIMPLE_TYPE(ICPCtrlRegsState, ICP_CONTROL_REGS)
|
||||
|
||||
struct ICPCtrlRegsState {
|
||||
/*< private >*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue