- 27 10月, 2015 10 次提交
-
-
由 Yang Hongyang 提交于
The value returned from object_get_canonical_path_component must be freed. Signed-off-by: NYang Hongyang <yanghy@cn.fujitsu.com> Cc: Jason Wang <jasowang@redhat.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Yang Hongyang 提交于
We want "buf, sizeof(buf)" here. sizeof(buffer) is the size of a pointer, which is wrong. Thanks to Paolo for pointing it out. Signed-off-by: NYang Hongyang <yanghy@cn.fujitsu.com> Cc: Jason Wang <jasowang@redhat.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Vladislav Yasevich 提交于
When responding to a query-rx-filter command on a multiqueue netdev, qemu reports the data for each queue. The data, however, is not per-queue, but per device and the same data is reported multiple times. This causes confusion and may also cause extra unnecessary processing when looking at the data. Commit 638fb141 (net: Make qmp_query_rx_filter() with name argument more obvious) partially addresses this issue, by limiting the output when the name is specified. However, when the name is not specified, the issue still persists. Signed-off-by: NVladislav Yasevich <vyasevic@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Shmulik Ladkani 提交于
Guest OS may issue VMXNET3_CMD_GET_STATS even before device was activated (for example in linux, after insmod but prior net-dev open). Accessing shared descriptors prior device activation is illegal as the VMXNET3State structures have not been fully initialized. As a result, guest memory gets corrupted and may lead to guest OS crashes. Fix, by not filling the stats descriptors if device is inactive. Reported-by: NLeonid Shatz <leonid.shatz@ravellosystems.com> Acked-by: NDmitry Fleytman <dmitry@daynix.com> Signed-off-by: NDana Rubin <dana.rubin@ravellosystems.com> Signed-off-by: NShmulik Ladkani <shmulik.ladkani@ravellosystems.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Thomas Huth 提交于
Add a short description for the filter-dump command line options. Signed-off-by: NThomas Huth <thuth@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Thomas Huth 提交于
Use the net-filter infrastructure to provide the dumping functions for netdev devices, too. Reviewed-by: NYang Hongyang <yanghy@cn.fujitsu.com> Signed-off-by: NThomas Huth <thuth@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Thomas Huth 提交于
With the upcoming dumping-via-netfilter patch, the DumpState should not be related to NetClientState anymore, so move the related information to a new struct called DumpNetClient. Reviewed-by: NYang Hongyang <yanghy@cn.fujitsu.com> Signed-off-by: NThomas Huth <thuth@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Thomas Huth 提交于
Move the creation of the dump client from net_dump_init() into net_init_dump(), so we can later use the former function for dump via netfilter, too. Also rename net_dump_init() to net_dump_state_init() to make it easier distinguishable from net_init_dump(). Reviewed-by: NYang Hongyang <yanghy@cn.fujitsu.com> Signed-off-by: NThomas Huth <thuth@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Thomas Huth 提交于
Adding a proper receive_iov function to the net dump module. This will make it easier to support the dump filter feature for the -netdev option in later patches. Reviewed-by: NYang Hongyang <yanghy@cn.fujitsu.com> Signed-off-by: NThomas Huth <thuth@redhat.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
由 Sebastian Huber 提交于
Set initial MAC address to the one specified by the command line. Signed-off-by: NSebastian Huber <sebastian.huber@embedded-brains.de> Reviewed-by: NJason Wang <jasowang@redhat.com> Reviewed-by: NPeter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: NJason Wang <jasowang@redhat.com>
-
- 26 10月, 2015 14 次提交
-
-
由 Peter Maydell 提交于
Xen 2015-10-26 # gpg: Signature made Mon 26 Oct 2015 11:32:50 GMT using RSA key ID 70E1AE90 # gpg: Good signature from "Stefano Stabellini <stefano.stabellini@eu.citrix.com>" * remotes/sstabellini/tags/xen-2015-10-26: xen-platform: Replace assert() with appropriate error reporting xen_platform: switch to realize Qemu/Xen: Fix early freeing MSIX MMIO memory region Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Eduardo Habkost 提交于
Commit dbb7405d made it possible to trigger an assert using "-device xen-platform". Replace it with appropriate error reporting. Before: $ qemu-system-x86_64 -device xen-platform qemu-system-x86_64: hw/i386/xen/xen_platform.c:391: xen_platform_initfn: Assertion `xen_enabled()' failed. Aborted (core dumped) $ After: $ qemu-system-x86_64 -device xen-platform qemu-system-x86_64: -device xen-platform: xen-platform device requires the Xen accelerator $ Signed-off-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com>
-
由 Stefano Stabellini 提交于
Use realize to initialize the xen_platform device Signed-off-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Peter Maydell 提交于
ivshmem series # gpg: Signature made Mon 26 Oct 2015 09:27:46 GMT using RSA key ID 75969CE5 # gpg: Good signature from "Marc-André Lureau <marcandre.lureau@redhat.com>" # gpg: aka "Marc-André Lureau <marcandre.lureau@gmail.com>" # gpg: WARNING: This key is not certified with sufficiently trusted signatures! # gpg: It is not certain that the signature belongs to the owner. # Primary key fingerprint: 87A9 BD93 3F87 C606 D276 F62D DAE8 E109 7596 9CE5 * remotes/elmarco/tags/ivshmem-pull-request: (51 commits) doc: document ivshmem & hugepages ivshmem: use little-endian int64_t for the protocol ivshmem: use kvm irqfd for msi notifications ivshmem: rename MSI eventfd_table ivshmem: remove EventfdEntry.vector ivshmem: add hostmem backend ivshmem: use qemu_strtosz() ivshmem: do not keep shm_fd open tests: add ivshmem qtest qtest: add qtest_add_abrt_handler() msix: implement pba write (but read-only) contrib: remove unnecessary strdup() ivshmem: add check on protocol version in QEMU docs: update ivshmem device spec ivshmem-server: fix hugetlbfs support ivshmem-server: use a uint16 for client ID ivshmem-client: check the number of vectors contrib: add ivshmem client and server util: const event_notifier_get_fd() argument ivshmem: reset mask on device reset ... Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Lan Tianyu 提交于
msix->mmio is added to XenPCIPassthroughState's object as property. object_finalize_child_property is called for XenPCIPassthroughState's object, which calls object_property_del_all, which is going to try to delete msix->mmio. object_finalize_child_property() will access msix->mmio's obj. But the whole msix struct has already been freed by xen_pt_msix_delete. This will cause segment fault when msix->mmio has been overwritten. This patch is to fix the issue. Signed-off-by: NLan Tianyu <tianyu.lan@intel.com> Reviewed-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com>
-
由 Marc-André Lureau 提交于
Document and give some examples of hugepages support with ivshmem device and server. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com>
-
由 Marc-André Lureau 提交于
The current ivshmem protocol uses 'long' for integers. But the sizeof(long) depends on the host and the endianess is not defined, which may cause portability troubles. Instead, switch to using little-endian int64_t. This breaks the protocol, except on x64 little-endian host where this change should be compatible. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Use irqfd for improving context switch when notifying the guest. If the host doesn't support kvm irqfd, regular msi notifications are still supported. Note: the ivshmem implementation doesn't allow switching between MSI and IO interrupts, this patch doesn't either. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
-
由 Marc-André Lureau 提交于
The array is used to have vector specific data, so use a more descriptive name. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
No need to store an extra int for the vector number when it can be computed easily by looking at the position in the array. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Instead of handling allocation, teach ivshmem to use a memory backend. This allows to use hugetlbfs backed memory now. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Use the common qemu utility function to parse the memory size. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Remove shm_fd from device state, closing it as early as possible to avoid leaks. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Adds 4 ivshmemtests: - single qemu instance and basic IO - pair of instances, check memory sharing - pair of instances with server, and MSIX - hot plug/unplug A temporary shm is created as well as a directory to place server socket, both should be clear on exit and abort. Cc: Cam Macdonell <cam@cs.ualberta.ca> Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com> Signed-off-by: NAndreas Färber <afaerber@suse.de>
-
- 25 10月, 2015 16 次提交
-
-
由 Marc-André Lureau 提交于
Allow a test to add abort handlers, use GHook for all handlers. There is currently no way to remove a handler, but it could be later added if needed. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
qpci_msix_pending() writes on pba region, causing qemu to SEGV: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7ffff7fba8c0 (LWP 25882)] 0x0000000000000000 in ?? () (gdb) bt #0 0x0000000000000000 in () #1 0x00005555556556c5 in memory_region_oldmmio_write_accessor (mr=0x5555579f3f80, addr=0, value=0x7fffffffbf68, size=4, shift=0, mask=4294967295, attrs=...) at /home/elmarco/src/qemu/memory.c:434 #2 0x00005555556558e1 in access_with_adjusted_size (addr=0, value=0x7fffffffbf68, size=4, access_size_min=1, access_size_max=4, access=0x55555565563e <memory_region_oldmmio_write_accessor>, mr=0x5555579f3f80, attrs=...) at /home/elmarco/src/qemu/memory.c:506 #3 0x00005555556581eb in memory_region_dispatch_write (mr=0x5555579f3f80, addr=0, data=0, size=4, attrs=...) at /home/elmarco/src/qemu/memory.c:1176 #4 0x000055555560b6f9 in address_space_rw (as=0x555555eff4e0 <address_space_memory>, addr=3759147008, attrs=..., buf=0x7fffffffc1b0 "", len=4, is_write=true) at /home/elmarco/src/qemu/exec.c:2439 #5 0x000055555560baa2 in cpu_physical_memory_rw (addr=3759147008, buf=0x7fffffffc1b0 "", len=4, is_write=1) at /home/elmarco/src/qemu/exec.c:2534 #6 0x000055555564c005 in cpu_physical_memory_write (addr=3759147008, buf=0x7fffffffc1b0, len=4) at /home/elmarco/src/qemu/include/exec/cpu-common.h:80 #7 0x000055555564cd9c in qtest_process_command (chr=0x55555642b890, words=0x5555578de4b0) at /home/elmarco/src/qemu/qtest.c:378 #8 0x000055555564db77 in qtest_process_inbuf (chr=0x55555642b890, inbuf=0x55555641b340) at /home/elmarco/src/qemu/qtest.c:569 #9 0x000055555564dc07 in qtest_read (opaque=0x55555642b890, buf=0x7fffffffc2e0 "writel 0xe0100800 0x0\n", size=22) at /home/elmarco/src/qemu/qtest.c:581 #10 0x000055555574ce3e in qemu_chr_be_write (s=0x55555642b890, buf=0x7fffffffc2e0 "writel 0xe0100800 0x0\n", len=22) at qemu-char.c:306 #11 0x0000555555751263 in tcp_chr_read (chan=0x55555642bcf0, cond=G_IO_IN, opaque=0x55555642b890) at qemu-char.c:2876 #12 0x00007ffff64c9a8a in g_main_context_dispatch (context=0x55555641c400) at gmain.c:3122 (without this patch, this can be reproduced with the ivshmem qtest) Implement an empty mmio write to avoid the crash. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
-
由 Marc-André Lureau 提交于
getopt() optarg points to argv memory, no need to dup those values, fixes small leaks detected by clang-analyzer. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
-
由 David Marchand 提交于
Send a protocol version as the first message from server, clients must close communication if they don't support this protocol version. Older QEMUs should be fine with this change in the protocol since they overrides their own vm_id on reception of an id associated to no eventfd. Signed-off-by: NDavid Marchand <david.marchand@6wind.com> Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> [use fifo_update_and_get()] Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 David Marchand 提交于
Add some notes on the parts needed to use ivshmem devices: more specifically, explain the purpose of an ivshmem server and the basic concept to use the ivshmem devices in guests. Move some parts of the documentation and re-organise it. Signed-off-by: NDavid Marchand <david.marchand@6wind.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com>
-
由 Marc-André Lureau 提交于
As pointed out on the ML by Andrew Jones, glibc no longer permits creating POSIX shm on hugetlbfs directly. When given a hugetlbfs path, create a shareable file there. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
-
由 Marc-André Lureau 提交于
In practice, the number of VM is limited to MAXUINT16 in ivshmem, so use the same limit on the server (removes a theorical infinite loop) Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Check the number of vectors received from the server, to avoid out of bound array access. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 David Marchand 提交于
When using ivshmem devices, notifications between guests can be sent as interrupts using a ivshmem-server (typical use described in documentation). The client is provided as a debug tool. Signed-off-by: NOlivier Matz <olivier.matz@6wind.com> Signed-off-by: NDavid Marchand <david.marchand@6wind.com> [fix a valgrind warning, option and server_close() segvs, extra server headers includes, getopt() return type, out-of-tree build, use qemu event_notifier instead of eventfd, fix x86/osx warnings - Marc-André] Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com>
-
由 Marc-André Lureau 提交于
Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com>
-
由 Marc-André Lureau 提交于
The interrupt mask is a state value, it should be reset, like the interrupt status. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
The number of eventfd that can be handled per peer is limited by the number of vectors. Return an error when receiving too many of them. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
The terms 'guest' and 'peer' are used sometime interchangeably which may be confusing. Instead, use 'peer' for the remote instances of ivshmem clients, and 'guest' for the local VM. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Free all objects owned by the device, making sure the device is free, fixing hot-unplug. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-
由 Marc-André Lureau 提交于
The server should not change the shm, and this isn't handled by qemu and we should should verify this in qemu. Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NClaudio Fontana <claudio.fontana@huawei.com>
-