1 /* Declarations for use by board files for creating devices. */ 2 3 #ifndef HW_BOARDS_H 4 #define HW_BOARDS_H 5 6 #include "sysemu/blockdev.h" 7 #include "hw/qdev.h" 8 9 typedef struct QEMUMachineInitArgs { 10 ram_addr_t ram_size; 11 const char *boot_order; 12 const char *kernel_filename; 13 const char *kernel_cmdline; 14 const char *initrd_filename; 15 const char *cpu_model; 16 } QEMUMachineInitArgs; 17 18 typedef void QEMUMachineInitFunc(QEMUMachineInitArgs *args); 19 20 typedef void QEMUMachineResetFunc(void); 21 22 typedef void QEMUMachineHotAddCPUFunc(const int64_t id, Error **errp); 23 24 typedef struct QEMUMachine { 25 const char *name; 26 const char *alias; 27 const char *desc; 28 QEMUMachineInitFunc *init; 29 QEMUMachineResetFunc *reset; 30 QEMUMachineHotAddCPUFunc *hot_add_cpu; 31 BlockInterfaceType block_default_type; 32 int max_cpus; 33 unsigned int no_serial:1, 34 no_parallel:1, 35 use_virtcon:1, 36 use_sclp:1, 37 no_floppy:1, 38 no_cdrom:1, 39 no_sdcard:1; 40 int is_default; 41 const char *default_machine_opts; 42 const char *default_boot_order; 43 GlobalProperty *compat_props; 44 struct QEMUMachine *next; 45 const char *hw_version; 46 } QEMUMachine; 47 48 int qemu_register_machine(QEMUMachine *m); 49 QEMUMachine *find_default_machine(void); 50 51 extern QEMUMachine *current_machine; 52 53 #endif 54