History | View | Annotate | Download (22.5 kB)
Rename target_phys_addr_t to hwaddr
target_phys_addr_t is unwieldly, violates the C standard (_t suffixes arereserved) and its purpose doesn't match the name (most target_phys_addr_taddresses are not target specific). Replace it with a finger-friendly,...
cleanup useless return sentence
This patch cleans up return sentences in the end of void functions.
Reported-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Amos Kong <akong@redhat.com>Signed-off-by: Stefan Hajnoczi <stefanha@gmail.com>
ivshmem: add 64bit option
This patch adds a "use64" property which will make the ivshmem driverregister a 64bit memory bar when set, so you have something to play withwhen testing 64bit pci bits. It also allows to have quite big sharedmemory regions, like this:...
ivshmem: remove redundant ioeventfd configuration
setup_ioeventfds() is unnecessary and actually causes a segfault when usedioeventfd=on is used on the command-line. Since ioeventfds are handled withinthe memory API, it can be removed.
Signed-off-by: Cam Macdonell <cam@cs.ualberta.ca>...
ivshmem: fix memory_region_del_eventfd assertion failure
We do not register ioeventfds unless the IVSHMEM_IOEVENTFD featureis set. The same feature must be checked before releasing the eventfds.Regression introduced by commit 563027c (ivshmem: use EventNotifier and...
ivshmem, qdev-monitor: fix order of qerror parameters
Now that the QERR_ macros no longer contain a json dictionary,the order of some parameters needs to be fixed for them to appearcorrectly.
Signed-off-by: Alberto Garcia <agarcia@igalia.com>Reviewed-by: Luiz Capitulino <lcapitulino@redhat.com>...
Merge branch pci into master
Merge master and pci branch, resolve build breakage in hw/esp.cintroduced by f90c2bcd.
Conflicts: hw/esp.c
ivshmem: use EventNotifier and memory API
All of ivshmem's usage of eventfd now has a corresponding API inEventNotifier. Simplify the code by using it, and also use thememory API consistently to set up and tear down the ioeventfds.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>...
ivshmem: wrap ivshmem_del_eventfd loops with transaction
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Avi Kivity <avi@redhat.com>
memory: pass EventNotifier, not eventfd
Under Win32, EventNotifiers will not have event_notifier_get_fd, so wecannot call it in common code such as hw/virtio-pci.c. Pass a pointer tothe notifier, and only retrieve the file descriptor in kvm-specific code....
pci: convert PCIUnregisterFunc to void
Not a single driver has any possibility of failure on theirexit function, let's keep it that way.
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
ivshmem: Convert to msix_init_exclusive_bar() interface
Trivial conversion, failed to have an uninit before and after.
msi: Invoke msi/msix_reset from PCI core
There is no point in pushing this burden to the devices, they tend toforget to call them (like intel-hda, ahci, xhci did). Instead, resetfunctions are now called from pci_device_reset. They do nothing ifMSI/MSI-X is not in use....
Merge remote-tracking branch 'mst/tags/for_anthony' into staging
kvm: allow arbitrarily sized mmio ioeventfd
We use a 2 byte ioeventfd for virtio memory,add support for this.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>Reviewed-by: Amos Kong <akong@redhat.com>Signed-off-by: Avi Kivity <avi@redhat.com>
ivshmem: add missing msix calls
ivshmem used msix but didn't call it on either reset orconfig write paths. This used to partically work sinceguests don't use all of msi-x configuration fields,and reset is rarely used, but the patch 'msix: track function masked...
Replace Qemu by QEMU in comments
The official spelling is QEMU.
Signed-off-by: Stefan Weil <sw@weilnetz.de>Reviewed-by: Andreas Färber <afaerber@suse.de>[blauwirbel@gmail.com: fixed comment style in hw/sun4m.c]Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
qom: Unify type registration
Replace device_init() with generalized type_init().
While at it, unify naming convention: type_init([$prefix_]register_types)Also, type_init() is a function, so add preceding blank line wherenecessary and don't put a semicolon after the closing brace....
qdev: register all types natively through QEMU Object Model
This was done in a mostly automated fashion. I did it in three steps and thenrebased it into a single step which avoids repeatedly touching every file inthe tree.
The first step was a sed-based addition of the parent type to the subclass...
pci: convert to QEMU Object Model
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
prepare for future GPLv2+ relicensing
All files under GPLv2 will get GPLv2+ changes starting tomorrow.event_notifier.c and exec-obsolete.h were only ever touched by Red Hatemployees and can be relicensed now.
vmstate, memory: decouple vmstate from memory API
Currently creating a memory region automatically registers it forlive migration. This differs from other state (which is enumeratedin a VMStateDescription structure) and ties the live migration codeinto the memory core....
ivshmem: fix PCI BAR2 registration during initialization
Ivshmem cannot work, and the command lspci cannot show ivshmem BAR2 in the guest.As for pci_register_bar(), parameter MemoryRegion should be s->bar instead of s->ivshmem.
Reviewed-by: Avi Kivity <avi@redhat.com>...
ivshmem: use migration blockers to prevent live migration in peer mode (v2)
Now when you try to migrate with ivshmem, you get a proper QMP error:
(qemu) migrate tcp:localhost:1025Migration is disabled when using feature 'peer mode' in device 'ivshmem'(qemu)...
char: rename qemu_chr_get_msgfd() -> qemu_chr_fe_get_msgfd()
Use glib memory allocation and free functions
qemu_malloc/qemu_free no longer exist after this commit.
msix: convert to memory API
The msix table is defined as a subregion, to allow for a BAR thatmixes device specific regions with the msix table.
Reviewed-by: Richard Henderson <rth@twiddle.net>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Signed-off-by: Avi Kivity <avi@redhat.com>...
pci: rename pci_register_bar_region() to pci_register_bar()
Reviewed-by: Richard Henderson <rth@twiddle.net>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Signed-off-by: Avi Kivity <avi@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
ivshmem: convert to memory API
excluding msix.
hw/ivshmem.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>
Add endianness as io mem parameter
As stated before, devices can be little, big or native endian. Thetarget endianness is not of their concern, so we need to push thingsdown a level.
This patch adds a parameter to cpu_register_io_memory that allows adevice to choose its endianness. For now, all devices simply choose...
Fix ivshmem build on 32-bit hosts
stat() fields can be more or less anything depending on configuration, castexplicitly to uint64_t to avoid printf() format mismatches.
Signed-off-by: Avi Kivity <avi@redhat.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
hw/ivshmem.c don't check for negative values on unsigned data types
There is no need to check for dest < 0 or vector >= 0 as both areuint16_t.
This should fix problems with broken build with aggressive compilerflags. Reported by Xudong Hao <xudong.hao@intel.com>...
RESEND: Inter-VM shared memory PCI device
resend for bug fix related to removal of irqfd
Support an inter-vm shared memory device that maps a shared-memory object as aPCI device in the guest. This patch also supports interrupts between guest bycommunicating over a unix domain socket. This patch applies to the qemu-kvm...