qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: qemu-devel@nongnu.org
Cc: Anthony Liguori <aliguori@us.ibm.com>
Subject: [Qemu-devel] [PULL 5/5] pc: don't access fw cfg if NULL
Date: Wed, 17 Jul 2013 12:48:12 +0300	[thread overview]
Message-ID: <1374054430-21966-6-git-send-email-mst@redhat.com> (raw)
In-Reply-To: <1374054430-21966-1-git-send-email-mst@redhat.com>

commit f8c457b88d72a48989f190bc3d7b79f4f3b7d11c
     "pc: pass PCI hole ranges to Guests"
broke Xen as it has no fw_cfg.
Check for this configuration and boil out.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Tested-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
---
 hw/i386/pc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/i386/pc.c b/hw/i386/pc.c
index 80c27d6..cb3897e 100644
--- a/hw/i386/pc.c
+++ b/hw/i386/pc.c
@@ -1000,7 +1000,7 @@ typedef struct PcRomPciInfo {
 static void pc_fw_cfg_guest_info(PcGuestInfo *guest_info)
 {
     PcRomPciInfo *info;
-    if (!guest_info->has_pci_info) {
+    if (!guest_info->has_pci_info || !guest_info->fw_cfg) {
         return;
     }
 
-- 
MST

      parent reply	other threads:[~2013-07-17  9:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-17  9:47 [Qemu-devel] [PULL 0/5] pci,net,pc enhancements Michael S. Tsirkin
2013-07-17  9:48 ` [Qemu-devel] [PULL 1/5] pci-bridge: update mappings for migration/restore Michael S. Tsirkin
2013-07-17  9:48 ` [Qemu-devel] [PULL 2/5] pci: fix BRDIGE typo Michael S. Tsirkin
2013-07-17  9:48 ` [Qemu-devel] [PULL 3/5] net: add support of mac-programming over macvtap in QEMU side Michael S. Tsirkin
2013-07-17  9:48 ` [Qemu-devel] [PULL 4/5] virtio-net: add feature bit for any header s/g Michael S. Tsirkin
2013-07-17  9:48 ` Michael S. Tsirkin [this message]

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=1374054430-21966-6-git-send-email-mst@redhat.com \
    --to=mst@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).