Received: from eggs.gnu.org ([2001:4830:134:3::10]:48718) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UxFpH-0005cf-9y for qemu-devel@nongnu.org; Thu, 11 Jul 2013 08:18:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UxFpF-0005Y2-VP for qemu-devel@nongnu.org; Thu, 11 Jul 2013 08:18:23 -0400 Received: from mx1.redhat.com ([209.132.183.28]:12250) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UxFpF-0005Xr-O1 for qemu-devel@nongnu.org; Thu, 11 Jul 2013 08:18:21 -0400 Date: Thu, 11 Jul 2013 14:18:16 +0200 From: Igor Mammedov Message-ID: <20130711141816.0152e4bc@nial.usersys.redhat.com> In-Reply-To: <20130711115240.GA24956@redhat.com> References: <20130711115240.GA24956@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] pc: don't access fw cfg if NULL List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Michael S. Tsirkin" Cc: Paolo Bonzini , Anthony Liguori , Stefano Stabellini , qemu-devel@nongnu.org, Andreas =?ISO-8859-1?B?RuRyYmVy?= On Thu, 11 Jul 2013 14:52:40 +0300 "Michael S. Tsirkin" wrote: > 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 > Tested-by: Stefano Stabellini > > --- > > Anthony, could you fast-track this into master please? > Thanks! > > 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 9f9207d..c7fc475 100644 > --- a/hw/i386/pc.c > +++ b/hw/i386/pc.c > @@ -999,7 +999,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; > } > Reviewed-By: Igor Mammedov