]> git.proxmox.com Git - qemu.git/blob - hw/boards.h
qemu-ga: Fix unchecked strdup() by converting to g_strdup()
[qemu.git] / hw / boards.h
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 "qdev.h"
8
9 #define DEFAULT_MACHINE_OPTIONS \
10 .boot_order = "cad"
11
12 typedef struct QEMUMachineInitArgs {
13 ram_addr_t ram_size;
14 const char *boot_device;
15 const char *kernel_filename;
16 const char *kernel_cmdline;
17 const char *initrd_filename;
18 const char *cpu_model;
19 } QEMUMachineInitArgs;
20
21 typedef void QEMUMachineInitFunc(QEMUMachineInitArgs *args);
22
23 typedef void QEMUMachineResetFunc(void);
24
25 typedef struct QEMUMachine {
26 const char *name;
27 const char *alias;
28 const char *desc;
29 QEMUMachineInitFunc *init;
30 QEMUMachineResetFunc *reset;
31 BlockInterfaceType block_default_type;
32 int max_cpus;
33 unsigned int no_serial:1,
34 no_parallel:1,
35 use_virtcon:1,
36 no_floppy:1,
37 no_cdrom:1,
38 no_sdcard:1;
39 int is_default;
40 const char *default_machine_opts;
41 const char *boot_order;
42 GlobalProperty *compat_props;
43 struct QEMUMachine *next;
44 const char *hw_version;
45 } QEMUMachine;
46
47 int qemu_register_machine(QEMUMachine *m);
48 QEMUMachine *find_default_machine(void);
49
50 extern QEMUMachine *current_machine;
51
52 #endif