From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MWSlc-0005xZ-EQ for qemu-devel@nongnu.org; Thu, 30 Jul 2009 06:21:44 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MWSlY-0005wZ-PM for qemu-devel@nongnu.org; Thu, 30 Jul 2009 06:21:44 -0400 Received: from [199.232.76.173] (port=34955 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MWSlY-0005wT-C4 for qemu-devel@nongnu.org; Thu, 30 Jul 2009 06:21:40 -0400 Received: from mx20.gnu.org ([199.232.41.8]:26520) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MWSlY-0000OC-1t for qemu-devel@nongnu.org; Thu, 30 Jul 2009 06:21:40 -0400 Received: from mx2.redhat.com ([66.187.237.31]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MWSlX-0001TA-5T for qemu-devel@nongnu.org; Thu, 30 Jul 2009 06:21:39 -0400 Received: from int-mx2.corp.redhat.com (int-mx2.corp.redhat.com [172.16.27.26]) by mx2.redhat.com (8.13.8/8.13.8) with ESMTP id n6UAK9Mx003258 for ; Thu, 30 Jul 2009 06:20:09 -0400 From: Zachary Amsden Date: Thu, 30 Jul 2009 00:15:10 -1000 Message-Id: <1248948912-7877-13-git-send-email-zamsden@redhat.com> In-Reply-To: <1248948912-7877-12-git-send-email-zamsden@redhat.com> References: <1248948912-7877-1-git-send-email-zamsden@redhat.com> <1248948912-7877-2-git-send-email-zamsden@redhat.com> <1248948912-7877-3-git-send-email-zamsden@redhat.com> <1248948912-7877-4-git-send-email-zamsden@redhat.com> <1248948912-7877-5-git-send-email-zamsden@redhat.com> <1248948912-7877-6-git-send-email-zamsden@redhat.com> <1248948912-7877-7-git-send-email-zamsden@redhat.com> <1248948912-7877-8-git-send-email-zamsden@redhat.com> <1248948912-7877-9-git-send-email-zamsden@redhat.com> <1248948912-7877-10-git-send-email-zamsden@redhat.com> <1248948912-7877-11-git-send-email-zamsden@redhat.com> <1248948912-7877-12-git-send-email-zamsden@redhat.com> Subject: [Qemu-devel] [PATCH 12/14] Add a PCI BAR for the VGA ROM which is mapped into cirrus_vga. This makes the cirrus device complete under some X servers which require the V_BIOS mapping. List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: zamsden@redhat.com Signed-off-by: Zachary Amsden --- hw/cirrus_vga.c | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/hw/cirrus_vga.c b/hw/cirrus_vga.c index 9623820..d7874f0 100644 --- a/hw/cirrus_vga.c +++ b/hw/cirrus_vga.c @@ -3288,6 +3288,12 @@ static void cirrus_pci_mmio_map(PCIDevice *d, int region_num, s->cirrus_mmio_io_addr); } +static void cirrus_pci_rom_map(PCIDevice *d, int region_num, + uint32_t addr, uint32_t size, int type) +{ + cpu_register_physical_memory(addr, 0x10000, 0xc0000 | IO_MEM_ROM); +} + static void pci_cirrus_write_config(PCIDevice *d, uint32_t address, uint32_t val, int len) { @@ -3341,5 +3347,6 @@ void pci_cirrus_vga_init(PCIBus *bus) pci_register_bar((PCIDevice *)d, 1, CIRRUS_PNPMMIO_SIZE, PCI_ADDRESS_SPACE_MEM, cirrus_pci_mmio_map); } - /* XXX: ROM BIOS */ + pci_register_bar((PCIDevice *)d, PCI_ROM_SLOT, 0x10000, + PCI_ADDRESS_SPACE_MEM, cirrus_pci_rom_map); } -- 1.6.2.5