diff mbox

[v1,2/3] vl.c: Add qemu_get_boot_opts()

Message ID 30d158f868d17a0866de29b5fcb255603dccdd4e.1397536761.git.peter.crosthwaite@xilinx.com
State New
Headers show

Commit Message

Peter Crosthwaite April 15, 2014, 6:44 a.m. UTC
Same basic idea as qemu_get_machine_opts().

Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
---

 include/sysemu/sysemu.h |  1 +
 vl.c                    | 11 +++++++++++
 2 files changed, 12 insertions(+)
diff mbox

Patch

diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h
index ba5c7f8..d41748d 100644
--- a/include/sysemu/sysemu.h
+++ b/include/sysemu/sysemu.h
@@ -198,6 +198,7 @@  char *get_boot_devices_list(size_t *size, bool ignore_suffixes);
 DeviceState *get_boot_device(uint32_t position);
 
 QemuOpts *qemu_get_machine_opts(void);
+QemuOpts *qemu_get_boot_opts(void);
 
 bool usb_enabled(bool default_usb);
 
diff --git a/vl.c b/vl.c
index bc12d0f..d761211 100644
--- a/vl.c
+++ b/vl.c
@@ -535,6 +535,17 @@  QemuOpts *qemu_get_machine_opts(void)
     return qemu_get_opts_nofail("machine");
 }
 
+/**
+ * Get boot options
+ *
+ * Returns: boot options (never null).
+ */
+
+QemuOpts *qemu_get_boot_opts(void)
+{
+    return qemu_get_opts_nofail("boot-opts");
+}
+
 const char *qemu_get_vm_name(void)
 {
     return qemu_name;