mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
Make default boot order machine specific
This patch makes default boot order machine specific instead of set globally. The default boot order can be set per machine in QEMUMachine boot_order. This also allows a machine to receive a NULL boot order when -boot isn't used and take an appropriate action accordingly. This helps machine boots from the devices as set in guest's non-volatile memory location in case no boot order is provided by the user. Reviewed-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Avik Sil <aviksil@linux.vnet.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
committed by
Anthony Liguori
parent
038794cfe1
commit
e4ada29e90
@@ -171,6 +171,7 @@ static QEMUMachine clipper_machine = {
|
||||
.init = clipper_init,
|
||||
.max_cpus = 4,
|
||||
.is_default = 1,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void clipper_machine_init(void)
|
||||
|
||||
@@ -86,6 +86,7 @@ static QEMUMachine an5206_machine = {
|
||||
.name = "an5206",
|
||||
.desc = "Arnewsh 5206",
|
||||
.init = an5206_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void an5206_machine_init(void)
|
||||
|
||||
@@ -355,6 +355,7 @@ static QEMUMachine axisdev88_machine = {
|
||||
.desc = "AXIS devboard 88",
|
||||
.init = axisdev88_init,
|
||||
.is_default = 1,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void axisdev88_machine_init(void)
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
#include "sysemu/blockdev.h"
|
||||
#include "qdev.h"
|
||||
|
||||
#define DEFAULT_MACHINE_OPTIONS \
|
||||
.boot_order = "cad"
|
||||
|
||||
typedef struct QEMUMachineInitArgs {
|
||||
ram_addr_t ram_size;
|
||||
const char *boot_device;
|
||||
@@ -35,6 +38,7 @@ typedef struct QEMUMachine {
|
||||
no_sdcard:1;
|
||||
int is_default;
|
||||
const char *default_machine_opts;
|
||||
const char *boot_order;
|
||||
GlobalProperty *compat_props;
|
||||
struct QEMUMachine *next;
|
||||
const char *hw_version;
|
||||
|
||||
@@ -62,6 +62,7 @@ static QEMUMachine collie_machine = {
|
||||
.name = "collie",
|
||||
.desc = "Collie PDA (SA-1110)",
|
||||
.init = collie_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void collie_machine_init(void)
|
||||
|
||||
@@ -73,6 +73,7 @@ static QEMUMachine dummy_m68k_machine = {
|
||||
.name = "dummy",
|
||||
.desc = "Dummy board",
|
||||
.init = dummy_m68k_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void dummy_m68k_machine_init(void)
|
||||
|
||||
@@ -150,12 +150,14 @@ static QEMUMachine exynos4_machines[EXYNOS4_NUM_OF_BOARDS] = {
|
||||
.desc = "Samsung NURI board (Exynos4210)",
|
||||
.init = nuri_init,
|
||||
.max_cpus = EXYNOS4210_NCPUS,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
},
|
||||
[EXYNOS4_BOARD_SMDKC210] = {
|
||||
.name = "smdkc210",
|
||||
.desc = "Samsung SMDKC210 board (Exynos4210)",
|
||||
.init = smdkc210_init,
|
||||
.max_cpus = EXYNOS4210_NCPUS,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
@@ -122,12 +122,14 @@ static QEMUMachine connex_machine = {
|
||||
.name = "connex",
|
||||
.desc = "Gumstix Connex (PXA255)",
|
||||
.init = connex_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static QEMUMachine verdex_machine = {
|
||||
.name = "verdex",
|
||||
.desc = "Gumstix Verdex (PXA270)",
|
||||
.init = verdex_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void gumstix_machine_init(void)
|
||||
|
||||
@@ -331,6 +331,7 @@ static QEMUMachine highbank_machine = {
|
||||
.init = highbank_init,
|
||||
.block_default_type = IF_SCSI,
|
||||
.max_cpus = 4,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void highbank_machine_init(void)
|
||||
|
||||
@@ -512,6 +512,7 @@ static QEMUMachine integratorcp_machine = {
|
||||
.desc = "ARM Integrator/CP (ARM926EJ-S)",
|
||||
.init = integratorcp_init,
|
||||
.is_default = 1,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void integratorcp_machine_init(void)
|
||||
|
||||
@@ -146,6 +146,7 @@ static QEMUMachine kzm_machine = {
|
||||
.name = "kzm",
|
||||
.desc = "ARM KZM Emulation Baseboard (ARM1136)",
|
||||
.init = kzm_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void kzm_machine_init(void)
|
||||
|
||||
@@ -212,6 +212,7 @@ static QEMUMachine leon3_generic_machine = {
|
||||
.name = "leon3_generic",
|
||||
.desc = "Leon-3 generic",
|
||||
.init = leon3_generic_hw_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void leon3_machine_init(void)
|
||||
|
||||
+4
-2
@@ -287,14 +287,16 @@ static QEMUMachine lm32_evr_machine = {
|
||||
.name = "lm32-evr",
|
||||
.desc = "LatticeMico32 EVR32 eval system",
|
||||
.init = lm32_evr_init,
|
||||
.is_default = 1
|
||||
.is_default = 1,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static QEMUMachine lm32_uclinux_machine = {
|
||||
.name = "lm32-uclinux",
|
||||
.desc = "lm32 platform for uClinux and u-boot by Theobroma Systems",
|
||||
.init = lm32_uclinux_init,
|
||||
.is_default = 0
|
||||
.is_default = 0,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void lm32_machine_init(void)
|
||||
|
||||
@@ -179,6 +179,7 @@ static QEMUMachine mainstone2_machine = {
|
||||
.name = "mainstone",
|
||||
.desc = "Mainstone II (PXA27x)",
|
||||
.init = mainstone_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void mainstone_machine_init(void)
|
||||
|
||||
@@ -292,6 +292,7 @@ static QEMUMachine mcf5208evb_machine = {
|
||||
.desc = "MCF5206EVB",
|
||||
.init = mcf5208evb_init,
|
||||
.is_default = 1,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void mcf5208evb_machine_init(void)
|
||||
|
||||
+2
-1
@@ -206,7 +206,8 @@ static QEMUMachine milkymist_machine = {
|
||||
.name = "milkymist",
|
||||
.desc = "Milkymist One",
|
||||
.init = milkymist_init,
|
||||
.is_default = 0
|
||||
.is_default = 0,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void milkymist_machine_init(void)
|
||||
|
||||
@@ -400,6 +400,7 @@ static QEMUMachine mips_fulong2e_machine = {
|
||||
.name = "fulong2e",
|
||||
.desc = "Fulong 2e mini pc",
|
||||
.init = mips_fulong2e_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void mips_fulong2e_machine_init(void)
|
||||
|
||||
@@ -325,6 +325,7 @@ static QEMUMachine mips_magnum_machine = {
|
||||
.desc = "MIPS Magnum",
|
||||
.init = mips_magnum_init,
|
||||
.block_default_type = IF_SCSI,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static QEMUMachine mips_pica61_machine = {
|
||||
@@ -332,6 +333,7 @@ static QEMUMachine mips_pica61_machine = {
|
||||
.desc = "Acer Pica 61",
|
||||
.init = mips_pica61_init,
|
||||
.block_default_type = IF_SCSI,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void mips_jazz_machine_init(void)
|
||||
|
||||
@@ -1020,6 +1020,7 @@ static QEMUMachine mips_malta_machine = {
|
||||
.init = mips_malta_init,
|
||||
.max_cpus = 16,
|
||||
.is_default = 1,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void mips_malta_register_types(void)
|
||||
|
||||
@@ -229,6 +229,7 @@ static QEMUMachine mips_mipssim_machine = {
|
||||
.name = "mipssim",
|
||||
.desc = "MIPS MIPSsim platform",
|
||||
.init = mips_mipssim_init,
|
||||
DEFAULT_MACHINE_OPTIONS,
|
||||
};
|
||||
|
||||
static void mips_mipssim_machine_init(void)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user