[Qemu-devel] [PATCH] numa-test: fix query-cpus leaks

2017-05-26 Thread Marc-André Lureau
Fix test leaks introduced in commit 2941020a476. (and small extra space removed) Spotted by ASAN. Signed-off-by: Marc-André Lureau --- tests/numa-test.c | 14 +- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/tests/numa-test.c

Re: [Qemu-devel] [PATCH v1 01/13] qcow2: alloc space for COW in one chunk

2017-05-26 Thread Kevin Wolf
Am 26.05.2017 um 12:57 hat Denis V. Lunev geschrieben: > On 05/26/2017 11:11 AM, Kevin Wolf wrote: > > > > No. This is what you bypass: > some analysis for the record. > [...] > anyway, this is a good list of things to take into account > within bdrv_allocate. But it is important, that from the >

Re: [Qemu-devel] [PATCH 03/12] migration: Switch to using announcement timer

2017-05-26 Thread Vlad Yasevich
On 05/26/2017 12:16 AM, Jason Wang wrote: > > > On 2017年05月25日 02:05, Vladislav Yasevich wrote: >> Switch qemu_announce_self and virtio annoucements to use >> the announcement timer framework. This makes sure that both >> timers use the same timeouts and number of annoucement attempts >> >>

Re: [Qemu-devel] [PATCH] qemu-ga: remove useless allocation

2017-05-26 Thread Eric Blake
On 05/26/2017 05:13 AM, Marc-André Lureau wrote: > There is no need to duplicate a fixed string. > > CC: qemu-triv...@nongnu.org > Signed-off-by: Marc-André Lureau > --- > qga/commands-posix.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) >

Re: [Qemu-devel] [PATCH 05/26] target/s390x: implement PACK

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/helper.h | 1 + target/s390x/insn-data.def | 5 + target/s390x/mem_helper.c | 37 + target/s390x/translate.c | 8 4

Re: [Qemu-devel] [PATCH 11/26] target/s390x: implement MOVE ZONES

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/helper.h | 1 + target/s390x/insn-data.def | 2 ++ target/s390x/mem_helper.c | 13 + target/s390x/translate.c | 8 4 files changed, 24

Re: [Qemu-devel] [RESEND PATCH 1/2] nvdimm: warn if the backend is not a DAX device

2017-05-26 Thread Dan Williams
On Thu, May 25, 2017 at 9:30 PM, Haozhong Zhang wrote: > On 05/25/17 20:34 -0700, Dan Williams wrote: >> On Thu, May 25, 2017 at 7:32 PM, Haozhong Zhang >> wrote: >> > Applications in Linux guest that use device-dax never trigger flush >> >

Re: [Qemu-devel] [RFC] Is it useful to create a seperate address space for cpu-memory on x86 platform?

2017-05-26 Thread Paolo Bonzini
On 26/05/2017 11:59, Gonglei (Arei) wrote: > The result before this commit: > > linux-arei:/mnt/sdb/gonglei/opensource/qemu # ps aux|grep qemu > root 12658 17.2 0.0 375996 21412 pts/1Sl+ 12:53 0:00 > ./x86_64-softmmu/qemu-system-x86_64 -machine pc-i440fx-2.5,accel=kvm,usb=off >

Re: [Qemu-devel] [PATCH V2 0/3] COLO-compare: Make COLO-compare support remote COLO-frame

2017-05-26 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1495797727-16695-1-git-send-email-zhangchen.f...@cn.fujitsu.com Subject: [Qemu-devel] [PATCH V2 0/3] COLO-compare: Make COLO-compare support remote COLO-frame === TEST

Re: [Qemu-devel] [PATCH v2] target/s390x/cpu_models: Allow some additional feature bits for the "qemu" CPU

2017-05-26 Thread David Hildenbrand
On 25.05.2017 11:22, Thomas Huth wrote: > Currently we only present the plain z900 feature bits to the guest, > but QEMU already emulates some additional features (but not all of > the next CPU generation, so we can not use the next CPU level as > default yet). Since newer Linux kernels are

Re: [Qemu-devel] [PATCH v2] kvmclock: update system_time_msr address forcibly

2017-05-26 Thread no-reply
Hi, This series failed automatic build test. Please find the testing commands and their output below. If you have docker installed, you can probably reproduce it locally. Message-id: 1495801522-27628-1-git-send-email-dplotni...@virtuozzo.com Subject: [Qemu-devel] [PATCH v2] kvmclock: update

Re: [Qemu-devel] [PATCH v7 09/20] qcow: convert QCow to use QCryptoBlock for encryption

