From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:54382) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWXaw-00054Z-VJ for qemu-devel@nongnu.org; Tue, 14 Jun 2011 13:40:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QWXav-0006uM-30 for qemu-devel@nongnu.org; Tue, 14 Jun 2011 13:40:06 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52129) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWXau-0006uD-FR for qemu-devel@nongnu.org; Tue, 14 Jun 2011 13:40:04 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p5EHe3eM015421 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 14 Jun 2011 13:40:03 -0400 Date: Tue, 14 Jun 2011 20:40:20 +0300 From: "Michael S. Tsirkin" Message-ID: <20110614174020.GA13285@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Subject: [Qemu-devel] [PATCH] usb-ehci: move device/vendor/class id to qdev List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gerd Hoffmann This is on top of my pci tree. Signed-off-by: Michael S. Tsirkin --- hw/usb-ehci.c | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) diff --git a/hw/usb-ehci.c b/hw/usb-ehci.c index f63519e..4d6989a 100644 --- a/hw/usb-ehci.c +++ b/hw/usb-ehci.c @@ -1945,6 +1945,10 @@ static PCIDeviceInfo ehci_info = { .qdev.name = "usb-ehci", .qdev.size = sizeof(EHCIState), .init = usb_ehci_initfn, + .vendor_id = PCI_VENDOR_ID_INTEL, + .device_id = PCI_DEVICE_ID_INTEL_82801D, + .revision = 0x10, + .class_id = PCI_CLASS_SERIAL_USB, }; static int usb_ehci_initfn(PCIDevice *dev) @@ -1953,12 +1957,7 @@ static int usb_ehci_initfn(PCIDevice *dev) uint8_t *pci_conf = s->dev.config; int i; - pci_config_set_vendor_id(pci_conf, PCI_VENDOR_ID_INTEL); - pci_config_set_device_id(pci_conf, PCI_DEVICE_ID_INTEL_82801D); - pci_set_byte(&pci_conf[PCI_REVISION_ID], 0x10); pci_set_byte(&pci_conf[PCI_CLASS_PROG], 0x20); - pci_config_set_class(pci_conf, PCI_CLASS_SERIAL_USB); - pci_set_byte(&pci_conf[PCI_HEADER_TYPE], PCI_HEADER_TYPE_NORMAL); /* capabilities pointer */ pci_set_byte(&pci_conf[PCI_CAPABILITY_LIST], 0x00); -- 1.7.5.53.gc233e