summaryrefslogtreecommitdiff
path: root/hw/usb/hcd-ehci-pci.c
AgeCommit message (Collapse)AuthorFilesLines
2014-02-10qdev:pci: refactor PCIDevice to use generic "hotpluggable" propertyIgor Mammedov1-1/+1
Get rid of PCIDevice specific PCIDeviceClass.no_hotplug and use generic DeviceClass.hotpluggable field instead. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2013-10-14hw: set interrupts using pci irq wrappersMarcel Apfelbaum1-1/+1
pci_set_irq and the other pci irq wrappers use PCI_INTERRUPT_PIN config register to compute device INTx pin to assert/deassert. An irq is allocated using pci_allocate_irq wrapper only if is needed by non pci devices. Removed irq related fields from state if not used anymore. Signed-off-by: Marcel Apfelbaum <marcel.a@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2013-07-29devices: Associate devices to their logical categoryMarcel Apfelbaum1-0/+2
The category will be used to sort the devices displayed in the command line help. Signed-off-by: Marcel Apfelbaum <marcel.a@redhat.com> Message-id: 1375107465-25767-4-git-send-email-marcel.a@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-06-24usb/hcd-ehci: Replace PORTSC macros with variablesKuo-Jung Su1-0/+2
Replace PORTSC macros with variables which could then be configured in ehci_xxxx_class_init(...) Signed-off-by: Kuo-Jung Su <dantesu@faraday-tech.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2013-06-24usb/hcd-ehci: Split off instance_init from realizeAndreas Färber1-5/+14
This makes the mem MemoryRegion available to derived instance_inits. Keep the bus in realize for now since naming breaks in instance_init. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2013-06-24usb/hcd-ehci-sysbus: Convert to QOM realizeAndreas Färber1-1/+1
The SysBus qdev initfn merely calls SysBusDeviceClass::init, so we can replace it with a realizefn already. This avoids getting into any initfn ambiguity with the upcoming Faraday EHCI implementation. Rename internal usb_ehci_initfn() to usb_ehci_realize() to allow to return Errors from common initialization code as well. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2013-06-20dma: eliminate DMAContextPaolo Bonzini1-2/+2
The DMAContext is a simple pointer to an AddressSpace that is now always already available. Make everyone hold the address space directly, and clean up the DMA API to use the AddressSpace directly. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-01-07usb/ehci: Clean up SysBus and PCI EHCI splitAndreas Färber1-15/+24
SysBus EHCI was introduced in a hurry before 1.3 Soft Freeze. To use QOM casts in place of DO_UPCAST() / FROM_SYSBUS(), we need an identifying type. Introduce generic abstract base types for PCI and SysBus EHCI to allow multiple types to access the shared fields. While at it, move the state structs being amended with macros to the header file so that they can be embedded. The VMSTATE_PCI_DEVICE() macro does not play nice with the QOM parent_obj naming convention, so defer that cleanup. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2012-12-19misc: move include files to include/qemu/Paolo Bonzini1-1/+1
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2012-12-17pci: update all users to look in pci/Michael S. Tsirkin1-1/+1
update all users so we can remove the makefile hack. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2012-11-29usb: tag usb host adapters as not hotpluggable.Gerd Hoffmann1-0/+1
Hotplugging them simply doesn't work, so tag them accordingly to avoid users trying and then crashing qemu. For xhci there is nothing fundamental which prevents hotplug from working, we'll "only" need a exit() function which cleans up everything properly. That isn't for 1.3 though. For ehci+uhci+ohci hotplug can't be supported until qemu gains the capability to hotplug multifunction pci devices. https://bugzilla.redhat.com/show_bug.cgi?id=879096 Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2012-11-16ehci: handle dma errorsGerd Hoffmann1-0/+17
Starting with commit 1c380f9460522f32c8dd2577b2a53d518ec91c6d dma transfers can actually fail. This patch makes ehci keep track of the busmaster bit in pci config space, by setting/clearing the dma_context pointer. Attempts to dma without context will result in raising HSE (Host System Error) interrupt and stopping the host controller. This patch fixes WinXP not booting with a usb stick attached to ehci. Root cause is seabios activating ehci so you can boot from the stick, and WinXP clearing the busmaster bit before resetting the host controller, leading to ehci actually trying dma while it is disabled. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2012-11-09ehci: fix migrationGerd Hoffmann1-1/+2
Commit 5010d4dc618b6b8e7c21129c487c06f6493f71fc reorganized vmstate to split core + pci, but got two little details wrong. Fix them. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2012-11-01usb/ehci-pci: add helper to create ich9 usb controllersGerd Hoffmann1-0/+53
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2012-11-01usb/ehci-pci: add ich9 00:1a.* variantGerd Hoffmann1-1/+6
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2012-11-01usb/ehci-pci: dynamic type generationGerd Hoffmann1-31/+35
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2012-11-01usb/ehci: split into multiple source filesGerd Hoffmann1-0/+138
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>