2017-05-26 Thread Daniel P. Berrange
On Fri, May 26, 2017 at 02:03:40PM +0200, Alberto Garcia wrote: > On Thu 25 May 2017 06:38:40 PM CEST, Daniel P. Berrange wrote: > > @@ -105,6 +116,13 @@ static int qcow_open(BlockDriverState *bs, QDict > > *options, int flags, > > int ret; > > QCowHeader header; > > Error

Re: [Qemu-devel] [PATCH 02/26] target/s390x: make IPTE SMP aware

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: /* XXX we exploit the fact that Linux passes the exact virtual address here - it's not obliged to! */ -tlb_flush_page(cs, page); +tlb_flush_page_all_cpus_synced(cs, page); /* XXX 31-bit hack */ if (page &

Re: [Qemu-devel] [PATCH 06/26] target/s390x: implement LOAD PAIR FROM QUADWORD

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: +static ExitStatus op_lpq(DisasContext *s, DisasOps *o) +{ +/* In a parallel context, stop the world and single step. */ +if (parallel_cpus) { +potential_page_fault(s); +gen_exception(EXCP_ATOMIC); +return

Re: [Qemu-devel] [PATCH 08/26] target/s390x: implement MOVE INVERSE

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/helper.h | 1 + target/s390x/insn-data.def | 2 ++ target/s390x/mem_helper.c | 12 target/s390x/translate.c | 8 4 files changed, 23

Re: [Qemu-devel] [PATCH 13/26] target/s390x: improve 24-bit and 31-bit addresses write

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/mem_helper.c | 37 ++--- 1 file changed, 30 insertions(+), 7 deletions(-) Reviewed-by: Richard Henderson r~

[Qemu-devel] [PATCH v2 5/6] vhost-user: add slave-req-fd support

2017-05-26 Thread Maxime Coquelin
From: Marc-André Lureau Learn to give a socket to the slave to let him make requests to the master. Signed-off-by: Marc-André Lureau Signed-off-by: Maxime Coquelin --- docs/specs/vhost-user.txt | 32

[Qemu-devel] [PATCH V2 1/3] COLO-compare: Add new parameter for communicate with remote colo-frame

2017-05-26 Thread Zhang Chen
We add the "notify_dev=chardevID" parameter. colo-compare can connect with remote colo-frame through chardev socket, Xen colo-frame is the first user. We can notify colo-frame do checkpoint events. Signed-off-by: Zhang Chen --- net/colo-compare.c | 20

Re: [Qemu-devel] [PULL v2 00/20] Misc patches for 2017-05-19

2017-05-26 Thread Paolo Bonzini
On 24/05/2017 18:11, Paolo Bonzini wrote: > The following changes since commit 56821559f0ba682fe6b367815572e6f974d329ab: > > Merge remote-tracking branch 'dgilbert/tags/pull-hmp-20170517' into staging > (2017-05-18 13:36:15 +0100) > > are available in the git repository at: > >

Re: [Qemu-devel] [PATCH v7 09/20] qcow: convert QCow to use QCryptoBlock for encryption

2017-05-26 Thread Alberto Garcia
On Thu 25 May 2017 06:38:40 PM CEST, Daniel P. Berrange wrote: > @@ -105,6 +116,13 @@ static int qcow_open(BlockDriverState *bs, QDict > *options, int flags, > int ret; > QCowHeader header; > Error *local_err = NULL; > +QCryptoBlockOpenOptions *crypto_opts = NULL; > +

Re: [Qemu-devel] [PATCH v2] kvmclock: update system_time_msr address forcibly

2017-05-26 Thread Roman Kagan
On Fri, May 26, 2017 at 03:25:22PM +0300, Denis Plotnikov wrote: > Do an update of system_time_msr address every time before reading > the value of tsc_timestamp from guest's kvmclock page. > > There is no other code paths which ensure that qemu has an up-to-date > value of system_time_msr. So,

Re: [Qemu-devel] [PATCH v7 19/20] qcow2: report encryption specific image information

2017-05-26 Thread Daniel P. Berrange
On Thu, May 25, 2017 at 02:52:30PM -0500, Eric Blake wrote: > On 05/25/2017 11:38 AM, Daniel P. Berrange wrote: > > Currently 'qemu-img info' reports a simple "encrypted: yes" > > field. This is not very useful now that qcow2 can support > > multiple encryption formats. Users want to know which

[Qemu-devel] [PATCH v2 1/6] vhost: propagate errors in vhost_device_iotlb_miss()

2017-05-26 Thread Maxime Coquelin
Some backends might want to know when things went wrong. Signed-off-by: Maxime Coquelin --- hw/virtio/vhost.c | 15 ++- include/hw/virtio/vhost.h | 2 +- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/hw/virtio/vhost.c

[Qemu-devel] [PATCH v2 0/6] vhost-user: Specify and implement device IOTLB support

2017-05-26 Thread Maxime Coquelin
This series aims at specifying ans implementing the protocol update required to support device IOTLB with user backends. In this second non-RFC version, main changes are: - spec fixes and clarification - rings information update has been restored back to ring enablement time - Work around GCC

[Qemu-devel] [PATCH v2 4/6] vhost-user: add vhost_user to hold the chr

2017-05-26 Thread Maxime Coquelin
From: Marc-André Lureau Next patches will add more fields to the structure Signed-off-by: Marc-André Lureau Signed-off-by: Maxime Coquelin --- hw/virtio/vhost-user.c | 19 --- 1 file

Re: [Qemu-devel] [PATCH] qtest: add rtc periodic timer test

2017-05-26 Thread Paolo Bonzini
On 26/05/2017 05:21, Xiao Guangrong wrote: > On 05/26/2017 12:03 AM, Paolo Bonzini wrote: >> On 25/05/2017 05:19, guangrong.x...@gmail.com wrote: >> I'm not sure I understand. Why would clock_step(1000) not be a good >> replacement for nsleep(1000)? > > We can not. As we use the real time to

Re: [Qemu-devel] [Qemu-block] Behavior of QMP "query-block"

2017-05-26 Thread Kevin Wolf
Am 25.05.2017 um 20:44 hat Bruno Alvisio geschrieben: > Hello John, > > Thanks. Yes, typo when I wrote the e-mail. > > It might be possible that XEN does that (I will ask in the XEN forum). > However, > I have noticed that it is not the case for all of the VMs I have launched. In > some of them

Re: [Qemu-devel] [PATCH 11/13] Remove/replace chardev/char.h inclusion

2017-05-26 Thread Marc-André Lureau
On Tue, May 9, 2017 at 4:46 PM Philippe Mathieu-Daudé wrote: > Hi Marc-André Lureau, > > Isn't clearer if the "remove" part of this commit goes before your patch > 6 "move headers to include/chardev"? > make sense, reordered thanks > > On 05/09/2017 08:33 AM, Marc-André

Re: [Qemu-devel] [PATCH v2] nbd/client.c: use errp instead of LOG

2017-05-26 Thread Eric Blake
On 05/26/2017 06:09 AM, Vladimir Sementsov-Ogievskiy wrote: > Move to modern errp scheme from just LOGging errors. > > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > > Fixes: > > - local_err initialized to NULL > - 083 iotest ajusted > > \I feel like an idiot...

Re: [Qemu-devel] [PATCH 04/26] target/s390x: implement TEST ADDRESSING MODE

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: +tcg_gen_movi_i32(cc_op, cc); +set_cc_static(s); gen_op_movi_cc r~

Re: [Qemu-devel] [PATCH] RFC: vmcoreinfo device

2017-05-26 Thread Marc-André Lureau
Hi On Thu, May 4, 2017 at 5:41 PM Igor Mammedov wrote: > On Tue, 02 May 2017 19:03:15 + > Marc-André Lureau wrote: > > > Hi > > > > On Tue, May 2, 2017 at 11:17 AM Igor Mammedov > wrote: > > > > > On Fri, 28 Apr 2017

Re: [Qemu-devel] [PATCH v7 12/20] qcow2: extend specification to cover LUKS encryption

2017-05-26 Thread Daniel P. Berrange
On Thu, May 25, 2017 at 02:39:56PM -0500, Eric Blake wrote: > On 05/25/2017 11:38 AM, Daniel P. Berrange wrote: > > Update the qcow2 specification to describe how the LUKS header is > > placed inside a qcow2 file, when using LUKS encryption for the > > qcow2 payload instead of the legacy AES-CBC

Re: [Qemu-devel] [PATCH 09/26] target/s390x: implement MOVE NUMERICS

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/helper.h | 1 + target/s390x/insn-data.def | 2 ++ target/s390x/mem_helper.c | 13 + target/s390x/translate.c | 8 4 files changed, 24

[Qemu-devel] [PULL 14/22] nbd/client.c: use errp instead of LOG

2017-05-26 Thread Paolo Bonzini
From: Vladimir Sementsov-Ogievskiy Move to modern errp scheme from just LOGging errors. Signed-off-by: Vladimir Sementsov-Ogievskiy Message-Id: <20170526110913.89098-1-vsement...@virtuozzo.com> Signed-off-by: Paolo Bonzini

[Qemu-devel] [PATCH v2] nbd/client.c: use errp instead of LOG

2017-05-26 Thread Vladimir Sementsov-Ogievskiy
Move to modern errp scheme from just LOGging errors. Signed-off-by: Vladimir Sementsov-Ogievskiy --- Fixes: - local_err initialized to NULL - 083 iotest ajusted \I feel like an idiot... block/nbd-client.c | 7 ++- include/block/nbd.h| 5 +++--

Re: [Qemu-devel] [PATCH] pci: Set err to errp directly rather than through error_porpagate()

2017-05-26 Thread Mao Zhongyi
Hi, Markus On 05/26/2017 05:43 PM, Igor Mammedov wrote: On Fri, 26 May 2017 16:29:25 +0800 Mao Zhongyi wrote: ioh3420_interrupts_init() and its callers, rp_realize() and pci_qdev_realize() fill error message to local_err, then propagate it to errp by

Re: [Qemu-devel] [PATCH v1 01/13] qcow2: alloc space for COW in one chunk

2017-05-26 Thread Kevin Wolf
Am 26.05.2017 um 10:57 hat Denis V. Lunev geschrieben: > On 05/26/2017 11:11 AM, Kevin Wolf wrote: > > It seems much clearer to me that simply unifying the three write > > requests into a single one is an improvement. And it's easy to do, I > > even had a patch once to do this. The reason that I

Re: [Qemu-devel] [PATCH v7 11/20] qcow2: convert QCow2 to use QCryptoBlock for encryption

2017-05-26 Thread Alberto Garcia
On Thu 25 May 2017 06:38:42 PM CEST, Daniel P. Berrange wrote: > This converts the qcow2 driver to make use of the QCryptoBlock > APIs for encrypting image content, using the legacy QCow2 AES > scheme. > > With this change it is now required to use the QCryptoSecret > object for providing

Re: [Qemu-devel] [PATCH 01/12] migration: Introduce announce parameters

2017-05-26 Thread Vlad Yasevich
On 05/26/2017 12:03 AM, Jason Wang wrote: > > On 2017年05月25日 02:05, Vladislav Yasevich wrote: >> Add parameters that control RARP/GARP announcement timeouts. >> The parameters structure is added to the QAPI and a qmp command >> is added to set/get the parameter data. >> >> Based on work by "Dr.

Re: [Qemu-devel] [PATCH 01/12] migration: Introduce announce parameters

2017-05-26 Thread Eric Blake
On 05/24/2017 01:05 PM, Vladislav Yasevich wrote: > Add parameters that control RARP/GARP announcement timeouts. > The parameters structure is added to the QAPI and a qmp command > is added to set/get the parameter data. > > Based on work by "Dr. David Alan Gilbert" > >

Re: [Qemu-devel] [PATCH 0/7] qcow2: Reduce the number of I/O ops when doing COW

2017-05-26 Thread Anton Nefedov
On 05/26/2017 04:08 PM, Alberto Garcia wrote: On Fri 26 May 2017 02:47:55 PM CEST, Anton Nefedov wrote: Tried the another machine; about 10% improvement here [...] [root@localhost ~]# fio --name=randwrite --blocksize=4k --filename=/dev/sdb --rw=randwrite --direct=1 --ioengine=libaio

Re: [Qemu-devel] [PATCH] pci-bridge/i82801b11: Convert to realize

2017-05-26 Thread Marcel Apfelbaum
On 26/05/2017 15:15, Mao Zhongyi wrote: The pci-birdge device i82801b11 still implements the old PCIDeviceClass .init() through i82801b11_bridge_init() instead of the new .realize(). All devices need to be converted to .realize(). So convert it and rename it to i82801b11_bridge_realize().

Re: [Qemu-devel] [PATCH 07/26] target/s390x: implement STORE PAIR TO QUADWORD

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/insn-data.def | 2 ++ target/s390x/translate.c | 18 ++ 2 files changed, 20 insertions(+) diff --git a/target/s390x/insn-data.def

Re: [Qemu-devel] [PATCH v1 01/13] qcow2: alloc space for COW in one chunk

2017-05-26 Thread Denis V. Lunev
On 05/26/2017 11:11 AM, Kevin Wolf wrote: > > No. This is what you bypass: some analysis for the record. > * All sanity checks that the block layer does > > * bdrv_inc/dec_in_flight(), which is required for drain to work > correctly. Not doing this will cause crashes. Should not be a problem.

[Qemu-devel] [PATCH V2 2/3] COLO-compare: Add remote checkpoint notify chardev socket handler frame

2017-05-26 Thread Zhang Chen
Add chardev handler to get remote colo-frame's notify, Xen colo is the first user. Signed-off-by: Zhang Chen --- net/colo-compare.c | 41 ++--- 1 file changed, 38 insertions(+), 3 deletions(-) diff --git a/net/colo-compare.c

[Qemu-devel] [PATCH V2 0/3] COLO-compare: Make COLO-compare support remote COLO-frame

2017-05-26 Thread Zhang Chen
This series focus on COLO-proxy remote colo-frame support. Xen COLO-frame is the first user. We add a new chardev socket in colo-compare as the way of communicate with remote COLO-frame. And remote COLO-frame notify colo-proxy part depend on this serise:

Re: [Qemu-devel] [PATCH 07/13] chardev: serial & parallel declaration to own headers

2017-05-26 Thread Marc-André Lureau
Hi On Tue, May 9, 2017 at 3:49 PM Paolo Bonzini wrote: > > > On 09/05/2017 13:33, Marc-André Lureau wrote: > > Signed-off-by: Marc-André Lureau > > --- > > include/chardev/char-parallel.h | 20 +++- > >

Re: [Qemu-devel] [PATCH 0/7] qcow2: Reduce the number of I/O ops when doing COW

2017-05-26 Thread Anton Nefedov
On 05/26/2017 01:17 PM, Kevin Wolf wrote: Am 24.05.2017 um 18:09 hat Anton Nefedov geschrieben: I agree; as mentioned we have similar patches and they don't conflict much. We noticed a performance regression on HDD though, for the presumably optimized case (random 4k write over a large backed

Re: [Qemu-devel] [PATCH 06/12] qmp: Expose qemu_announce_self as a qmp command

2017-05-26 Thread Vlad Yasevich
On 05/26/2017 09:16 AM, Eric Blake wrote: > On 05/24/2017 01:05 PM, Vladislav Yasevich wrote: >> Add a qmp command that can trigger guest announcements. >> >> Based on work of Germano Veit Michel >> >> Signed-off-by: Vladislav Yasevich >> --- >>

Re: [Qemu-devel] [PATCH 7/7] qcow2: Merge the writing of the COW regions with the guest data

2017-05-26 Thread Alberto Garcia
On Tue 23 May 2017 01:23:02 PM CEST, Alberto Garcia wrote: You can still review this now if you want, but here's a couple of minor things I'll correct in the next revision: > +if (m->data_qiov) { > +qemu_iovec_reset(); > +qemu_iovec_add(, start_buffer, start->nb_bytes); > +

Re: [Qemu-devel] [PATCH 10/26] target/s390x: implement MOVE WITH OFFSET

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/helper.h | 1 + target/s390x/insn-data.def | 4 target/s390x/mem_helper.c | 31 +++ target/s390x/translate.c | 8 4 files

Re: [Qemu-devel] [PATCH 12/26] target/s390x: improve 24-bit and 31-bit addresses read

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Improve fix_address to also handle the 24-bit mode. Rename fix_address to wrap_address to better explain what is changed. For the same reason, rename get_address into get_address_rel and get_address_31fix into get_address_rel. Finally replace many

Re: [Qemu-devel] [PATCH v5 4/5] slirp: fix leak

2017-05-26 Thread Marc-André Lureau
On Sat, May 6, 2017 at 3:56 AM Samuel Thibault wrote: > Applied to my tree, thanks! > > still not in tree, please remove the unnecessary 'if' before merging thanks! -- Marc-André Lureau

[Qemu-devel] [PATCH V2 3/3] COLO-compare: Add remote initialization and checkpoint notification

2017-05-26 Thread Zhang Chen
Initialize remote communication socket and make a handshack with remote colo-frame. Then use this way to notify remote colo-frame do checkpoint. Signed-off-by: Zhang Chen --- net/colo-compare.c | 34 +- 1 file changed, 33

Re: [Qemu-devel] [PATCH 0/3] arm/virt: refine virt.c code and implement hot_add_cpu interface

2017-05-26 Thread Igor Mammedov
On Fri, 26 May 2017 17:21:05 +0800 Li Zhang wrote: > From: Li Zhang > > virt machine doesn't support hot_add_cpu interface. This patchset is to > implement > hot_add_cpu interface. A CPU can be added by QMP command with QEMU monitor. > > Here is

[Qemu-devel] [PATCH] pci-bridge/i82801b11: Convert to realize

2017-05-26 Thread Mao Zhongyi
The pci-birdge device i82801b11 still implements the old PCIDeviceClass .init() through i82801b11_bridge_init() instead of the new .realize(). All devices need to be converted to .realize(). So convert it and rename it to i82801b11_bridge_realize(). Signed-off-by: Mao Zhongyi

Re: [Qemu-devel] [PATCH 08/13] be-hci: use backend functions

2017-05-26 Thread Marc-André Lureau
On Tue, May 9, 2017 at 3:42 PM Marc-André Lureau < marcandre.lur...@redhat.com> wrote: > Avoid accessing CharBackend directly, use qemu_chr_be_* methods instead. > > be->chr_read should exists if qemu_chr_be_can_write() is true. > > (use qemu_chr_be_write(), _impl() bypasses replay) > >

[Qemu-devel] [PATCH v2] kvmclock: update system_time_msr address forcibly

2017-05-26 Thread Denis Plotnikov
Do an update of system_time_msr address every time before reading the value of tsc_timestamp from guest's kvmclock page. There is no other code paths which ensure that qemu has an up-to-date value of system_time_msr. So, force this update on guest's tsc_timestamp reading. This bug causes effect

Re: [Qemu-devel] [PATCH 03/26] target/s390x: implement TEST AND SET

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: +TCGv_i32 t1 = tcg_const_i32(0xff); +tcg_gen_atomic_fetch_or_i32(t1, o->in2, t1, get_mem_index(s), MO_UB); Better as tcg_gen_atomic_xchg_i32. r~

Re: [Qemu-devel] [PATCH v2] pci: Set err to errp directly rather than through error_porpagate()

2017-05-26 Thread Marcel Apfelbaum
On 26/05/2017 14:58, Mao Zhongyi wrote: ioh3420_interrupts_init() and its callers rp_realize() fill error message to local_err, then propagate it to errp by error_porpagate(), which's not necessary. So eliminate it and pass errp directly instead of local_err. Of course, error_propagate() also

Re: [Qemu-devel] [PATCH v5 5/5] dump: fix memory_mapping_filter leak

2017-05-26 Thread Marc-André Lureau
Hi On Thu, May 4, 2017 at 2:42 AM Marc-André Lureau < marcandre.lur...@redhat.com> wrote: > Spotted by ASAN. > > Signed-off-by: Marc-André Lureau > --- > memory_mapping.c | 1 + > No maintainer for this file, Wen, Paolo? > 1 file changed, 1 insertion(+) > >

[Qemu-devel] [PATCH v2] pci: Set err to errp directly rather than through error_porpagate()

2017-05-26 Thread Mao Zhongyi
ioh3420_interrupts_init() and its callers rp_realize() fill error message to local_err, then propagate it to errp by error_porpagate(), which's not necessary. So eliminate it and pass errp directly instead of local_err. Of course, error_propagate() also has been removed. Signed-off-by: Mao

Re: [Qemu-devel] [PATCH 0/7] qcow2: Reduce the number of I/O ops when doing COW

2017-05-26 Thread Alberto Garcia
On Fri 26 May 2017 02:47:55 PM CEST, Anton Nefedov wrote: > Tried the another machine; about 10% improvement here [...] > [root@localhost ~]# fio --name=randwrite --blocksize=4k > --filename=/dev/sdb --rw=randwrite --direct=1 --ioengine=libaio > --size=2g --io_size=32m In my tests I sometimes

Re: [Qemu-devel] [PATCH 06/12] qmp: Expose qemu_announce_self as a qmp command

2017-05-26 Thread Eric Blake
On 05/24/2017 01:05 PM, Vladislav Yasevich wrote: > Add a qmp command that can trigger guest announcements. > > Based on work of Germano Veit Michel > > Signed-off-by: Vladislav Yasevich > --- > migration/savevm.c | 14 ++ >

Re: [Qemu-devel] [PATCH 01/12] migration: Introduce announce parameters

2017-05-26 Thread Vlad Yasevich
On 05/26/2017 09:08 AM, Eric Blake wrote: > On 05/24/2017 01:05 PM, Vladislav Yasevich wrote: >> Add parameters that control RARP/GARP announcement timeouts. >> The parameters structure is added to the QAPI and a qmp command >> is added to set/get the parameter data. >> >> Based on work by "Dr.

Re: [Qemu-devel] [PATCH 0/7] qcow2: Reduce the number of I/O ops when doing COW

2017-05-26 Thread Alberto Garcia
On Fri 26 May 2017 03:32:49 PM CEST, Anton Nefedov wrote: >>> [root@localhost ~]# fio --name=randwrite --blocksize=4k >>> --filename=/dev/sdb --rw=randwrite --direct=1 --ioengine=libaio >>> --size=2g --io_size=32m >> >> In my tests I sometimes detected slight performance decreases in that >> HDD

Re: [Qemu-devel] [PATCH 01/26] target/s390x: remove dead code in translate.c

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/translate.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) Reviewed-by: Richard Henderson r~

Re: [Qemu-devel] [RESEND PATCH 2/2] hostmem-file: add an attribute 'align' to set its alignment

2017-05-26 Thread Dan Williams
On Fri, May 26, 2017 at 12:16 AM, Haozhong Zhang wrote: > On 05/26/17 07:05 +, Marc-André Lureau wrote: >> Hi >> >> On Fri, May 26, 2017 at 10:51 AM Haozhong Zhang >> wrote: >> >> > On 05/26/17 06:39 +, Marc-André Lureau wrote: >> > >

[Qemu-devel] [PATCH v2 2/6] vhost: rework IOTLB messaging

2017-05-26 Thread Maxime Coquelin
This patch reworks IOTLB messaging to prepare for vhost-user device IOTLB support. IOTLB messages handling is extracted from vhost-kernel backend, so that only the messages transport remains backend specifics. Signed-off-by: Maxime Coquelin --- v2: Work around GCC

[Qemu-devel] [PATCH v2 6/6] spec/vhost-user spec: Add IOMMU support

2017-05-26 Thread Maxime Coquelin
This patch specifies and implements the master/slave communication to support device IOTLB in slave. The vhost_iotlb_msg structure introduced for kernel backends is re-used, making the design close between the two backends. An exception is the use of the secondary channel to enable the slave to

[Qemu-devel] [PATCH v2 3/6] vhost: extend ring information update for IOTLB to all rings

2017-05-26 Thread Maxime Coquelin
Vhost-kernel backend need to receive IOTLB entry for used ring information early, which is done by triggering a miss event on its address. This patch extends this behaviour to all rings information, to be compatible with vhost-user backend design. Signed-off-by: Maxime Coquelin

Re: [Qemu-devel] [PATCH 05/13] char-win: close file handle except with console

2017-05-26 Thread Philippe Mathieu-Daudé
Hi Marc-André, On 05/09/2017 08:33 AM, Marc-André Lureau wrote: Only the console handle shouldn't be closed, however, the "file" handle should. Correct. Signed-off-by: Marc-André Lureau --- chardev/char-win.h | 5 ++--- chardev/char-console.c | 2 +-

Re: [Qemu-devel] [PATCH v2 1/5] numa: consolidate cpu_preplug fixups/checks for pc/arm/spapr

2017-05-26 Thread Eduardo Habkost
On Tue, May 23, 2017 at 04:38:46PM +0200, Igor Mammedov wrote: > Signed-off-by: Igor Mammedov > Reviewed-by: David Gibson > --- > v2: > user error_abort in numa_cpu_pre_plug() > Eduardo Habkost > --- >

Re: [Qemu-devel] [PATCH v2 3/5] numa: make sure that all cpus in has has_node_id set if numa is enabled

2017-05-26 Thread Eduardo Habkost
On Tue, May 23, 2017 at 04:38:48PM +0200, Igor Mammedov wrote: > It fixes/add missing _PXM object for non mapped CPU (x86) > and missing fdt node (virt-arm). > > It ensures that possible_cpus contains complete mapping if > numa is enabled by the time machine_init() is executed. > > As result non

Re: [Qemu-devel] [PATCH 21/26] target/s390x: implement PACK UNICODE

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:05 PM, Aurelien Jarno wrote: +} else if (srclen > ssize) { b = cpu_ldub_data_ra(env, src, ra) & 0x0f; -src--; -srclen--; +src -= ssize; +srclen -= ssize; Surely we need to use lduw in order to correctly read

Re: [Qemu-devel] [PATCH 22/26] target/s390x: implement UNPACK ASCII

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:05 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/helper.h | 1 + target/s390x/insn-data.def | 2 ++ target/s390x/mem_helper.c | 51 ++ target/s390x/translate.c | 17

[Qemu-devel] [PATCH v3 08/16] block/file-posix: Preallocation for truncate

2017-05-26 Thread Max Reitz
By using raw_regular_truncate() in raw_truncate(), we can now easily support preallocation. Signed-off-by: Max Reitz Reviewed-by: Stefan Hajnoczi --- block/file-posix.c | 22 ++ 1 file changed, 10 insertions(+), 12 deletions(-) diff

Re: [Qemu-devel] [PATCH v2 2/5] numa: move default mapping init to machine

2017-05-26 Thread Eduardo Habkost
On Tue, May 23, 2017 at 04:38:47PM +0200, Igor Mammedov wrote: > there is no need use cpu_index_to_instance_props() for setting > default cpu -> node mapping. Generic machine code can do it > without cpu_index by just enabling already preset defaults > in possible_cpus. > > PS: > as bonus it

[Qemu-devel] [PATCH v3 04/16] qemu-img: Expose PreallocMode for resizing

2017-05-26 Thread Max Reitz
Add a --preallocation command line option to qemu-img resize which can be used to set the PreallocMode parameter of blk_truncate(). Signed-off-by: Max Reitz --- qemu-img.c| 33 ++--- qemu-img.texi | 7 ++- 2 files changed, 36

[Qemu-devel] [PATCH v3 02/16] block: Add PreallocMode to bdrv_truncate()

2017-05-26 Thread Max Reitz
For block drivers that just pass a truncate request to the underlying protocol, we can now pass the preallocation mode instead of aborting if it is not PREALLOC_MODE_OFF. Signed-off-by: Max Reitz Reviewed-by: Stefan Hajnoczi --- include/block/block.h |

[Qemu-devel] [PATCH v3 12/16] block/qcow2: Add qcow2_refcount_area()

2017-05-26 Thread Max Reitz
This function creates a collection of self-describing refcount structures (including a new refcount table) at the end of a qcow2 image file. Optionally, these structures can also describe a number of additional clusters beyond themselves; this will be important for preallocated truncation, which

Re: [Qemu-devel] [PATCH 14/26] target/s390x: improve 24-bit and 31-bit lengths read/write

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: Signed-off-by: Aurelien Jarno --- target/s390x/mem_helper.c | 47 +-- 1 file changed, 33 insertions(+), 14 deletions(-) Reviewed-by: Richard Henderson r~

Re: [Qemu-devel] [PATCH 15/26] target/s390x: fix COMPARE LOGICAL LONG EXTENDED

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: There are multiple issues with the COMPARE LOGICAL LONG EXTENDED instruction: - The test between the two operands is inverted, leading to an inversion of the cc values 1 and 2. - The address and length of an operand continue to be decreased after

Re: [Qemu-devel] [RESEND PATCH 1/2] nvdimm: warn if the backend is not a DAX device

2017-05-26 Thread Dan Williams
On Fri, May 26, 2017 at 7:38 AM, Daniel P. Berrange wrote: > On Thu, May 25, 2017 at 08:34:23PM -0700, Dan Williams wrote: >> On Thu, May 25, 2017 at 7:32 PM, Haozhong Zhang >> wrote: >> > Applications in Linux guest that use device-dax never

Re: [Qemu-devel] [PATCH 08/13] be-hci: use backend functions

2017-05-26 Thread Philippe Mathieu-Daudé
Hi Marc-André, On 05/09/2017 08:33 AM, Marc-André Lureau wrote: Avoid accessing CharBackend directly, use qemu_chr_be_* methods instead. be->chr_read should exists if qemu_chr_be_can_write() is true. (use qemu_chr_be_write(), _impl() bypasses replay) Signed-off-by: Marc-André Lureau

Re: [Qemu-devel] [PATCH 17/26] target/s390x: improve MOVE LONG and MOVE LONG EXTENDED

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: As MVCL and MVCLE only differ by their operands, use a common do_mvcl helper. Optimize it calling fast_memmove and fast_memset. Correctly write back addresses. Signed-off-by: Aurelien Jarno --- target/s390x/mem_helper.c | 90

[Qemu-devel] [PATCH v3 09/16] block/qcow2: Generalize preallocate()

2017-05-26 Thread Max Reitz
This patch adds two new parameters to the preallocate() function so we will be able to use it not just for preallocating a new image but also for preallocated image growth. The offset parameter allows the caller to specify a virtual offset from which to start preallocating. For newly created

[Qemu-devel] [PATCH v3 13/16] block/qcow2: Rename "fail_block" to just "fail"

2017-05-26 Thread Max Reitz
Now alloc_refcount_block() only contains a single fail label, so it makes more sense to just name it "fail" instead of "fail_block". Signed-off-by: Max Reitz --- block/qcow2-refcount.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git

Re: [Qemu-devel] [PATCH 27/26] target/s390x: fix adj_len_to_page

2017-05-26 Thread Richard Henderson
On 05/25/2017 05:32 PM, Aurelien Jarno wrote: adj_len_to_page doesn't return the correct result when the address is already page aligned and the length is bigger than a page. Fix that. Signed-off-by: Aurelien Jarno --- target/s390x/mem_helper.c | 2 +- 1 file changed, 1

Re: [Qemu-devel] [RESEND PATCH 1/2] nvdimm: warn if the backend is not a DAX device

2017-05-26 Thread Daniel P. Berrange
On Thu, May 25, 2017 at 08:34:23PM -0700, Dan Williams wrote: > On Thu, May 25, 2017 at 7:32 PM, Haozhong Zhang > wrote: > > Applications in Linux guest that use device-dax never trigger flush > > that can be trapped by KVM/QEMU. Meanwhile, if the host backend is not > >

[Qemu-devel] [PULL v3 00/22] Misc patches for 2017-05-19

2017-05-26 Thread Paolo Bonzini
The following changes since commit 56821559f0ba682fe6b367815572e6f974d329ab: Merge remote-tracking branch 'dgilbert/tags/pull-hmp-20170517' into staging (2017-05-18 13:36:15 +0100) are available in the git repository at: git://github.com/bonzini/qemu.git tags/for-upstream for you to fetch

[Qemu-devel] [PULL 21/22] i386: fix read/write cr with icount option

2017-05-26 Thread Paolo Bonzini
From: Mihail Abakumov Running Windows with icount causes a crash in instruction of write cr. This patch fixes it. Reading and writing cr cause an icount read because there are called cpu_get_apic_tpr and cpu_set_apic_tpr functions. So, there is need

Re: [Qemu-devel] [PATCH v3 06/18] numa: mirror cpu to node mapping in MachineState::possible_cpus

2017-05-26 Thread Eduardo Habkost
On Wed, May 10, 2017 at 01:29:50PM +0200, Igor Mammedov wrote: [...] > diff --git a/hw/core/machine.c b/hw/core/machine.c > index 2482c63..420c8c4 100644 > --- a/hw/core/machine.c > +++ b/hw/core/machine.c > @@ -389,6 +389,102 @@ HotpluggableCPUList > *machine_query_hotpluggable_cpus(MachineState

[Qemu-devel] [PATCH v3 03/16] block: Add PreallocMode to blk_truncate()

2017-05-26 Thread Max Reitz
blk_truncate() itself will pass that value to bdrv_truncate(), and all callers of blk_truncate() just set the parameter to PREALLOC_MODE_OFF for now. Signed-off-by: Max Reitz Reviewed-by: Stefan Hajnoczi --- include/sysemu/block-backend.h | 3 ++-

[Qemu-devel] [PATCH v3 05/16] block/file-posix: Small fixes in raw_create()

2017-05-26 Thread Max Reitz
Variables should be declared at the start of a block, and if a certain parameter value is not supported it may be better to return -ENOTSUP instead of -EINVAL. Signed-off-by: Max Reitz Reviewed-by: Stefan Hajnoczi Reviewed-by: Philippe Mathieu-Daudé

[Qemu-devel] [PATCH v3 14/16] block/qcow2: falloc/full preallocating growth

2017-05-26 Thread Max Reitz
Implement the preallocation modes falloc and full for growing qcow2 images. Signed-off-by: Max Reitz --- block/qcow2.h | 5 +++ block/qcow2-refcount.c | 12 ++ block/qcow2.c | 100 - 3 files changed, 108

Re: [Qemu-devel] [PATCH 25/26] target/s390x: implement TRANSLATE ONE/TWO TO ONE/TWO

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:05 PM, Aurelien Jarno wrote: +uint32_t HELPER(trXX)(CPUS390XState *env, uint32_t r1, uint32_t r2, + uint32_t sizes) +{ +uintptr_t ra = GETPC(); +int dsize = (sizes & 1) ? 1 : 2; +int ssize = (sizes & 2) ? 1 : 2; +uint16_t tst = env->regs[0] &

[Qemu-devel] [PULL 22/22] sockets: improve error reporting if UNIX socket path is too long

2017-05-26 Thread Paolo Bonzini
From: "Daniel P. Berrange" The 'struct sockaddr_un' only allows 108 bytes for the socket path. If the user supplies a path, QEMU uses snprintf() to silently truncate it when too long. This is undesirable because the user will then be unable to connect to the path they asked

Re: [Qemu-devel] [PATCH v2 1/5] numa: consolidate cpu_preplug fixups/checks for pc/arm/spapr

2017-05-26 Thread Eduardo Habkost
On Tue, May 23, 2017 at 04:38:46PM +0200, Igor Mammedov wrote: > Signed-off-by: Igor Mammedov > Reviewed-by: David Gibson Queued on machine-next, thanks. -- Eduardo

Re: [Qemu-devel] [PATCH 16/26] target/s390x: implement COMPARE LOGICAL LONG

2017-05-26 Thread Richard Henderson
On 05/25/2017 02:04 PM, Aurelien Jarno wrote: +static ExitStatus op_clcl(DisasContext *s, DisasOps *o) +{ +TCGv_i32 r1 = tcg_const_i32(get_field(s->fields, r1)); +TCGv_i32 r2 = tcg_const_i32(get_field(s->fields, r2)); Need to force r1 and r2 even. I guess we didn't do that for clcle

  1   2   3   >