qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Glauber Costa <glommer@redhat.com>
To: qemu-devel@nongnu.org
Cc: aliguori@us.ibm.com
Subject: [Qemu-devel] [PATCH v2 1/2] early set current_machine
Date: Tue,  1 Jun 2010 13:56:15 -0400	[thread overview]
Message-ID: <1275414976-18258-2-git-send-email-glommer@redhat.com> (raw)
In-Reply-To: <1275414976-18258-1-git-send-email-glommer@redhat.com>

this way, the machine_init function itself can know which machine is current
in use, not only the late init code.
Signed-off-by: Glauber Costa <glommer@redhat.com>
---
 vl.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/vl.c b/vl.c
index 96838f8..7a8b20b 100644
--- a/vl.c
+++ b/vl.c
@@ -5824,6 +5824,9 @@ int main(int argc, char **argv, char **envp)
     if (machine->compat_props) {
         qdev_prop_register_compat(machine->compat_props);
     }
+
+    current_machine = machine;
+
     machine->init(ram_size, boot_devices,
                   kernel_filename, kernel_cmdline, initrd_filename, cpu_model);
 
@@ -5841,8 +5844,6 @@ int main(int argc, char **argv, char **envp)
         }
     }
 
-    current_machine = machine;
-
     /* init USB devices */
     if (usb_enabled) {
         if (foreach_device_config(DEV_USB, usb_parse) < 0)
-- 
1.6.2.2

  reply	other threads:[~2010-06-01 18:04 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-01 17:56 [Qemu-devel] [PATCH v2 0/2] basic machine opts framework Glauber Costa
2010-06-01 17:56 ` Glauber Costa [this message]
2010-06-01 17:56   ` [Qemu-devel] [PATCH v2 2/2] " Glauber Costa
2010-06-02  7:15     ` [Qemu-devel] " Jan Kiszka
2010-06-02 14:06       ` Glauber Costa
2010-06-03  6:07         ` Jan Kiszka
2010-06-03 13:11           ` Anthony Liguori
2010-06-03  9:02         ` Paul Brook
2010-06-03 14:13     ` Anthony Liguori
2010-06-03 13:14   ` [Qemu-devel] Re: [PATCH v2 1/2] early set current_machine Anthony Liguori

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1275414976-18258-2-git-send-email-glommer@redhat.com \
    --to=glommer@redhat.com \
    --cc=aliguori@us.ibm.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).