[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 34/38] hw/vga-pci.c: convert to PCIDeviceInfo to
From: |
Isaku Yamahata |
Subject: |
[Qemu-devel] [PATCH v2 34/38] hw/vga-pci.c: convert to PCIDeviceInfo to initialize ids |
Date: |
Wed, 18 May 2011 01:55:51 +0900 |
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <address@hidden>
---
hw/vga-pci.c | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/hw/vga-pci.c b/hw/vga-pci.c
index ce9ec45..481f448 100644
--- a/hw/vga-pci.c
+++ b/hw/vga-pci.c
@@ -74,7 +74,6 @@ static int pci_vga_initfn(PCIDevice *dev)
{
PCIVGAState *d = DO_UPCAST(PCIVGAState, dev, dev);
VGACommonState *s = &d->vga;
- uint8_t *pci_conf = d->dev.config;
// vga + console init
vga_common_init(s, VGA_RAM_SIZE);
@@ -83,11 +82,6 @@ static int pci_vga_initfn(PCIDevice *dev)
s->ds = graphic_console_init(s->update, s->invalidate,
s->screen_dump, s->text_update, s);
- // dummy VGA (same as Bochs ID)
- pci_config_set_vendor_id(pci_conf, PCI_VENDOR_ID_QEMU);
- pci_config_set_device_id(pci_conf, PCI_DEVICE_ID_QEMU_VGA);
- pci_config_set_class(pci_conf, PCI_CLASS_DISPLAY_VGA);
-
/* XXX: VGA_RAM_SIZE must be a power of two */
pci_register_bar(&d->dev, 0, VGA_RAM_SIZE,
PCI_BASE_ADDRESS_MEM_PREFETCH, vga_map);
@@ -114,6 +108,11 @@ static PCIDeviceInfo vga_info = {
.init = pci_vga_initfn,
.config_write = pci_vga_write_config,
.romfile = "vgabios-stdvga.bin",
+
+ /* dummy VGA (same as Bochs ID) */
+ .vendor_id = PCI_VENDOR_ID_QEMU,
+ .device_id = PCI_DEVICE_ID_QEMU_VGA,
+ .class_id = PCI_CLASS_DISPLAY_VGA,
};
static void vga_register(void)
--
1.7.1.1
- [Qemu-devel] [PATCH v2 11/38] hw/cirrus_vga.c: convert to PCIDeviceInfo to initialize ids, (continued)
- [Qemu-devel] [PATCH v2 11/38] hw/cirrus_vga.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 36/38] hw/wdt_i6300esb.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 20/38] hw/ioh3420.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 05/38] apb_pci: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 23/38] hw/ne2000.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 28/38] hw/rtl8139.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 21/38] hw/ivshmem.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 32/38] hw/usb-ohci.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 33/38] hw/versatile_pci.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 26/38] hw/piix_pci.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 34/38] hw/vga-pci.c: convert to PCIDeviceInfo to initialize ids,
Isaku Yamahata <=
- [Qemu-devel] [PATCH v2 38/38] hw/xio3130_upstream.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 06/38] ide/piix: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 29/38] hw/sh_pci.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 27/38] hw/qxl.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 01/38] pci: move ids of config space into PCIDeviceInfo, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 31/38] hw/unin_pci.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 24/38] hw/pcnet-pci.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 16/38] hw/ide/cmd646.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 18/38] hw/ide/via.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17
- [Qemu-devel] [PATCH v2 13/38] hw/es1370.c: convert to PCIDeviceInfo to initialize ids, Isaku Yamahata, 2011/05/17