4 * Copyright IBM, Corp. 2012
7 * Anthony Liguori <aliguori@us.ibm.com>
9 * This work is licensed under the terms of the GNU GPL, version 2 or later.
10 * See the COPYING file in the top-level directory.
14 #include "qemu/osdep.h"
15 #include "qemu-common.h"
16 #include "qemu/error-report.h"
18 #include "hw/boards.h"
19 #include "sysemu/sysemu.h"
20 #include "exec/address-spaces.h"
23 static void machine_none_init(MachineState
*mch
)
27 /* Initialize CPU (if a model has been specified) */
29 cpu
= cpu_init(mch
->cpu_model
);
31 error_report("Unable to initialize CPU");
36 /* RAM at address zero */
38 MemoryRegion
*ram
= g_new(MemoryRegion
, 1);
40 memory_region_allocate_system_memory(ram
, NULL
, "ram", mch
->ram_size
);
41 memory_region_add_subregion(get_system_memory(), 0, ram
);
45 static void machine_none_machine_init(MachineClass
*mc
)
47 mc
->desc
= "empty machine";
48 mc
->init
= machine_none_init
;
50 mc
->default_ram_size
= 0;
53 DEFINE_MACHINE("none", machine_none_machine_init
)