aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorIsaku Yamahata <yamahata@valinux.co.jp>2011-05-25 10:58:14 +0900
committerMichael S. Tsirkin <mst@redhat.com>2011-06-12 10:33:35 +0300
commit03f1c14379d74b0c76a368681843c7c47c1e0627 (patch)
treeba154cf8f82e8bb5161e52085571f641c76b9994 /hw
parentc04ca0756da8087e15579915d55fdca816c9ef4e (diff)
hw/ide/ich.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r--hw/ide/ich.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/hw/ide/ich.c b/hw/ide/ich.c
index 5ce0a88800..976cc9244b 100644
--- a/hw/ide/ich.c
+++ b/hw/ide/ich.c
@@ -79,11 +79,6 @@ static int pci_ich9_ahci_init(PCIDevice *dev)
ahci_init(&d->ahci, &dev->qdev, 6);
- pci_config_set_vendor_id(d->card.config, PCI_VENDOR_ID_INTEL);
- pci_config_set_device_id(d->card.config, PCI_DEVICE_ID_INTEL_82801IR);
-
- pci_config_set_class(d->card.config, PCI_CLASS_STORAGE_SATA);
- pci_config_set_revision(d->card.config, 0x02);
pci_config_set_prog_interface(d->card.config, AHCI_PROGMODE_MAJOR_REV_1);
d->card.config[PCI_CACHE_LINE_SIZE] = 0x08; /* Cache line size */
@@ -131,6 +126,10 @@ static PCIDeviceInfo ich_ahci_info[] = {
.init = pci_ich9_ahci_init,
.exit = pci_ich9_uninit,
.config_write = pci_ich9_write_config,
+ .vendor_id = PCI_VENDOR_ID_INTEL,
+ .device_id = PCI_DEVICE_ID_INTEL_82801IR,
+ .revision = 0x02,
+ .class_id = PCI_CLASS_STORAGE_SATA,
},{
/* end of list */
}