qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-ppc] [PATCH 2/2] bootdevice: update boot_order in MachineState


From: dvaleev
Subject: [Qemu-ppc] [PATCH 2/2] bootdevice: update boot_order in MachineState
Date: Tue, 27 Jan 2015 00:52:21 +0100

From: Dinar Valeev <address@hidden>

on sPAPR we need to update boot_order in MachineState in case it
got changed on reset.

Signed-off-by: Dinar Valeev <address@hidden>
---
 bootdevice.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/bootdevice.c b/bootdevice.c
index 5914417..4f11a06 100644
--- a/bootdevice.c
+++ b/bootdevice.c
@@ -26,6 +26,7 @@
 #include "qapi/visitor.h"
 #include "qemu/error-report.h"
 #include "hw/hw.h"
+#include "hw/boards.h"
 
 typedef struct FWBootEntry FWBootEntry;
 
@@ -50,6 +51,8 @@ void qemu_register_boot_set(QEMUBootSetHandler *func, void 
*opaque)
 void qemu_boot_set(const char *boot_order, Error **errp)
 {
     Error *local_err = NULL;
+    MachineState *machine = MACHINE(qdev_get_machine());
+    machine->boot_order = boot_order;
 
     if (!boot_set_handler) {
         error_setg(errp, "no function defined to set boot device list for"
-- 
2.1.2




reply via email to

[Prev in Thread] Current Thread [Next in Thread]