diff options
author | aurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-05-04 20:11:34 +0000 |
---|---|---|
committer | aurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-05-04 20:11:34 +0000 |
commit | 0ecdffbb60a2723779a37fa17b717d919d670336 (patch) | |
tree | 17aff64cd35df25fee555574ee67af87c5e48ff2 /monitor.c | |
parent | 4001a81e8e1af1e4bda63baa404a8ebb4919d1f9 (diff) |
Allow bootdevice change from the monitor
(Gildas Le Nadan)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4333 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'monitor.c')
-rw-r--r-- | monitor.c | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -1019,6 +1019,21 @@ static void do_ioport_read(int count, int format, int size, int addr, int has_in suffix, addr, size * 2, val); } +static void do_boot_set(const char *bootdevice) +{ + int res; + + if (qemu_boot_set_handler) { + res = qemu_boot_set_handler(bootdevice); + if (res == 0) + term_printf("boot device list now set to %s\n", bootdevice); + else + term_printf("setting boot device list failed with error %i\n", res); + } else { + term_printf("no function defined to set boot device list for this architecture\n"); + } +} + static void do_system_reset(void) { qemu_system_reset_request(); @@ -1369,6 +1384,8 @@ static term_cmd_t term_cmds[] = { "addr size file", "save to disk virtual memory dump starting at 'addr' of size 'size'", }, { "pmemsave", "lis", do_physical_memory_save, "addr size file", "save to disk physical memory dump starting at 'addr' of size 'size'", }, + { "boot_set", "s", do_boot_set, + "bootdevice", "define new values for the boot device list" }, #if defined(TARGET_I386) { "nmi", "i", do_inject_nmi, "cpu", "inject an NMI on the given CPU", }, |