1 #ifndef QEMU_TYPEDEFS_H
2 #define QEMU_TYPEDEFS_H
3 
4 /*
5  * This header is for selectively avoiding #include just to get a
6  * typedef name.
7  *
8  * Declaring a typedef name in its "obvious" place can result in
9  * inclusion cycles, in particular for complete struct and union
10  * types that need more types for their members.  It can also result
11  * in headers pulling in many more headers, slowing down builds.
12  *
13  * You can break such cycles and unwanted dependencies by declaring
14  * the typedef name here.
15  *
16  * For struct types used in only a few headers, judicious use of the
17  * struct tag instead of the typedef name is commonly preferable.
18  */
19 
20 /*
21  * Incomplete struct types
22  * Please keep this list in case-insensitive alphabetical order.
23  */
24 typedef struct AdapterInfo AdapterInfo;
25 typedef struct AddressSpace AddressSpace;
26 typedef struct AioContext AioContext;
27 typedef struct AnnounceTimer AnnounceTimer;
28 typedef struct BdrvDirtyBitmap BdrvDirtyBitmap;
29 typedef struct BdrvDirtyBitmapIter BdrvDirtyBitmapIter;
30 typedef struct BlockBackend BlockBackend;
31 typedef struct BlockBackendRootState BlockBackendRootState;
32 typedef struct BlockDriverState BlockDriverState;
33 typedef struct BusClass BusClass;
34 typedef struct BusState BusState;
35 typedef struct Chardev Chardev;
36 typedef struct CompatProperty CompatProperty;
37 typedef struct CoMutex CoMutex;
38 typedef struct CPUAddressSpace CPUAddressSpace;
39 typedef struct CPUState CPUState;
40 typedef struct DeviceListener DeviceListener;
41 typedef struct DeviceState DeviceState;
42 typedef struct DirtyBitmapSnapshot DirtyBitmapSnapshot;
43 typedef struct DisplayChangeListener DisplayChangeListener;
44 typedef struct DriveInfo DriveInfo;
45 typedef struct Error Error;
46 typedef struct EventNotifier EventNotifier;
47 typedef struct FlatView FlatView;
48 typedef struct FWCfgEntry FWCfgEntry;
49 typedef struct FWCfgIoState FWCfgIoState;
50 typedef struct FWCfgMemState FWCfgMemState;
51 typedef struct FWCfgState FWCfgState;
52 typedef struct HostMemoryBackend HostMemoryBackend;
53 typedef struct HVFX86EmulatorState HVFX86EmulatorState;
54 typedef struct I2CBus I2CBus;
55 typedef struct I2SCodec I2SCodec;
56 typedef struct IOMMUMemoryRegion IOMMUMemoryRegion;
57 typedef struct ISABus ISABus;
58 typedef struct ISADevice ISADevice;
59 typedef struct IsaDma IsaDma;
60 typedef struct MACAddr MACAddr;
61 typedef struct MachineClass MachineClass;
62 typedef struct MachineState MachineState;
63 typedef struct MemoryListener MemoryListener;
64 typedef struct MemoryMappingList MemoryMappingList;
65 typedef struct MemoryRegion MemoryRegion;
66 typedef struct MemoryRegionCache MemoryRegionCache;
67 typedef struct MemoryRegionSection MemoryRegionSection;
68 typedef struct MigrationIncomingState MigrationIncomingState;
69 typedef struct MigrationState MigrationState;
70 typedef struct Monitor Monitor;
71 typedef struct MonitorDef MonitorDef;
72 typedef struct MSIMessage MSIMessage;
73 typedef struct NetClientState NetClientState;
74 typedef struct NetFilterState NetFilterState;
75 typedef struct NICInfo NICInfo;
76 typedef struct NodeInfo NodeInfo;
77 typedef struct NumaNodeMem NumaNodeMem;
78 typedef struct ObjectClass ObjectClass;
79 typedef struct PCIBridge PCIBridge;
80 typedef struct PCIBus PCIBus;
81 typedef struct PCIDevice PCIDevice;
82 typedef struct PCIEAERErr PCIEAERErr;
83 typedef struct PCIEAERLog PCIEAERLog;
84 typedef struct PCIEAERMsg PCIEAERMsg;
85 typedef struct PCIEPort PCIEPort;
86 typedef struct PCIESlot PCIESlot;
87 typedef struct PCIExpressDevice PCIExpressDevice;
88 typedef struct PCIExpressHost PCIExpressHost;
89 typedef struct PCIHostDeviceAddress PCIHostDeviceAddress;
90 typedef struct PCIHostState PCIHostState;
91 typedef struct PCMachineState PCMachineState;
92 typedef struct PostcopyDiscardState PostcopyDiscardState;
93 typedef struct Property Property;
94 typedef struct PropertyInfo PropertyInfo;
95 typedef struct QBool QBool;
96 typedef struct QDict QDict;
97 typedef struct QEMUBH QEMUBH;
98 typedef struct QemuConsole QemuConsole;
99 typedef struct QEMUFile QEMUFile;
100 typedef struct QemuLockable QemuLockable;
101 typedef struct QemuMutex QemuMutex;
102 typedef struct QemuOpt QemuOpt;
103 typedef struct QemuOpts QemuOpts;
104 typedef struct QemuOptsList QemuOptsList;
105 typedef struct QEMUSGList QEMUSGList;
106 typedef struct QemuSpin QemuSpin;
107 typedef struct QEMUTimer QEMUTimer;
108 typedef struct QEMUTimerListGroup QEMUTimerListGroup;
109 typedef struct QJSON QJSON;
110 typedef struct QList QList;
111 typedef struct QNull QNull;
112 typedef struct QNum QNum;
113 typedef struct QObject QObject;
114 typedef struct QString QString;
115 typedef struct RAMBlock RAMBlock;
116 typedef struct Range Range;
117 typedef struct SHPCDevice SHPCDevice;
118 typedef struct SSIBus SSIBus;
119 typedef struct VirtIODevice VirtIODevice;
120 typedef struct Visitor Visitor;
121 typedef struct VMChangeStateEntry VMChangeStateEntry;
122 typedef struct VMStateDescription VMStateDescription;
123 
124 /*
125  * Pointer types
126  * Such typedefs should be limited to cases where the typedef's users
127  * are oblivious of its "pointer-ness".
128  * Please keep this list in case-insensitive alphabetical order.
129  */
130 typedef struct IRQState *qemu_irq;
131 
132 /*
133  * Function types
134  */
135 typedef void SaveStateHandler(QEMUFile *f, void *opaque);
136 typedef int LoadStateHandler(QEMUFile *f, void *opaque, int version_id);
137 typedef void (*qemu_irq_handler)(void *opaque, int n, int level);
138 
139 #endif /* QEMU_TYPEDEFS_H */
140