- 12 6月, 2015 1 次提交
-
-
由 Gerd Hoffmann 提交于
Some convinience fluff: Add support for '-vga virtio', also add virtio-vga to the list of vga cards so '-device virtio-vga' will turn off the default vga. Written by Dave Airlie and Gerd Hoffmann. Signed-off-by: NDave Airlie <airlied@redhat.com> Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
-
- 04 6月, 2015 6 次提交
-
-
由 Michael Roth 提交于
We need to work with PCI BARs to generate OF properties during PCI hotplug for sPAPR guests. Signed-off-by: NMichael Roth <mdroth@linux.vnet.ibm.com> Reviewed-by: NDavid Gibson <david@gibson.dropbear.id.au> Acked-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au> Signed-off-by: NAlexander Graf <agraf@suse.de>
-
由 Marcel Apfelbaum 提交于
PCI root buses can be attached to a specific NUMA node. PCI buses are not attached by default to a NUMA node. Signed-off-by: NMarcel Apfelbaum <marcel@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NLaszlo Ersek <lersek@redhat.com>
-
由 Marcel Apfelbaum 提交于
Use the newer pci_bus_num to correctly get the root bus number. Signed-off-by: NMarcel Apfelbaum <marcel@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NLaszlo Ersek <lersek@redhat.com>
-
由 Marcel Apfelbaum 提交于
PXB buses are assumed to be children of bus 0. Look for them while scanning the buses. Signed-off-by: NMarcel Apfelbaum <marcel@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NLaszlo Ersek <lersek@redhat.com>
-
由 Marcel Apfelbaum 提交于
Refactoring it as a method of PCIBusClass will allow different implementations for subclasses. Signed-off-by: NMarcel Apfelbaum <marcel@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NLaszlo Ersek <lersek@redhat.com>
-
由 Marcel Apfelbaum 提交于
Refactoring it as a method of PCIBusClass will allow different implementations for subclasses. Removed the assumption that the root bus does not have a parent device because is specific only to the default class implementation. Signed-off-by: NMarcel Apfelbaum <marcel@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NLaszlo Ersek <lersek@redhat.com>
-
- 06 5月, 2015 1 次提交
-
-
由 Eric Blake 提交于
A future patch will be using a 'name':{dictionary} entry in the QAPI schema to specify a default value for an optional argument (see previous commit message for more details why); but existing use of inline nested structs conflicts with that goal. This patch fixes one of only two commands relying on nested types, by breaking the nesting into an explicit type; it means that the type is now boxed instead of unboxed in C code, but the QMP wire format is unaffected by this change. Prefer the safer g_new0() while making the conversion, and reduce some long lines. Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NMarkus Armbruster <armbru@redhat.com> Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
-
- 28 4月, 2015 1 次提交
-
-
由 Thomas Huth 提交于
The error reporting in pci_nic_init() is quite erratic: Some errors are printed directly with error_report(), and some are passed back to the caller pci_nic_init_nofail() via an Error pointer. Since pci_nic_init() is only used by pci_nic_init_nofail(), the functions can be simply merged to clean up this inconsistency. Signed-off-by: NThomas Huth <thuth@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NMarkus Armbruster <armbru@redhat.com>
-
- 13 4月, 2015 1 次提交
-
-
由 Thomas Huth 提交于
Current QEMU crashes when specifying an illegal model with the "-net nic,model=xxx" option, e.g.: $ qemu-system-x86_64 -net nic,model=n/a qemu-system-x86_64: Unsupported NIC model: n/a Program received signal SIGSEGV, Segmentation fault. The gdb backtrace looks like this: 0x0000555555965fe0 in error_get_pretty (err=0x0) at util/error.c:152 152 return err->msg; (gdb) bt 0 0x0000555555965fe0 in error_get_pretty (err=0x0) at util/error.c:152 1 0x0000555555965ffd in error_report_err (err=0x0) at util/error.c:157 2 0x0000555555809c90 in pci_nic_init_nofail (nd=0x555555e49860 <nd_table>, rootbus=0x5555564409b0, default_model=0x55555598c37b "e1000", default_devaddr=0x0) at hw/pci/pci.c:1663 3 0x0000555555691e42 in pc_nic_init (isa_bus=0x555556f71900, pci_bus=0x5555564409b0) at hw/i386/pc.c:1506 4 0x000055555569396b in pc_init1 (machine=0x5555562abbf0, pci_enabled=1, kvmclock_enabled=1) at hw/i386/pc_piix.c:248 5 0x0000555555693d27 in pc_init_pci (machine=0x5555562abbf0) at hw/i386/pc_piix.c:310 6 0x000055555572ddf5 in main (argc=3, argv=0x7fffffffe018, envp=0x7fffffffe038) at vl.c:4226 The problem is that pci_nic_init_nofail() does not check whether the err parameter from pci_nic_init has been set up and thus passes a NULL pointer to error_report_err(). Fix it by correctly checking the err parameter. Signed-off-by: NThomas Huth <thuth@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NJason Wang <jasowang@redhat.com> Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
- 12 3月, 2015 1 次提交
-
-
由 Markus Armbruster 提交于
qdev_init() is deprecated, and will be removed when its callers have been weaned off it. Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Acked-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 01 3月, 2015 1 次提交
-
-
由 Markus Armbruster 提交于
None of them should be used in new code. Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 26 2月, 2015 2 次提交
-
-
由 Markus Armbruster 提交于
Call the new PCIDeviceClass method realize(). Default it to pci_default_realize(), which calls old method init(). To convert a device model, make it implement realize() rather than init(). Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NGonglei <arei.gonglei@huawei.com>
-
由 Markus Armbruster 提交于
Implement DeviceClass methods realize() and unrealize() instead of init() and exit(). The core's initialization errors now get propagated properly, and QMP sends them instead of an unspecific "Device initialization failed" error. Unrealize can't fail, so no change there. PCIDeviceClass is unchanged: it still provides init() and exit(). Therefore, device models' errors are still not propagated. Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NGonglei <arei.gonglei@huawei.com>
-
- 18 2月, 2015 1 次提交
-
-
由 Markus Armbruster 提交于
Coccinelle semantic patch: @@ expression E; @@ - error_report("%s", error_get_pretty(E)); - error_free(E); + error_report_err(E); @@ expression E, S; @@ - error_report("%s", error_get_pretty(E)); + error_report_err(E); ( exit(S); | abort(); ) Trivial manual touch-ups in block/sheepdog.c. Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com>
-
- 06 2月, 2015 1 次提交
-
-
由 Alexander Graf 提交于
One of the annoyances of the current migration format is the fact that it's not self-describing. In fact, it's not properly describing at all. Some code randomly scattered throughout QEMU elaborates roughly how to read and write a stream of bytes. We discussed an idea during KVM Forum 2013 to add a JSON description of the migration protocol itself to the migration stream. This patch adds a section after the VM_END migration end marker that contains description data on what the device sections of the stream are composed of. This approach is backwards compatible with any QEMU version reading the stream, because QEMU just stops reading after the VM_END marker and ignores any data following it. With an additional external program this allows us to decipher the contents of any migration stream and hopefully make migration bugs easier to track down. Signed-off-by: NAlexander Graf <agraf@suse.de> Signed-off-by: NAmit Shah <amit.shah@redhat.com> Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
- 27 1月, 2015 1 次提交
-
-
由 Don Koch 提交于
Signed-off-by: NDon Koch <dkoch@verizon.com> Acked-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 02 11月, 2014 2 次提交
-
-
由 Marcel Apfelbaum 提交于
Hot-plugging a device that has a romfile (either supplied by user or built-in) using rombar=0 option is a user error, do not allow the device to be hot-plugged. Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NMarcel Apfelbaum <marcel.a@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Marcel Apfelbaum 提交于
Verify return code for pci_add_option_rom. Signed-off-by: NMarcel Apfelbaum <marcel.a@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NMarkus Armbruster <armbru@redhat.com>
-
- 09 9月, 2014 1 次提交
-
-
由 Hu Tao 提交于
Add parameter errp to memory_region_init_ram and update all call sites to pass in &error_abort. Signed-off-by: NHu Tao <hutao@cn.fujitsu.com> Reviewed-by: NPeter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
-
- 02 9月, 2014 1 次提交
-
-
由 Knut Omang 提交于
Since commit 95d65800 msi: Invoke msi/msix_write_config from PCI core msix config writes are lost, the value written is always 0. Fix pci_default_write_config to avoid this. Cc: qemu-stable@nongnu.org Signed-off-by: NKnut Omang <knut.omang@oracle.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 18 8月, 2014 1 次提交
-
-
由 Paolo Bonzini 提交于
The function is empty after the previous patch, so remove it. Reviewed-by: NPeter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
-
- 06 7月, 2014 1 次提交
-
-
由 Le Tan 提交于
In function do_pci_register_device() in file hw/pci/pci.c, move the assignment of pci_dev->devfn to the position before the call to pci_device_iommu_address_space(pci_dev) which will use the value of pci_dev->devfn. Fixes: 9eda7d37 pci: Introduce helper to retrieve a PCI device's DMA address space Cc: qemu-stable@nongnu.org Signed-off-by: NLe Tan <tamlokveer@gmail.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 16 6月, 2014 1 次提交
-
-
由 Juan Quintela 提交于
After previous Peter patch, they are redundant. This way we don't assign them except when needed. Once there, there were lots of case where the ".fields" indentation was wrong: .fields = (VMStateField []) { and .fields = (VMStateField []) { Change all the combinations to: .fields = (VMStateField[]){ The biggest problem (appart from aesthetics) was that checkpatch complained when we copy&pasted the code from one place to another. Signed-off-by: NJuan Quintela <quintela@redhat.com> Acked-by: NAlexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 24 5月, 2014 1 次提交
-
-
由 Saravanakumar 提交于
Signed-off-by: NSaravanakumar <saravanakumar.punith@gmail.com> Reviewed-by: NAndreas Färber <afaerber@suse.de> Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
- 09 5月, 2014 1 次提交
-
-
由 Laszlo Ersek 提交于
... and rebase pci_add_capability() to it. Signed-off-by: NLaszlo Ersek <lersek@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
-
- 06 5月, 2014 1 次提交
-
-
由 Michael S. Tsirkin 提交于
As the macro verifies the value is positive, rename it to make the function clearer. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
- 01 4月, 2014 1 次提交
-
-
由 Cole Robinson 提交于
irq_state is cleared before calling pci_device_deassert_intx, but the latter misbehaves if the former isn't accurate. In this case, any raised IRQs are not cleared, which hits an assertion in pcibus_reset: qemu-system-x86_64: hw/pci/pci.c:250: pcibus_reset: Assertion `bus->irq_count[i] == 0' failed. pci_device_deassert_intx should clear irq_state anyways, so add an assert. This fixes migration with usb2 + usb-tablet. Signed-off-by: NCole Robinson <crobinso@redhat.com> Message-id: 7da1ad94ce027183b4049c2de370cb191b0073c1.1396290569.git.crobinso@redhat.com Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
- 13 3月, 2014 1 次提交
-
-
由 Bandan Das 提交于
Use the realize and unrealize hooks to register and unregister vmstate_pcibus respectively. Relocate some stuff to avoid forward declarations. Signed-off-by: NBandan Das <bsd@redhat.com> Acked-by: NMichael S. Tsirkin <mst@redhat.com> [AF: Keep using PCI_BUS() cast macro] Signed-off-by: NAndreas Färber <afaerber@suse.de>
-
- 10 2月, 2014 2 次提交
-
-
由 Igor Mammedov 提交于
make qdev_unplug()/device_set_realized() to call hotplug handler's plug/unplug methods if available and remove not needed anymore hot(un)plug handling from PCIDevice. In case if hotplug handler is not available, revert to the legacy hotplug method for compatibility with not yet converted buses. Signed-off-by: NIgor Mammedov <imammedo@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Igor Mammedov 提交于
Get rid of PCIDevice specific PCIDeviceClass.no_hotplug and use generic DeviceClass.hotpluggable field instead. Signed-off-by: NIgor Mammedov <imammedo@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 26 1月, 2014 2 次提交
-
-
由 Marcel Apfelbaum 提交于
Scenario: - There is a non multifunction pci device A on 00:0X.0. - Hot-plug another multifunction pci device B at 00:0X.1. - The operation will fail of course. - Try to hot-plug the B device 2-3 more times, qemu will crash. Reason: The error flow leaves the B's address space into global address spaces list, but the device object is freed. Fixed that. Signed-off-by: NMarcel Apfelbaum <marcel.a@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Useful for ACPI hotplug. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 23 12月, 2013 3 次提交
-
-
由 Paolo Bonzini 提交于
Post-order is the only sensible direction for the reset signals. For example, suppose pre-order is used and the parent has some data structures that cache children state (for example a list of active requests). When the reset method is invoked on the parent, these caches could be in any state. If post-order is used, on the other hand, these will be in a known state when the reset method is invoked on the parent. This change means that it is no longer possible to block the visit of the devices, so the callback is changed to return void. This is not a problem, because PCI was returning 1 exactly in order to achieve the same ordering that this patch implements. PCI can then rely on the qdev core having sent a "reset signal" (whatever that means) to the device, and only do the PCI-specific initialization with pci_do_device_reset. MST: fixed up virtio-ccw Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Paolo Bonzini 提交于
pci_device_reset will deassert the INTX pins, and this will make the irq_count array all-zeroes. Check that this is the case, and remove the existing loop which might even unsync irq_count and irq_state. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Paolo Bonzini 提交于
qbus_reset_all can be used instead. There is no semantic change because pcibus_reset returns 1 and takes care of the device tree traversal. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 12 12月, 2013 1 次提交
-
-
由 Gerd Hoffmann 提交于
qemu uses "pci" as name for pci bridges in the firmware device path. seabios expects "pci-bridge". Result is that bootorder is broken for devices behind pci bridges. Some googling suggests that "pci-bridge" is the correct one. At least PPC-based Apple machines are using this. See question "How do I boot from a device attached to a PCI card" here: http://www.netbsd.org/ports/macppc/faq.html So lets change qemu to use "pci-bridge" too. Signed-off-by: NGerd Hoffmann <kraxel@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 21 11月, 2013 1 次提交
-
-
由 Bandan Das 提交于
PCIBus registers a vmstate during init. Unregister it upon removal/unplug. Signed-off-by: NBandan Das <bsd@redhat.com> Cc: qemu-stable@nongnu.org Reviewed-by: NAndreas Färber <afaerber@suse.de> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 10 11月, 2013 1 次提交
-
-
由 Marcel Apfelbaum 提交于
This reverts commit a53ae8e9. The patch being reverted introduced a low-priority memory region covering all 64 bit pci address space. This exposed the following bugs elsewhere in the code: 1. Some memory regions have INT64_MAX size, where the intent was all 64 bit address space. This results in a sub-page region, should be UINT64_MAX. 2. page table rendering in exec.c ignores physical address bits above TARGET_PHYS_ADDR_SPACE_BITS. Access outside this range (e.g. from device DMA, or gdb stub) ends up with a wrong region. Registering a region outside this range leads to page table corruption. 3. Some regions overlap PCI hole and have same priority. This only works as long as no device uses the overlapping address. It doesn't look like we can resolve all issues in time for 1.7. Let's fix the bugs first and apply afterwards for 1.8. Signed-off-by: NMarcel Apfelbaum <marcel.a@redhat.com> Reviewed-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 14 10月, 2013 1 次提交
-
-
由 Michael S. Tsirkin 提交于
BAR base was calculated incorrectly. Use existing pci_bar_address to get it right. Tested-by: NIgor Mammedov <imammedo@redhat.com> Reviewed-by: NIgor Mammedov <imammedo@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-