Re: [Qemu-devel] [PATCH for 2.10 v2 10/20] m68k/translate: fix incorrect copy/paste

2017-07-26 Thread Richard Henderson
On 07/26/2017 07:42 PM, Philippe Mathieu-Daudé wrote: db3d7945ae extended gen_cc_cond() for cond [6, 7, 9, 10] but misswrote [4, 5] target/m68k/translate.c:1323:70: warning: identical expressions on both sides of logical operator if (op == CC_OP_ADDB || op == CC_OP_ADDW || op ==

Re: [Qemu-devel] [for-2.11 PATCH 26/26] spapr: add hotplug hooks for PHB hotplug

2017-07-26 Thread Alexey Kardashevskiy
On 26/07/17 18:40, Greg Kurz wrote: > Hotplugging PHBs is a machine-level operation, but PHBs reside on the > main system bus, so we register spapr machine as the handler for the > main system bus. > > Signed-off-by: Michael Roth > Signed-off-by: Greg Kurz

Re: [Qemu-devel] [PATCH for 2.10 0/4] check dtc submodule is outdated

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/26/2017 06:40 PM, Philippe Mathieu-Daudé wrote:> patch 4: if no system libdtc and submodule present, compile the dtc submodule and verify it is at least v1.4.2. Prefixed RFC because I'm not sure about these 3 lines: +make -C dtc 1>/dev/null which can leads to: /bin/sh: 1: cannot

Re: [Qemu-devel] [PATCH for 2.10 v2 19/20] spapr_vio: fix overflow of qdevs in spapr_dt_vdevice()

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/27/2017 12:43 AM, David Gibson wrote: On Wed, Jul 26, 2017 at 11:42:23PM -0300, Philippe Mathieu-Daudé wrote: sizeof(ptr) was used instead of sizeof(struct)... also use g_malloc_n() which take care of possible type overflow. hw/ppc/spapr_vio.c:641:22: warning: The code calls sizeof() on

Re: [Qemu-devel] [PATCH for 2.10 v2 19/20] spapr_vio: fix overflow of qdevs in spapr_dt_vdevice()

2017-07-26 Thread David Gibson
On Wed, Jul 26, 2017 at 11:42:23PM -0300, Philippe Mathieu-Daudé wrote: > sizeof(ptr) was used instead of sizeof(struct)... > > also use g_malloc_n() which take care of possible type overflow. > > hw/ppc/spapr_vio.c:641:22: warning: The code calls sizeof() on a pointer > type. This can produce

Re: [Qemu-devel] [for-2.11 PATCH 07/26] spapr_drc: fix realize and unrealize

2017-07-26 Thread David Gibson
On Wed, Jul 26, 2017 at 11:36:43AM +0200, Greg Kurz wrote: > On Wed, 26 Jul 2017 14:04:59 +1000 > David Gibson wrote: > > > On Tue, Jul 25, 2017 at 07:59:31PM +0200, Greg Kurz wrote: > > > If object_property_add_alias() returns an error in realize(), we should > > >

[Qemu-devel] why marking qcow2 img as corrupted

2017-07-26 Thread lampahome
I tried take snapshots on a demo.qcow2 10 times. cmd is below: > qemu-img snapshots -c tag_1 demo.qcow2 when I take snapshots 7 times and console shows: > mark image as corrupted and preventing from invalid write and I can't take snapshots anymore then. Can I avoid this situation or remove

Re: [Qemu-devel] Commit 77af8a2b95b79699de650965d5228772743efe84 breaks Windows 2000 support

2017-07-26 Thread Programmingkid
I just realized what we need in order to test QEMU better. We need a list of people who are willing to support a certain operating system. The list would probably be located here: http://wiki.qemu.org/Testing/Windows It would look like this: Operating systemTester Windows 3.1

Re: [Qemu-devel] [PATCH v12 5/8] virtio-balloon: VIRTIO_BALLOON_F_SG

2017-07-26 Thread Wei Wang
On 07/27/2017 01:02 AM, Michael S. Tsirkin wrote: On Wed, Jul 26, 2017 at 11:48:41AM +0800, Wei Wang wrote: On 07/23/2017 09:45 AM, Michael S. Tsirkin wrote: On Fri, Jul 14, 2017 at 03:12:43PM +0800, Wei Wang wrote: On 07/14/2017 04:19 AM, Michael S. Tsirkin wrote: On Thu, Jul 13, 2017 at

[Qemu-devel] [PATCH for 2.10 v2 20/20] i2c/exynos4210: fix write to I2CADD register, bit 0 is not mapped

2017-07-26 Thread Philippe Mathieu-Daudé
>From the Exynos4210 User Manual [1]: 14.4.1.3 I2CADDn (MULTI-MASTER I2C-Bus Address Register) [7-1] slave address, latched from the I2C-bus. bit [0] is not mapped. [1]: Exynos_4_Dual_45nm_User_Manaul_Public_REV1.00-0.pdf Signed-off-by: Philippe Mathieu-Daudé ---

[Qemu-devel] [PATCH for 2.10 v2 18/20] 9pfs: avoid sign conversion error simplifying the code

2017-07-26 Thread Philippe Mathieu-Daudé
(note this is how other functions also handle the errors). hw/9pfs/9p.c:948:18: warning: Loss of sign in implicit conversion offset = err; ^~~ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé --- hw/9pfs/9p.c | 6 ++ 1 file

[Qemu-devel] [PATCH for 2.10 v2 19/20] spapr_vio: fix overflow of qdevs in spapr_dt_vdevice()

2017-07-26 Thread Philippe Mathieu-Daudé
sizeof(ptr) was used instead of sizeof(struct)... also use g_malloc_n() which take care of possible type overflow. hw/ppc/spapr_vio.c:641:22: warning: The code calls sizeof() on a pointer type. This can produce an unexpected result qdevs = g_malloc(sizeof(qdev) * num);

[Qemu-devel] [PATCH for 2.10 v2 17/20] bt-sdp: fix memory leak in sdp_service_record_build()

2017-07-26 Thread Philippe Mathieu-Daudé
hw/bt/sdp.c:753:5: warning: Potential leak of memory pointed to by 'data' qsort(record->attribute_list, record->attributes, ^ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé --- hw/bt/*: get_maintainer.pl: No maintainers found hw/bt/sdp.c |

[Qemu-devel] [PATCH for 2.10 v2 12/20] syscall: fix dereference of undefined pointer

2017-07-26 Thread Philippe Mathieu-Daudé
linux-user/syscall.c:5581:9: warning: Dereference of undefined pointer value if (*host_rt_dev_ptr != 0) { ^~~~ Reported-by: Clang Static Analyzer Suggested-by: Laurent Vivier Signed-off-by: Philippe Mathieu-Daudé ---

[Qemu-devel] [PATCH for 2.10 v2 13/20] syscall: fix use of uninitialized values

2017-07-26 Thread Philippe Mathieu-Daudé
linux-user/syscall.c:1627:35: warning: 1st function call argument is an uninitialized value target_saddr->sa_family = tswap16(addr->sa_family); ^~~~ linux-user/syscall.c:1629:25: warning: The left operand of '==' is a garbage value

[Qemu-devel] [PATCH for 2.10 v2 14/20] syscall: check inotify() and eventfd() return value

2017-07-26 Thread Philippe Mathieu-Daudé
linux-user/syscall.c:555:25: warning: Out of bound memory access (accessed memory precedes memory block) target_fd_trans[fd] = trans; ^~~ Reported-by: Clang Static Analyzer Suggested-by: Laurent Vivier Signed-off-by: Philippe Mathieu-Daudé

[Qemu-devel] [PATCH for 2.10 v2 07/20] net/eth: fix incorrect check of iov_to_buf() return value

2017-07-26 Thread Philippe Mathieu-Daudé
So we have sizeof(struct in6_address) != sizeof(uintptr_t) and Clang > Coverity on this, see 4555ca6816c :) net/eth.c:426:30: warning: The code calls sizeof() on a pointer type. This can produce an unexpected result return bytes_read == sizeof(dst_addr); ^

[Qemu-devel] [PATCH for 2.10 v2 10/20] m68k/translate: fix incorrect copy/paste

2017-07-26 Thread Philippe Mathieu-Daudé
db3d7945ae extended gen_cc_cond() for cond [6, 7, 9, 10] but misswrote [4, 5] target/m68k/translate.c:1323:70: warning: identical expressions on both sides of logical operator if (op == CC_OP_ADDB || op == CC_OP_ADDW || op == CC_OP_ADDL || op == CC_OP_ADDB || op == CC_OP_ADDW

[Qemu-devel] [PATCH for 2.10 v2 09/20] vfio/pci: fix use of freed memory

2017-07-26 Thread Philippe Mathieu-Daudé
hw/vfio/pci.c:308:29: warning: Use of memory after it is freed qemu_set_fd_handler(*pfd, NULL, NULL, vdev); ^~~~ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Paolo Bonzini ---

[Qemu-devel] [PATCH for 2.10 v2 06/20] ui/vnc: fix leak of SocketAddress **

2017-07-26 Thread Philippe Mathieu-Daudé
Extract the (correct) cleaning code as a new function vnc_free_addresses() then use it to remove the memory leaks. Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Daniel P. Berrange --- ui/vnc.c | 36

[Qemu-devel] [PATCH for 2.10 v2 05/20] qcow2: fix null pointer dereference

2017-07-26 Thread Philippe Mathieu-Daudé
It seems this assert() was somehow misplaced. block/qcow2-refcount.c:2193:42: warning: Array access (from variable 'on_disk_reftable') results in a null pointer dereference on_disk_reftable[refblock_index] = refblock_offset; ^ Reported-by: Clang

[Qemu-devel] [PATCH for 2.10 v2 08/20] vfio/platform: fix use of freed memory

2017-07-26 Thread Philippe Mathieu-Daudé
free the data _after_ using it. hw/vfio/platform.c:126:29: warning: Use of memory after it is freed qemu_set_fd_handler(*pfd, NULL, NULL, NULL); ^~~~ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Paolo

[Qemu-devel] [PATCH for 2.10 v2 15/20] thunk: assert nb_fields is valid

2017-07-26 Thread Philippe Mathieu-Daudé
thunk.c:91:32: warning: Call to 'malloc' has an allocation size of 0 bytes se->field_offsets[i] = malloc(nb_fields * sizeof(int)); ^~~ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé ---

[Qemu-devel] [PATCH for 2.10 v2 04/20] nbd: fix memory leak in nbd_opt_go()

2017-07-26 Thread Philippe Mathieu-Daudé
nbd/client.c:385:12: warning: Potential leak of memory pointed to by 'buf' Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Blake --- nbd/client.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff

[Qemu-devel] [PATCH for 2.10 v2 00/20] fix bugs reported by Clang Static Analyzer

2017-07-26 Thread Philippe Mathieu-Daudé
Hi, This series is the result of [now NOT] having fun with Clang's Static Analyzer (see https://clang-analyzer.llvm.org/). v2: - addressed review feedbacks, - added various R-b, - dropped noise (Peter sharp eye), - dropped dup patches Patches 1-13 are already reviewed, Patches 14,15 address

[Qemu-devel] [PATCH for 2.10 v2 11/20] linux-user/sh4: fix incorrect memory write

2017-07-26 Thread Philippe Mathieu-Daudé
not hit since 2009! :) linux-user/elfload.c:1102:20: warning: Out of bound memory access (access exceeds upper limit of memory block) (*regs[i]) = tswap32(env->gregs[i]); ~~~^~~~ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé

[Qemu-devel] [PATCH for 2.10 v2 03/20] ivshmem: fix incorrect error handling in ivshmem_recv_msg()

2017-07-26 Thread Philippe Mathieu-Daudé
Screwed up in commit 3a55fc0f, v2.6.0. If qemu_chr_fe_read_all() returns -EINTR the do {} statement continues and the n accumulator used to complete reads upto sizeof(msg) is decremented by 4 (the value of EINTR on Linux). To avoid that, use simpler if() statements and continue if EINTR occured.

[Qemu-devel] [PATCH for 2.10 v2 02/20] loader: check get_image_size() return value

2017-07-26 Thread Philippe Mathieu-Daudé
since a negative value means it errored. hw/core/loader.c:149:9: warning: Loss of sign in implicit conversion if (size > max_sz) { ^~~~ hw/core/loader.c:171:9: warning: Loss of sign in implicit conversion if (size > memory_region_size(mr)) { ^~~~ Reported-by: Clang Static

[Qemu-devel] [PATCH for 2.10 v2 01/20] tests: add missing dependency to build QTEST_QEMU_BINARY

2017-07-26 Thread Philippe Mathieu-Daudé
This allow a one liner from fresh repository clone, i.e.: ./configure && make -j check-qtest-aarch64 Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Alex Bennée Reviewed-by: Stefan Hajnoczi Reviewed-by: John Snow

Re: [Qemu-devel] Commit 77af8a2b95b79699de650965d5228772743efe84 breaks Windows 2000 support

2017-07-26 Thread Programmingkid
> On Jul 26, 2017, at 10:28 AM, qemu-devel-requ...@nongnu.org wrote: > > Message: 3 > Date: Wed, 26 Jul 2017 15:30:20 +0200 > From: Igor Mammedov > To: Paolo Bonzini > Cc: Laszlo Ersek , Phil Dennis-Jordan >

[Qemu-devel] [PATCH v2] migration: optimize the downtime

2017-07-26 Thread Jay Zhou
Qemu_savevm_state_cleanup takes about 300ms in my ram migration tests with a 8U24G vm(20G is really occupied), the main cost comes from KVM_SET_USER_MEMORY_REGION ioctl when mem.memory_size = 0 in kvm_set_user_memory_region. In kmod, the main cost is kvm_zap_obsolete_pages, which traverses the

Re: [Qemu-devel] [PATCH v8 3/3] migration: add bitmap for received page

2017-07-26 Thread Peter Xu
On Wed, Jul 26, 2017 at 06:24:11PM +0300, Alexey Perevalov wrote: > On 07/26/2017 11:43 AM, Peter Xu wrote: > >On Wed, Jul 26, 2017 at 11:07:17AM +0300, Alexey Perevalov wrote: > >>On 07/26/2017 04:49 AM, Peter Xu wrote: > >>>On Thu, Jul 20, 2017 at 09:52:34AM +0300, Alexey Perevalov wrote: >

Re: [Qemu-devel] [PATCH V3] rtc: fix a infinite loop inwindowsvmstartup

2017-07-26 Thread peng.hao2
> On 26/07/2017 03:28, peng.h...@zte.com.cn wrote: > > > > > > when the problem happens , windows kernel is checking whether REG_A_UIP is > > changing after periodic timer has stopped. windows kernel access REG_A > > according to INB instrunction and it will spend several microseconds

Re: [Qemu-devel] [PATCH v3 4/4] intel_iommu: implement mru list for iotlb

2017-07-26 Thread Peter Xu
On Wed, Jul 26, 2017 at 11:37:13PM +0300, Michael S. Tsirkin wrote: > On Mon, Jul 17, 2017 at 09:53:27AM +0800, Peter Xu wrote: > > On Fri, Jul 14, 2017 at 03:28:09PM +0800, Jason Wang wrote: > > > > > > > > > On 2017年07月14日 12:32, Peter Xu wrote: > > > >On Thu, Jul 13, 2017 at 04:48:42PM +0800,

[Qemu-devel] [PATCH] tcg/README: fix a description error.

2017-07-26 Thread Jiang Biao
The atomics.txt is not in the docs directory but in docs/devel/ instead. Signed-off-by: Jiang Biao --- tcg/README | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tcg/README b/tcg/README index bf49e82..03bfb6a 100644 --- a/tcg/README +++ b/tcg/README

[Qemu-devel] [PATCH] fsdev: fix memory leak in main()

2017-07-26 Thread ZhiPeng Lu
@rpath and @ sock_name are not freed and leaked. Signed-off-by: Zhipeng Lu lu.zhip...@zte.com.cn --- fsdev/virtfs-proxy-helper.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fsdev/virtfs-proxy-helper.c b/fsdev/virtfs-proxy-helper.c index 6c066ec..8e48500 100644 ---

[Qemu-devel] [PATCH 2/3] s390x/css: generate solicited crw for rchp completion signaling

2017-07-26 Thread Dong Jia Shi
A successful completion of rchp should signal a solicited channel path initialized CRW (channel report word), while the current implementation always generates an un-solicited one. Let's fix this. Reported-by: Halil Pasic Signed-off-by: Dong Jia Shi

[Qemu-devel] [PATCH 3/3] s390x/css: generate channel path initialized CRW for channel path hotplug

2017-07-26 Thread Dong Jia Shi
When a channel path is hot plugged into a CSS, we should generate a channel path initialized CRW (channel report word). The current code does not do that, instead it puts a stub function with a TODO reminder there. This implements the css_generate_chp_crws() function by: 1. refactor the existing

[Qemu-devel] [PATCH 0/3] Channel Path realted CRW generation

2017-07-26 Thread Dong Jia Shi
This series is trying to: 1. clear up CRW related code. 2. generate the right channel path related CRW at the right time. I did this mainly because it's a requirement from my current work, that is I'm in preparation of a group of patch for channel path virtualization. I can use the inerface that

[Qemu-devel] [PATCH 1/3] s390x/css: use macro for event-information pending error recover code

2017-07-26 Thread Dong Jia Shi
Let's use a macro for the ERC (error recover code) when generating a Channel Subsystem Event-information pending CRW (channel report word). Signed-off-by: Dong Jia Shi --- hw/s390x/css.c| 2 +- include/hw/s390x/ioinst.h | 5 +++-- 2 files changed, 4

[Qemu-devel] [Bug 1706825] [NEW] qemu-user fails to run wineserver on ppc64el host

2017-07-26 Thread Timothy Pearson
Public bug reported: When attempting to run wineserver on a 64-bit ppc64el host via QEMU's user-mode i386 emulation, a file locking operation fails. Command line: qemu-i386-static /usr/lib/wine-development/wineserver32 Output: wineserver: fcntl /tmp/.wine-0/server-17-14d21bf/lock: Invalid

[Qemu-devel] [PATCH for-2.10 0/3] qdev/vfio: defer DEVICE_DEL to avoid races with libvirt

2017-07-26 Thread Michael Roth
This series was motivated by the discussion in this thread: https://www.redhat.com/archives/libvir-list/2017-June/msg01370.html The issue this series addresses is that when libvirt unplugs a VFIO PCI device, it may attempt to bind the host device back to the host driver when QEMU emits the

[Qemu-devel] [PATCH for-2.10 2/3] Revert "qdev: Free QemuOpts when the QOM path goes away"

2017-07-26 Thread Michael Roth
This reverts commit abed886ec60cf239a03515cf0b30fb11fa964c44. This patch originally addressed an issue where a DEVICE_DELETED event could be emitted (in device_unparent()) before a Device's QemuOpts were cleaned up (in device_finalize()), leading to a "duplicate ID" error if management attempted

[Qemu-devel] [PATCH for-2.10 1/3] qdev: store DeviceState's canonical path to use when unparenting

2017-07-26 Thread Michael Roth
device_unparent(dev, ...) is called when a device is unparented, either directly, or as a result of a parent device being finalized, and handles some final cleanup for the device. Part of this includes emiting a DEVICE_DELETED QMP event to notify management, which includes the device's path in the

[Qemu-devel] [PATCH for-2.10 3/3] qdev: defer DEVICE_DEL event until instance_finalize()

2017-07-26 Thread Michael Roth
DEVICE_DEL is currently emitted when a Device is unparented, as opposed to when it is finalized. The main design motivation for this seems to be that after unparent()/unrealize(), the Device is no longer visible to the guest, and thus the operation is complete from the perspective of management.

Re: [Qemu-devel] [PATCH for 2.10 2/2] Revert "elf-loader: warn about invalid endianness"

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/26/2017 08:56 PM, Aurelien Jarno wrote: From: Alexey Kardashevskiy This reverts c8e1158cf611 "elf-loader: warn about invalid endianness" as it produces a useless message every time an LE kernel image is passed via -kernel on a ppc64-pseries machine. The pseries machine

Re: [Qemu-devel] [PATCH for 2.10 1/2] hw/mips: load_elf_strerror to report kernel loading failure

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/26/2017 08:56 PM, Aurelien Jarno wrote: Emulated MIPS boards bail out with a simple "could not load kernel" when a kernel could not be load, without specifying the underlying reason. Fix that by calling load_elf_strerror. At the same time use error_report to report the error instead of

Re: [Qemu-devel] About the trace framework

2017-07-26 Thread Wang Dong
On 07/14/2017 09:25 PM, Stefan Hajnoczi wrote: On Thu, Jul 13, 2017 at 04:01:09PM +0800, Wang Dong wrote: On 07/10/2017 08:40 PM, Stefan Hajnoczi wrote: On Mon, Jul 10, 2017 at 01:24:23PM +0800, Xie Changlong wrote: 在 7/9/2017 5:57 PM, Wang Dong 写道: Hi, I am new to QEMU. But I got some

Re: [Qemu-devel] [PATCH 1/2] s390x/css: check ccw address validity

2017-07-26 Thread Dong Jia Shi
* Halil Pasic [2017-07-26 18:45:34 +0200]: [...] > >>> @@ -946,6 +953,17 @@ static void sch_handle_start_func_virtual(SubchDev > >>> *sch) > >>> suspend_allowed = true; > >>> } > >>> sch->last_cmd_valid = false; > >>> +if (sch->channel_prog &

Re: [Qemu-devel] KVM "fake DAX" flushing interface - discussion

2017-07-26 Thread Dan Williams
On Wed, Jul 26, 2017 at 4:46 PM, Rik van Riel wrote: > On Wed, 2017-07-26 at 14:40 -0700, Dan Williams wrote: >> On Wed, Jul 26, 2017 at 2:27 PM, Rik van Riel >> wrote: >> > On Wed, 2017-07-26 at 09:47 -0400, Pankaj Gupta wrote: >> > > > >> > > >> > > Just want

Re: [Qemu-devel] [PATCH 2/2] s390x/css: fix bits must be zero check for TIC

2017-07-26 Thread Dong Jia Shi
* Halil Pasic [2017-07-26 13:38:33 +0200]: > > > On 07/26/2017 05:01 AM, Dong Jia Shi wrote: > > Hello Halil, > > > > * Halil Pasic [2017-07-26 00:44:42 +0200]: > > > >> According to the PoP bit positions 0-3 and 8-32 of the format-1 CCW

Re: [Qemu-devel] [PATCH 1/2] vhost-user-blk: introduce a new vhost-user-blk host device

2017-07-26 Thread Liu, Changpeng
> -Original Message- > From: Stefan Hajnoczi [mailto:stefa...@redhat.com] > Sent: Wednesday, July 26, 2017 6:35 PM > To: Liu, Changpeng > Cc: qemu-devel@nongnu.org; pbonz...@redhat.com; fel...@nutanix.com; > m...@redhat.com > Subject: Re: [PATCH 1/2]

[Qemu-devel] [PATCH for 2.10 0/2] Move endianness error reporting to the MIPS boards

2017-07-26 Thread Aurelien Jarno
This patchset improves the MIPS board error reporting when loading a kernel with the wrong endianness, using load_elf_strerror. That way the check added to loader.c can be removed, as it harms the pseries platform. Indeed it can change its endianness dynamically at runtime and thus can load both

Re: [Qemu-devel] [PATCH qemu] Revert "elf-loader: warn about invalid endianness"

2017-07-26 Thread Aurelien Jarno
On 2017-07-21 17:30, Alexey Kardashevskiy wrote: > On 21/07/17 16:48, Philippe Mathieu-Daudé wrote: > > Hi Alexey, > > > > On 07/21/2017 01:19 AM, Alexey Kardashevskiy wrote: > >> This reverts c8e1158cf611 "elf-loader: warn about invalid endianness" > >> as it produces a useless message every

[Qemu-devel] [PATCH for 2.10 2/2] Revert "elf-loader: warn about invalid endianness"

2017-07-26 Thread Aurelien Jarno
From: Alexey Kardashevskiy This reverts c8e1158cf611 "elf-loader: warn about invalid endianness" as it produces a useless message every time an LE kernel image is passed via -kernel on a ppc64-pseries machine. The pseries machine already checks for ELF_LOAD_WRONG_ENDIAN and tries

[Qemu-devel] [PATCH for 2.10 1/2] hw/mips: load_elf_strerror to report kernel loading failure

2017-07-26 Thread Aurelien Jarno
Emulated MIPS boards bail out with a simple "could not load kernel" when a kernel could not be load, without specifying the underlying reason. Fix that by calling load_elf_strerror. At the same time use error_report to report the error instead of fprintf. Signed-off-by: Aurelien Jarno

Re: [Qemu-devel] KVM "fake DAX" flushing interface - discussion

2017-07-26 Thread Rik van Riel
On Wed, 2017-07-26 at 14:40 -0700, Dan Williams wrote: > On Wed, Jul 26, 2017 at 2:27 PM, Rik van Riel > wrote: > > On Wed, 2017-07-26 at 09:47 -0400, Pankaj Gupta wrote: > > > > > > > > > > Just want to summarize here(high level): > > > > > > This will require implementing

Re: [Qemu-devel] [PATCH v3 04/12] tests: Pass literal format strings directly to qmp_FOO()

2017-07-26 Thread John Snow
On 07/25/2017 05:15 PM, Eric Blake wrote: From: Markus Armbruster The qmp_FOO() take a printf-like format string. In a few places, we assign a string literal to a variable and pass that instead of simply passing the literal. Clean that up. Bonus: gets rid of non-literal

Re: [Qemu-devel] [RFC PATCH v2 4/6] hw/pci: introduce bridge-only vendor-specific capability to provide some hints to firmware

2017-07-26 Thread Michael S. Tsirkin
On Thu, Jul 27, 2017 at 12:54:07AM +0300, Alexander Bezzubikov wrote: > 2017-07-26 22:43 GMT+03:00 Michael S. Tsirkin : > > On Sun, Jul 23, 2017 at 01:15:41AM +0300, Aleksandr Bezzubikov wrote: > >> On PCI init PCI bridges may need some > >> extra info about bus number to reserve,

Re: [Qemu-devel] [PATCH for 2.10 17/35] usb/dev-mtp: fix use of uninitialized values

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/24/2017 03:27 PM, Philippe Mathieu-Daudé wrote: Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé --- hw/usb/dev-mtp.c | 36 +--- 1 file changed, 21 insertions(+), 15 deletions(-) diff --git a/hw/usb/dev-mtp.c

Re: [Qemu-devel] [PATCH for 2.10 16/35] usb/dev-mtp: fix use of uninitialized values

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/25/2017 09:34 AM, Gerd Hoffmann wrote: case CMD_GET_OBJECT_INFO: -o = usb_mtp_object_lookup(s, c->argv[0]); +if (c->argc > 0) { +o = usb_mtp_object_lookup(s, c->argv[0]); +} How about zero-initializing c->argv instead? I checked the MTP specs

Re: [Qemu-devel] [SeaBIOS] [RFC PATCH v2 4/6] hw/pci: introduce bridge-only vendor-specific capability to provide some hints to firmware

2017-07-26 Thread Laszlo Ersek
On 07/26/17 23:54, Alexander Bezzubikov wrote: > 2017-07-26 22:43 GMT+03:00 Michael S. Tsirkin : >> On Sun, Jul 23, 2017 at 01:15:41AM +0300, Aleksandr Bezzubikov wrote: >>> +PCIBridgeQemuCap cap; >> >> This leaks info to guest. You want to init all fields here: >> >> cap = {

Re: [Qemu-devel] [PATCH for 2.10 20/35] arm/boot: fix undefined instruction on secondary smp cpu bootloader

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/24/2017 06:06 PM, Peter Maydell wrote: On 24 July 2017 at 19:27, Philippe Mathieu-Daudé wrote: In a ARM multicore system, write_secondary_boot() only initializes fixups for FIXUP_GIC_CPU_IF and FIXUP_BOOTREG, while smpboot[] also uses FIXUP_DSB. This results in

Re: [Qemu-devel] [PATCH for 2.10 03/35] thunk: check nb_fields is valid before continuing

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/24/2017 03:37 PM, Eric Blake wrote: On 07/24/2017 01:27 PM, Philippe Mathieu-Daudé wrote: thunk.c:91:32: warning: Call to 'malloc' has an allocation size of 0 bytes se->field_offsets[i] = malloc(nb_fields * sizeof(int));

[Qemu-devel] How to debug crash in TCG code?

2017-07-26 Thread BALATON Zoltan
Hello, I'm getting a segfault in generated code that I don't know how to debug further. The back trace shows: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fffe87f7700 (LWP 24372)] 0x557ee0a1 in io_readx (env=0x7fffe88002a0, iotlbentry=0x7fffe8811d60,

Re: [Qemu-devel] [PATCH 2/2] iotests: Redirect stderr to stdout in 186

2017-07-26 Thread Jeff Cody
On Tue, Jul 25, 2017 at 05:56:44PM +0200, Max Reitz wrote: > Without redirecting qemu's stderr to stdout, _filter_qemu will not apply > to warnings. This results in $QEMU_PROG not being replaced by QEMU_PROG > which is not great if your qemu executable is not called > qemu-system-x86_64 (e.g.

Re: [Qemu-devel] [PATCH 1/2] iotests: Fix test 156

2017-07-26 Thread Jeff Cody
On Tue, Jul 25, 2017 at 05:56:43PM +0200, Max Reitz wrote: > On one hand, the _make_test_img invocation for creating the target image > was missing a -u because its backing file is not supposed to exist at > that point. > > On the other hand, nobody noticed probably because the backing file is >

Re: [Qemu-devel] [PATCH for 2.10 0/4] check dtc submodule is outdated

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/26/2017 06:56 PM, Eric Blake wrote: On 07/26/2017 04:47 PM, no-re...@patchew.org wrote: This series failed build test on s390x host. Please find the details below. [...] === PACKAGES === >> dtc-1.4.2-1.fc25.s390x === TEST BEGIN === Using CC: /home/fam/bin/cc ERROR: fdt disabled

Re: [Qemu-devel] [PATCH 1/4] configure: remember the user to run 'git submodule' command in source dir

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/26/2017 06:51 PM, Eric Blake wrote: On 07/26/2017 04:40 PM, Philippe Mathieu-Daudé wrote: In the subject: s/remember/remind/ Signed-off-by: Philippe Mathieu-Daudé --- configure | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/configure

Re: [Qemu-devel] [PATCH for 2.10 0/4] check dtc submodule is outdated

2017-07-26 Thread Eric Blake
On 07/26/2017 04:47 PM, no-re...@patchew.org wrote: > Hi, > > This series failed build test on s390x host. Please find the details below. > > Type: series > Subject: [Qemu-devel] [PATCH for 2.10 0/4] check dtc submodule is outdated > Message-id: 20170726214010.420-1-f4...@amsat.org > > ===

Re: [Qemu-devel] [RFC PATCH v2 4/6] hw/pci: introduce bridge-only vendor-specific capability to provide some hints to firmware

2017-07-26 Thread Alexander Bezzubikov
2017-07-26 22:43 GMT+03:00 Michael S. Tsirkin : > On Sun, Jul 23, 2017 at 01:15:41AM +0300, Aleksandr Bezzubikov wrote: >> On PCI init PCI bridges may need some >> extra info about bus number to reserve, IO, memory and >> prefetchable memory limits. QEMU can provide this >> with

Re: [Qemu-devel] [PATCH for 2.10 2/4] fdt: check fdt_required condition can be satisfied _after_ testing libfdt

2017-07-26 Thread Eric Blake
On 07/26/2017 04:40 PM, Philippe Mathieu-Daudé wrote: > Signed-off-by: Philippe Mathieu-Daudé > --- > configure | 18 +- > 1 file changed, 9 insertions(+), 9 deletions(-) Reviewed-by: Eric Blake -- Eric Blake, Principal Software Engineer

Re: [Qemu-devel] [PATCH 1/4] configure: remember the user to run 'git submodule' command in source dir

2017-07-26 Thread Eric Blake
On 07/26/2017 04:40 PM, Philippe Mathieu-Daudé wrote: In the subject: s/remember/remind/ > Signed-off-by: Philippe Mathieu-Daudé > --- > configure | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/configure b/configure > index

Re: [Qemu-devel] [PATCH for 2.10 0/4] check dtc submodule is outdated

2017-07-26 Thread no-reply
Hi, This series failed build test on s390x host. Please find the details below. Type: series Subject: [Qemu-devel] [PATCH for 2.10 0/4] check dtc submodule is outdated Message-id: 20170726214010.420-1-f4...@amsat.org === TEST SCRIPT BEGIN === #!/bin/bash # Testing script will be invoked under

Re: [Qemu-devel] KVM "fake DAX" flushing interface - discussion

2017-07-26 Thread Dan Williams
On Wed, Jul 26, 2017 at 2:27 PM, Rik van Riel wrote: > On Wed, 2017-07-26 at 09:47 -0400, Pankaj Gupta wrote: >> > >> Just want to summarize here(high level): >> >> This will require implementing new 'virtio-pmem' device which >> presents >> a DAX address range(like pmem) to

[Qemu-devel] [RFC PATCH for 2.10 4/4] fdt: compile dtc submodule to check it is up-to-date

2017-07-26 Thread Philippe Mathieu-Daudé
Reported-by: John Arbuckle Message-Id: <65ed9743-b53c-4e6a-866f-c88365091...@gmail.com> Signed-off-by: Philippe Mathieu-Daudé --- configure | 24 +++- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/configure

[Qemu-devel] [PATCH for 2.10 3/4] fdt: probe for v1.4.2 using fdt_setprop_inplace_namelen_partial()

2017-07-26 Thread Philippe Mathieu-Daudé
instead of fdt_first_subnode() which is v1.4.0 Signed-off-by: Philippe Mathieu-Daudé --- configure | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/configure b/configure index 0d5bdb3ae9..2d803d6a77 100755 --- a/configure +++ b/configure @@ -3565,7

[Qemu-devel] [PATCH for 2.10 0/4] check dtc submodule is outdated

2017-07-26 Thread Philippe Mathieu-Daudé
On http://lists.nongnu.org/archive/html/qemu-devel/2017-07/msg07987.html John hit the following error: hw/core/loader-fit.c:105:41: error: expected expression *addr = fdt32_to_cpu(*(fdt32_t *)prop); ^ having his ./configure

[Qemu-devel] [PATCH for 2.10 2/4] fdt: check fdt_required condition can be satisfied _after_ testing libfdt

2017-07-26 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé --- configure | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/configure b/configure index 063de32773..0d5bdb3ae9 100755 --- a/configure +++ b/configure @@ -3558,15 +3558,6 @@ for target in $target_list;

[Qemu-devel] [PATCH 1/4] configure: remember the user to run 'git submodule' command in source dir

2017-07-26 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé --- configure | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/configure b/configure index f8b1d014d7..063de32773 100755 --- a/configure +++ b/configure @@ -502,6 +502,7 @@ if test -f "./configure"; then

Re: [Qemu-devel] KVM "fake DAX" flushing interface - discussion

2017-07-26 Thread Rik van Riel
On Wed, 2017-07-26 at 09:47 -0400, Pankaj Gupta wrote: > > > Just want to summarize here(high level): > > This will require implementing new 'virtio-pmem' device which > presents  > a DAX address range(like pmem) to guest with read/write(direct > access) > & device flush functionality. Also,

Re: [Qemu-devel] [sw-dev] RFC: QEMU RISC-V modular ISA decoding

2017-07-26 Thread Michael Clark
> On 27 Jul 2017, at 8:58 AM, kr...@berkeley.edu wrote: > > > Given that one of the goals of RISC-V is extensibility, it would be > nice if the QEMU port was done in a way to make it easier to extend by > third parties, including other automated tools. I'm sure that, over > time, the

Re: [Qemu-devel] [sw-dev] RFC: QEMU RISC-V modular ISA decoding

2017-07-26 Thread krste
Given that one of the goals of RISC-V is extensibility, it would be nice if the QEMU port was done in a way to make it easier to extend by third parties, including other automated tools. I'm sure that, over time, the preprocessor can be improved to automatically incorporate optimizations for

Re: [Qemu-devel] hw/core/loader-fit.c:105:41: error: expected expression

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/26/2017 01:46 PM, Programmingkid wrote: On Jul 26, 2017, at 6:24 AM, Peter Maydell wrote: On 26 July 2017 at 06:15, Programmingkid wrote: On Jul 26, 2017, at 12:13 AM, Philippe Mathieu-Daudé wrote: Hi John, On

Re: [Qemu-devel] hw/core/loader-fit.c:105:41: error: expected expression

2017-07-26 Thread Philippe Mathieu-Daudé
On 07/26/2017 01:46 PM, Programmingkid wrote: On Jul 26, 2017, at 6:24 AM, Peter Maydell wrote: On 26 July 2017 at 06:15, Programmingkid wrote: On Jul 26, 2017, at 12:13 AM, Philippe Mathieu-Daudé wrote: Hi John, On

Re: [Qemu-devel] [PATCH v3 4/4] intel_iommu: implement mru list for iotlb

2017-07-26 Thread Michael S. Tsirkin
On Mon, Jul 17, 2017 at 09:53:27AM +0800, Peter Xu wrote: > On Fri, Jul 14, 2017 at 03:28:09PM +0800, Jason Wang wrote: > > > > > > On 2017年07月14日 12:32, Peter Xu wrote: > > >On Thu, Jul 13, 2017 at 04:48:42PM +0800, Jason Wang wrote: > > >> > > >>On 2017年07月12日 16:13, Peter Xu wrote: > > >>>It

Re: [Qemu-devel] [Qemu-ppc] [for-2.11 PATCH 00/26] spapr: add support for PHB hotplug

2017-07-26 Thread Daniel Henrique Barboza
I've tested the patch set using Greg's Github branch. It worked fine in my tests using a Fedora 26 and an Ubuntu 17.04 guests. I have two observations though: 1 - This is not related to this patch set per se because it is reproducible on master, but I think it is interfering with this new

Re: [Qemu-devel] [qemu PATCH for 2.10] i386: acpi: provide an XSDT instead of an RSDT

2017-07-26 Thread Michael S. Tsirkin
On Wed, Jul 26, 2017 at 04:24:41PM -0400, Paolo Bonzini wrote: > > > The point is that for PC we really should not keep piling up hacks, > > compatibility is more important. > > Non-explosion of the test matrix is just as important. Absolutely. > > > Doing it for PC only would mean switching >

Re: [Qemu-devel] [qemu PATCH for 2.10] i386: acpi: provide an XSDT instead of an RSDT

2017-07-26 Thread Paolo Bonzini
> The point is that for PC we really should not keep piling up hacks, > compatibility is more important. Non-explosion of the test matrix is just as important. > > Doing it for PC only would mean switching > > back from FADT rev3 to rev1, which is worse for guest OS support, > > It's only OSX

Re: [Qemu-devel] [seabios PATCH 1/2] seabios: build RSDT from XSDT

2017-07-26 Thread Paolo Bonzini
- Original Message - > From: "Michael S. Tsirkin" > To: "Paolo Bonzini" > Cc: seab...@seabios.org, "Kevin O'Connor" , > qemu-devel@nongnu.org, ler...@redhat.com, > li...@philjordan.eu, imamm...@redhat.com, p...@philjordan.eu,

Re: [Qemu-devel] [SeaBIOS] Commit 77af8a2b95b79699de650965d5228772743efe84 breaks Windows 2000 support

2017-07-26 Thread Paolo Bonzini
> > (4) would be acceptable I guess. However I think it's a bit worse > > because fw-cfg files are a somewhat scarce resource. The "legacy" > > aspect is something that SeaBIOS is in the best position to address, > > because it knows what OSes are running on it; QEMU instead only takes > > care

Re: [Qemu-devel] [PATCH v2] pc: acpi: force FADT rev1 for 440fx based machine types

2017-07-26 Thread Michael S. Tsirkin
On Wed, Jul 26, 2017 at 04:09:37PM +0200, Igor Mammedov wrote: > On Tue, 25 Jul 2017 16:36:06 +0300 > "Michael S. Tsirkin" wrote: > > > On Mon, Jul 24, 2017 at 03:50:20PM +0200, Igor Mammedov wrote: > > > w2k used to boot on QEMU until revision of FADT has > > > been bumped to

Re: [Qemu-devel] [qemu PATCH for 2.10] i386: acpi: provide an XSDT instead of an RSDT

2017-07-26 Thread Michael S. Tsirkin
On Wed, Jul 26, 2017 at 03:01:25PM +0200, Paolo Bonzini wrote: > On 26/07/2017 14:52, Michael S. Tsirkin wrote: > > On Wed, Jul 26, 2017 at 11:31:36AM +0200, Paolo Bonzini wrote: > >> The tables that QEMU provides are not ACPI 1.0 compatible since commit > >> 77af8a2b95 ("hw/i386: Use Rev3 FADT

Re: [Qemu-devel] [seabios PATCH 1/2] seabios: build RSDT from XSDT

2017-07-26 Thread Michael S. Tsirkin
On Wed, Jul 26, 2017 at 11:42:34AM +0200, Paolo Bonzini wrote: > Old operating systems would like to have a rev1 (ACPI 1.0) FADT, but > new operating systems would like to have rev3 (ACPI 2.0). > > Since old operating systems do not know about XSDTs, the > solution is to point the RSDT to a rev1

Re: [Qemu-devel] [RFC PATCH v2 4/6] hw/pci: introduce bridge-only vendor-specific capability to provide some hints to firmware

2017-07-26 Thread Michael S. Tsirkin
On Sun, Jul 23, 2017 at 01:15:41AM +0300, Aleksandr Bezzubikov wrote: > On PCI init PCI bridges may need some > extra info about bus number to reserve, IO, memory and > prefetchable memory limits. QEMU can provide this > with special with a special > vendor-specific PCI capability. > > Sizes of

Re: [Qemu-devel] [SeaBIOS] Commit 77af8a2b95b79699de650965d5228772743efe84 breaks Windows 2000 support

2017-07-26 Thread Kevin O'Connor
On Wed, Jul 26, 2017 at 09:20:16AM +0200, Paolo Bonzini wrote: > On 26/07/2017 00:01, Kevin O'Connor wrote: > > On Tue, Jul 25, 2017 at 07:10:21PM +0200, Paolo Bonzini wrote: > >> On 25/07/2017 18:23, Paolo Bonzini wrote: > >>> On 25/07/2017 18:14, Laszlo Ersek wrote: > "No regressions

Re: [Qemu-devel] [PATCH v2 2/2] hmp: allow apic-id for "info lapic"

2017-07-26 Thread Eduardo Habkost
On Wed, Jul 26, 2017 at 02:18:37AM -0400, Yi Wang wrote: > Add [apic-id] support for hmp command "info lapic", which is > useful when debugging ipi and so on. Current behavior is not > changed when the parameter isn't specified. > > Signed-off-by: Yi Wang > Signed-off-by:

[Qemu-devel] [PATCH] cpu: cpu_by_arch_id() helper

2017-07-26 Thread Eduardo Habkost
The helper can be used for CPU object lookup using the CPU's arch-specific ID (the one returned by CPUClass::get_arch_id()). Signed-off-by: Eduardo Habkost [Yi Wang: Added documentation comments] Signed-off-by: Yi Wang Signed-off-by: Yun Liu

[Qemu-devel] [PULL 2/2] vfio/pci: fix use of freed memory

2017-07-26 Thread Alex Williamson
From: Philippe Mathieu-Daudé hw/vfio/pci.c:308:29: warning: Use of memory after it is freed qemu_set_fd_handler(*pfd, NULL, NULL, vdev); ^~~~ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé

Re: [Qemu-devel] [PATCH] qemu-options: document existance of versioned machine types

2017-07-26 Thread John Snow
On 07/26/2017 04:07 AM, Daniel P. Berrange wrote: On Tue, Jul 25, 2017 at 01:46:23PM -0400, John Snow wrote: On 07/25/2017 10:10 AM, Daniel P. Berrange wrote: The -machine docs did not explain what the versioned machine types are for, nor that they'll be maintained across releases.

  1   2   3   4   5   >