Re: [Qemu-devel] [PATCH] qemu-thread: Assert locks are initialized before using

2017-07-04 Thread Philippe Mathieu-Daudé
On Tue, Jul 4, 2017 at 9:23 AM, Fam Zheng wrote: > Not all platforms check whether a lock is initialized before used. In > particular Linux seems to be more permissive than OSX. > > Check initialization state explicitly in our code to catch such bugs > earlier. > > Signed-off-by: Fam Zheng Revi

[Qemu-devel] [PATCH v4 0/1] virtio-scsi-ccw: fix iotest 068 for s390x

2017-07-04 Thread QingFeng Hao
This commit fixes iotest 068 for s390x as s390x uses virtio-scsi-ccw. It's based on commit c324fd0a39c by Stefan Hajnoczi. Thanks! Change history: v4: Got Cornelia Huck's Reviewed-by and take the comment to change the commit message. v3: Take Christian Borntraeger and Cornelia Huck's

[Qemu-devel] [PATCH v4 1/1] virtio-scsi-ccw: use ioeventfd even when KVM is disabled

2017-07-04 Thread QingFeng Hao
This patch is based on a similar patch from Stefan Hajnoczi - commit c324fd0a39c ("virtio-pci: use ioeventfd even when KVM is disabled") Do not check kvm_eventfds_enabled() when KVM is disabled since it always returns 0. Since commit 8c56c1a592b5092d91da8d8943c1d6462a6f ("memory: emulate ioev

Re: [Qemu-devel] [PATCH] qemu-img: delete the -e and -6 options from the 'create' command

2017-07-04 Thread Kashyap Chamarthy
On Tue, Jul 04, 2017 at 11:34:27AM +0100, Daniel P. Berrange wrote: > The '-e' and '-6' options to the 'create' command were "deprecated" > in favour of the more generic '-o' option many years ago: > > commit eec77d9e712bd4157a4e1c0b5a9249d168add738 > Author: Jes Sorensen > Date: Tue Dec

Re: [Qemu-devel] [PATCH v3 1/2] docs: document support lifetime for features

2017-07-04 Thread Daniel P. Berrange
On Tue, Jul 04, 2017 at 02:43:29PM +0200, Thomas Huth wrote: > On 04.07.2017 13:14, Daniel P. Berrange wrote: > > There is currently no explicit guidance on the duration of support > > for features such as versioned machine types, which have a finite > > useful lifespan. Thus apps / users cannot pr

Re: [Qemu-devel] [PATCH v3 2/2] docs: document deprecated features in appendix

2017-07-04 Thread Daniel P. Berrange
On Tue, Jul 04, 2017 at 02:59:27PM +0200, Thomas Huth wrote: > On 04.07.2017 13:14, Daniel P. Berrange wrote: > > The deprecation of features in QEMU is totally adhoc currently, > > with no way for the user to get a list of what is deprecated > > in each release. This adds an appendix to the doc th

[Qemu-devel] [PATCH] spapr: Only report host/guest IOMMU page size mismatches on KVM

2017-07-04 Thread David Gibson
We print a warning if the spapr IOMMU isn't configured to support a page size matching the host page size backing RAM. When that's the case we need more complex logic to translate VFIO mappings, which is slower. But, it's not so slow that it would be at all noticeable against the general slowness

Re: [Qemu-devel] [PATCH v4 1/1] virtio-scsi-ccw: use ioeventfd even when KVM is disabled

2017-07-04 Thread Christian Borntraeger
On 07/04/2017 03:23 PM, QingFeng Hao wrote: > This patch is based on a similar patch from Stefan Hajnoczi - > commit c324fd0a39c ("virtio-pci: use ioeventfd even when KVM is disabled") > > Do not check kvm_eventfds_enabled() when KVM is disabled since it > always returns 0. Since commit 8c56c1a59

Re: [Qemu-devel] [PATCH] spapr: Only report host/guest IOMMU page size mismatches on KVM

2017-07-04 Thread Thomas Huth
On 04.07.2017 15:54, David Gibson wrote: > We print a warning if the spapr IOMMU isn't configured to support a page > size matching the host page size backing RAM. When that's the case we need > more complex logic to translate VFIO mappings, which is slower. > > But, it's not so slow that it woul

[Qemu-devel] [PATCH 2/7] s390x/3270: fix instruction interception handler

2017-07-04 Thread Christian Borntraeger
From: Dong Jia Shi Commit bab482d7405f ("s390x/css: ccw translation infrastructure") introduced instruction interception handler for different types of subchannels. For emulated 3270 devices, we should assign the virtual subchannel handler to them during device realization process, or 3270 will n

[Qemu-devel] [PATCH 4/7] s390x: fix realize inheritance for kvm-flic

2017-07-04 Thread Christian Borntraeger
From: Halil Pasic Commit f6f4ce4211 ("s390x: add property adapter_routes_max_batch", 2016-12-09) introduces a common realize (intended to be common for all the subclasses) for flic, but fails to make sure the kvm-flic which had it's own is actually calling this common realize. This omission fort

[Qemu-devel] [PATCH 3/7] s390x: fix error propagation in kvm-flic's realize

2017-07-04 Thread Christian Borntraeger
From: Halil Pasic >From the moment it was introduced by commit a2875e6f98 ("s390x/kvm: implement floating-interrupt controller device", 2013-07-16) the kvm-flic is not making realize fail properly in case it's impossible to create the KVM device which basically serves as a backend and is absolute

[Qemu-devel] [PATCH 5/7] s390x/MAINTAINERS: Update my email address

2017-07-04 Thread Christian Borntraeger
From: Cornelia Huck Signed-off-by: Cornelia Huck Message-Id: <20170704092215.13742-2-coh...@redhat.com> Signed-off-by: Christian Borntraeger --- MAINTAINERS | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 839f7ca..4e17216 100644 --- a

[Qemu-devel] [PATCH 6/7] s390x: return unavailable features via query-cpu-definitions

2017-07-04 Thread Christian Borntraeger
From: Viktor Mihajlovski The response for query-cpu-definitions didn't include the unavailable-features field, which is used by libvirt to figure out whether a certain cpu model is usable on the host. The unavailable features are now computed by obtaining the host CPU model and comparing it agai

[Qemu-devel] [PATCH 7/7] virtio-scsi-ccw: use ioeventfd even when KVM is disabled

2017-07-04 Thread Christian Borntraeger
From: QingFeng Hao This patch is based on a similar patch from Stefan Hajnoczi - commit c324fd0a39c ("virtio-pci: use ioeventfd even when KVM is disabled") Do not check kvm_eventfds_enabled() when KVM is disabled since it always returns 0. Since commit 8c56c1a592b5092d91da8d8943c1d6462a6f (

[Qemu-devel] [PATCH 0/7] s390x/kvm: pending patches

2017-07-04 Thread Christian Borntraeger
This is what I have queued for s390x. Cornelia Huck (1): s390x/MAINTAINERS: Update my email address Dong Jia Shi (1): s390x/3270: fix instruction interception handler Halil Pasic (3): s390x: vmstatify config migration for virtio-ccw s390x: fix error propagation in kvm-flic's realize s3

[Qemu-devel] [PATCH 1/7] s390x: vmstatify config migration for virtio-ccw

2017-07-04 Thread Christian Borntraeger
From: Halil Pasic Let's vmstatify virtio_ccw_save_config and virtio_ccw_load_config for flexibility (extending using subsections) and for fun. To achieve this we need to hack the config_vector, which is VirtIODevice (that is common virtio) state, in the middle of the VirtioCcwDevice state repres

Re: [Qemu-devel] [RFC 29/29] vhost-user: Claim support for postcopy

2017-07-04 Thread Maxime Coquelin
On 06/28/2017 09:00 PM, Dr. David Alan Gilbert (git) wrote: From: "Dr. David Alan Gilbert" Tell QEMU we understand the protocol features needed for postcopy. Signed-off-by: Dr. David Alan Gilbert --- contrib/libvhost-user/libvhost-user.c | 3 ++- 1 file changed, 2 insertions(+), 1 deleti

Re: [Qemu-devel] [Xen-devel] [PATCH 2/2 v2] xenfb: Allow vkbd to connect without a DisplayState

2017-07-04 Thread Oleksandr Grytsov
On Mon, Jul 3, 2017 at 4:17 PM, Owen Smith wrote: > If the vkbd device model is registered and the vfb device model > is not registered, the backend will not transition to connected. > If there is no DisplayState, then the absolute coordinates cannot > be scaled, and will remain in the range [0, 0

[Qemu-devel] [PATCH] vhost: fix a memory leak

2017-07-04 Thread Peng Hao
vhost exists a call for g_file_get_contents, but not call g_free. Signed-off-by: Peng Hao --- hw/virtio/vhost-backend.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/virtio/vhost-backend.c b/hw/virtio/vhost-backend.c index 4e31de1..2c481d6 100644 --- a/hw/virtio/vhost-backend.c +++ b/h

Re: [Qemu-devel] [PATCH v3 1/1] virtio-scsi-ccw: use ioeventfd even when KVM is disabled

2017-07-04 Thread Cornelia Huck
On Tue, 4 Jul 2017 10:32:31 +0200 QingFeng Hao wrote: > This patch is based on a similar patch from Stefan Hajnoczi - > commit c324fd0a39c (" virtio-pci: use ioeventfd even when KVM is disabled) > > Do not check kvm_eventfds_enabled() when KVM is disabled since it > always returns 0. Since com

[Qemu-devel] [PATCH] audio: st_rate_flow exist a dead loop

2017-07-04 Thread Peng Hao
From: Hao Peng if audio device is opend for a long time in windows vm, there is a uint32_t varaible reversal. It will result to a dead loop. Signed-off-by: Peng Hao Reviewed-by: Liu Yun Reviewed-by: Wang Yechao --- audio/rate_template.h | 5 + 1 file changed, 5 insertions(+) diff --git

[Qemu-devel] [PATCH 1/1] Update my email address

2017-07-04 Thread Cornelia Huck
Signed-off-by: Cornelia Huck --- MAINTAINERS | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 7df088259b..afc2b8b328 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -299,7 +299,7 @@ F: target/ppc/kvm.c S390 M: Christian Borntraeger -M:

Re: [Qemu-devel] postcopy migration hangs while loading virtio state

2017-07-04 Thread Martin Schwidefsky
On Tue, 4 Jul 2017 09:48:11 +0200 Christian Borntraeger wrote: > On 07/03/2017 09:07 PM, Dr. David Alan Gilbert wrote: > > * Michael S. Tsirkin (m...@redhat.com) wrote: > >> On Fri, Jun 30, 2017 at 05:31:39PM +0100, Dr. David Alan Gilbert wrote: > >>> * Christian Borntraeger (borntrae...@de.i

[Qemu-devel] [PATCH 0/1] Change mail address

2017-07-04 Thread Cornelia Huck
New employer, new address. Make sure people use the right one. Christian, it's probably quickest if you take this. Cornelia Huck (1): Update my email address MAINTAINERS | 8 1 file changed, 4 insertions(+), 4 deletions(-) -- 2.13.0

Re: [Qemu-devel] [PATCH 2/7] s390x/3270: fix instruction interception handler

2017-07-04 Thread Cornelia Huck
On Tue, 4 Jul 2017 16:07:54 +0200 Christian Borntraeger wrote: > From: Dong Jia Shi > > Commit bab482d7405f ("s390x/css: ccw translation infrastructure") > introduced instruction interception handler for different types of > subchannels. For emulated 3270 devices, we should assign the virtual

Re: [Qemu-devel] [PATCH] vhost: fix a memory leak

2017-07-04 Thread Marc-André Lureau
Hi On Tue, Jul 4, 2017 at 4:16 PM Peng Hao wrote: > vhost exists a call for g_file_get_contents, but not call g_free. > > Signed-off-by: Peng Hao > Reviewed-by: Marc-André Lureau --- > hw/virtio/vhost-backend.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/hw/virtio/vhost-backe

Re: [Qemu-devel] [PATCH 3/7] s390x: fix error propagation in kvm-flic's realize

2017-07-04 Thread Cornelia Huck
On Tue, 4 Jul 2017 16:07:55 +0200 Christian Borntraeger wrote: > From: Halil Pasic > > From the moment it was introduced by commit a2875e6f98 ("s390x/kvm: > implement floating-interrupt controller device", 2013-07-16) the kvm-flic > is not making realize fail properly in case it's impossible t

Re: [Qemu-devel] [PATCH RESEND v6] qga: Add support network interface statistics in guest-network-get-interfaces command

2017-07-04 Thread Marc-André Lureau
Hi On Tue, Jul 4, 2017 at 10:51 AM ZhiPeng Lu wrote: > we can get the network interface statistics inside a virtual machine by > guest-network-get-interfaces command. it is very useful for us to monitor > and analyze network traffic. > > It's nicer if you give v1->v2->..->v6 change summary at ea

Re: [Qemu-devel] [PATCH 4/7] s390x: fix realize inheritance for kvm-flic

2017-07-04 Thread Cornelia Huck
On Tue, 4 Jul 2017 16:07:56 +0200 Christian Borntraeger wrote: > From: Halil Pasic > > Commit f6f4ce4211 ("s390x: add property adapter_routes_max_batch", > 2016-12-09) introduces a common realize (intended to be common for all > the subclasses) for flic, but fails to make sure the kvm-flic whi

Re: [Qemu-devel] [PATCH 6/7] s390x: return unavailable features via query-cpu-definitions

2017-07-04 Thread Cornelia Huck
On Tue, 4 Jul 2017 16:07:58 +0200 Christian Borntraeger wrote: > From: Viktor Mihajlovski > > The response for query-cpu-definitions didn't include the > unavailable-features field, which is used by libvirt to figure > out whether a certain cpu model is usable on the host. > > The unavailable

Re: [Qemu-devel] [PATCH v2] blockdev: Print a warning for legacy drive options that belong to -device

2017-07-04 Thread Kevin Wolf
Am 12.05.2017 um 12:33 hat Thomas Huth geschrieben: > We likely do not want to carry these legacy -drive options along forever. > Let's emit a deprecation warning for the -drive options that have a > replacement with the -device option, so that the (hopefully few) remaining > users are aware of thi

Re: [Qemu-devel] [PATCH] qemu-doc: Add missing "@c man end" statements

2017-07-04 Thread Kevin Wolf
Am 19.06.2017 um 11:16 hat Thomas Huth geschrieben: > Since commit 3f2ce724f1f1 ("Move the qemu-ga description into a > separate chapter"), the qemu.1 man page looks pretty much screwed > up, e.g. the title was "qemu-ga - QEMU Guest Agent" instead of > "qemu-doc - QEMU Emulator User Documentation".

Re: [Qemu-devel] [PATCH 3/7] s390x: fix error propagation in kvm-flic's realize

2017-07-04 Thread Halil Pasic
On 07/04/2017 04:31 PM, Cornelia Huck wrote: > On Tue, 4 Jul 2017 16:07:55 +0200 > Christian Borntraeger wrote: > >> From: Halil Pasic >> >> From the moment it was introduced by commit a2875e6f98 ("s390x/kvm: >> implement floating-interrupt controller device", 2013-07-16) the kvm-flic >> is n

[Qemu-devel] [RISU PATCH 01/11] risu: make match status take tracing into account

2017-07-04 Thread Alex Bennée
Signed-off-by: Alex Bennée --- reginfo.c | 14 +- risu.c| 4 ++-- risu.h| 2 +- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/reginfo.c b/reginfo.c index 13879d5..d9d37b3 100644 --- a/reginfo.c +++ b/reginfo.c @@ -138,7 +138,7 @@ int recv_and_compare_regist

[Qemu-devel] [RISU PATCH 03/11] README: document --static builds

2017-07-04 Thread Alex Bennée
Signed-off-by: Alex Bennée --- README | 16 +--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/README b/README index 858a349..e0bf5c5 100644 --- a/README +++ b/README @@ -17,7 +17,7 @@ test blobs (which can be run anywhere), and a Linux executable 'risu' which runs o

[Qemu-devel] [RISU PATCH 00/11] Misc fixes, documentation and patterns

2017-07-04 Thread Alex Bennée
Hi Peter, A bit of a mixed set of patches here for you to pick from as you will. The first 2 are additional tracing fixes including a fix for segfaulting when generating a trace. The next two are documentation patches as requested. Then two minor tweaks, one to risu.el and a indent failure of ri

[Qemu-devel] [RISU PATCH 04/11] README: document record/replay support

2017-07-04 Thread Alex Bennée
Signed-off-by: Alex Bennée --- README | 24 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/README b/README index e0bf5c5..5f16f60 100644 --- a/README +++ b/README @@ -107,6 +107,26 @@ mismatch status to its standard output. NB that in the register dump th

[Qemu-devel] [RISU PATCH 05/11] risu.el: derive from text-mode

2017-07-04 Thread Alex Bennée
As RISU files have copious commentary it seems better to derive from text-mode so we can access things like spell-checker short cuts ;-) Signed-off-by: Alex Bennée --- risu.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/risu.el b/risu.el index dff9337..1875d02 100644 ---

[Qemu-devel] [RISU PATCH 06/11] risugen: fix bad indent

2017-07-04 Thread Alex Bennée
Signed-off-by: Alex Bennée --- risugen | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/risugen b/risugen index 8b20425..347cf12 100755 --- a/risugen +++ b/risugen @@ -262,7 +262,7 @@ Valid options: These REs are applied after the matching pattern which

[Qemu-devel] [RISU PATCH 02/11] reginfo.c: always return 1 on OP_TESTEND

2017-07-04 Thread Alex Bennée
In the master/apprentice setup the response byte of 1 is returned by write_fn. However when tracing it will happily report 0 as it successfully writes the last bytes. To avoid running of the end when tracing we just always return 1 at this point. Signed-off-by: Alex Bennée --- reginfo.c | 5

[Qemu-devel] [RISU PATCH 07/11] risugen: support @GroupName in risu files

2017-07-04 Thread Alex Bennée
The existing pattern support is useful but it does get a little tedious when faced with large groups of instructions. This introduces the concept of a @GroupName which can be sprinkled in the risu definition and is attached to all instructions following its definition until the next group or an emp

[Qemu-devel] [RISU PATCH 09/11] aarch64.risu: remove duplicate AdvSIMD Scalar 3 same block

2017-07-04 Thread Alex Bennée
A chunk of the AArch64 definitions repeat themselves. Clean that up. Signed-off-by: Alex Bennée --- aarch64.risu | 25 +++-- 1 file changed, 3 insertions(+), 22 deletions(-) diff --git a/aarch64.risu b/aarch64.risu index bfca45f..609021a 100644 --- a/aarch64.risu +++ b/aarch

Re: [Qemu-devel] [PATCH 2/5] spapr: Refactor spapr_drc_detach()

2017-07-04 Thread David Gibson
On Thu, Jun 22, 2017 at 11:32:15AM +0200, Greg Kurz wrote: > On Wed, 21 Jun 2017 17:18:45 +0800 > David Gibson wrote: > > > This function has two unused parameters - remove them. > > > > It's ok for the d argument but I'm not sure about errp... Indeed it isn't used > in the current code, but lo

[Qemu-devel] [RISU PATCH 10/11] aarch64.risu: remove duplicate AdvSIMD scalar 2 reg misc block

2017-07-04 Thread Alex Bennée
While at that also: - sort alphabetically - add to @AdvSIMDScalar2RegMisc group Signed-off-by: Alex Bennée --- aarch64.risu | 114 --- 1 file changed, 39 insertions(+), 75 deletions(-) diff --git a/aarch64.risu b/aarch64.risu index 609

[Qemu-devel] [RISU PATCH 08/11] aarch64.risu: document naming conventions

2017-07-04 Thread Alex Bennée
Signed-off-by: Alex Bennée --- aarch64.risu | 10 ++ 1 file changed, 10 insertions(+) diff --git a/aarch64.risu b/aarch64.risu index 2f3341c..bfca45f 100644 --- a/aarch64.risu +++ b/aarch64.risu @@ -7,6 +7,7 @@ # # Contributors: # Claudio Fontana - initial implementation +# Al

[Qemu-devel] [RISU PATCH 11/11] aarch64.risu: update AdvancedSIMD across lanes

2017-07-04 Thread Alex Bennée
- sorted alphabetically - aligned the instructions patterns - adding half-precision F[MAX|MIN][NMV|V] - add @AdvSIMDAcrossVector group Signed-off-by: Alex Bennée --- aarch64.risu | 90 +--- 1 file changed, 49 insertions(+), 41 deletions

Re: [Qemu-devel] [PATCH 4/7] s390x: fix realize inheritance for kvm-flic

2017-07-04 Thread Halil Pasic
On 07/04/2017 04:37 PM, Cornelia Huck wrote: > On Tue, 4 Jul 2017 16:07:56 +0200 > Christian Borntraeger wrote: > >> From: Halil Pasic >> >> Commit f6f4ce4211 ("s390x: add property adapter_routes_max_batch", >> 2016-12-09) introduces a common realize (intended to be common for all >> the subc

Re: [Qemu-devel] [PATCH v7 2/4] net/socket: Convert several helper functions to Error

2017-07-04 Thread Markus Armbruster
Mao Zhongyi writes: > Currently, net_socket_mcast_create(), net_socket_fd_init_dgram() and > net_socket_fd_init() use the function such as fprintf(), perror() to > report an error message. > > Now, convert these functions to Error. > > Cc: jasow...@redhat.com > Cc: arm...@redhat.com > Cc: berra..

Re: [Qemu-devel] [PATCH v3 04/20] stream: Switch stream_run() to byte-based

2017-07-04 Thread Kevin Wolf
Am 27.06.2017 um 21:24 hat Eric Blake geschrieben: > We are gradually converting to byte-based interfaces, as they are > easier to reason about than sector-based. Change the internal > loop iteration of streaming to track by bytes instead of sectors > (although we are still guaranteed that we iter

Re: [Qemu-devel] [PATCH v7 3/4] net/net: Convert parse_host_port() to Error

2017-07-04 Thread Markus Armbruster
Mao Zhongyi writes: > Cc: berra...@redhat.com > Cc: kra...@redhat.com > Cc: pbonz...@redhat.com > Cc: jasow...@redhat.com > Cc: arm...@redhat.com > Cc: ebl...@redhat.com > Signed-off-by: Mao Zhongyi Reviewed-by: Markus Armbruster

Re: [Qemu-devel] [PATCH 3/7] s390x: fix error propagation in kvm-flic's realize

2017-07-04 Thread Halil Pasic
On 07/04/2017 04:46 PM, Halil Pasic wrote: > > > On 07/04/2017 04:31 PM, Cornelia Huck wrote: >> On Tue, 4 Jul 2017 16:07:55 +0200 >> Christian Borntraeger wrote: >> >>> From: Halil Pasic >>> >>> From the moment it was introduced by commit a2875e6f98 ("s390x/kvm: >>> implement floating-inter

Re: [Qemu-devel] [PATCH] qemu-doc: Add missing "@c man end" statements

2017-07-04 Thread Paolo Bonzini
On 04/07/2017 16:46, Kevin Wolf wrote: > Am 19.06.2017 um 11:16 hat Thomas Huth geschrieben: >> Since commit 3f2ce724f1f1 ("Move the qemu-ga description into a >> separate chapter"), the qemu.1 man page looks pretty much screwed >> up, e.g. the title was "qemu-ga - QEMU Guest Agent" instead of >>

Re: [Qemu-devel] [PATCH v3 02/20] trace: Show blockjob actions via bytes, not sectors

2017-07-04 Thread Kevin Wolf
Am 27.06.2017 um 21:24 hat Eric Blake geschrieben: > Upcoming patches are going to switch to byte-based interfaces > instead of sector-based. Even worse, trace_backup_do_cow_enter() > had a weird mix of cluster and sector indices. > > The trace interface is low enough that there are no stability

Re: [Qemu-devel] [PATCH v3 01/20] blockjob: Track job ratelimits via bytes, not sectors

2017-07-04 Thread Kevin Wolf
Am 27.06.2017 um 21:24 hat Eric Blake geschrieben: > The user interface specifies job rate limits in bytes/second. > It's pointless to have our internal representation track things > in sectors/second, particularly since we want to move away from > sector-based interfaces. > > Fix up a doc typo fo

Re: [Qemu-devel] [PATCH v3 05/20] commit: Switch commit_populate() to byte-based

2017-07-04 Thread Kevin Wolf
Am 27.06.2017 um 21:24 hat Eric Blake geschrieben: > We are gradually converting to byte-based interfaces, as they are > easier to reason about than sector-based. Start by converting an > internal function (no semantic change). > > Signed-off-by: Eric Blake > Reviewed-by: John Snow Reviewed-by

Re: [Qemu-devel] [PATCH v3 06/20] commit: Switch commit_run() to byte-based

2017-07-04 Thread Kevin Wolf
Am 27.06.2017 um 21:24 hat Eric Blake geschrieben: > We are gradually converting to byte-based interfaces, as they are > easier to reason about than sector-based. Change the internal > loop iteration of committing to track by bytes instead of sectors > (although we are still guaranteed that we ite

Re: [Qemu-devel] [PATCH v3 03/20] stream: Switch stream_populate() to byte-based

2017-07-04 Thread Kevin Wolf
Am 27.06.2017 um 21:24 hat Eric Blake geschrieben: > We are gradually converting to byte-based interfaces, as they are > easier to reason about than sector-based. Start by converting an > internal function (no semantic change). > > Signed-off-by: Eric Blake > Reviewed-by: John Snow Reviewed-by

[Qemu-devel] [PATCH v7 4/6] hmp: create a throttle initialization function for code reusability

2017-07-04 Thread Pradeep Jagadeesh
This patch creates a throttle initialization function to maximize the code reusability. The same code is also used by fsdev. Acked-by: Dr. David Alan Gilbert Signed-off-by: Pradeep Jagadeesh --- hmp.c | 19 +-- 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/hmp.c

[Qemu-devel] [PATCH v7 3/6] throttle: move out function to reuse the code

2017-07-04 Thread Pradeep Jagadeesh
This patch move out the throttle code to util/throttle.c to maximize the reusability of the code.The same code is also used by fsdev. Signed-off-by: Pradeep Jagadeesh --- blockdev.c | 53 +++- include/qemu/throttle-options.h | 3 +++ util/thr

[Qemu-devel] [PATCH v7 1/6] throttle: factor out duplicate code

2017-07-04 Thread Pradeep Jagadeesh
This patch factor out the duplicate throttle code that was present in block and fsdev devices. Signed-off-by: Pradeep Jagadeesh Reviewed-by: Alberto Garcia --- blockdev.c | 44 +-- fsdev/qemu-fsdev-throttle.c | 44 ++--

[Qemu-devel] [PATCH v7 5/6] fsdev: hmp interface for throttling

2017-07-04 Thread Pradeep Jagadeesh
This patch introduces hmp interfaces for the fsdev devices. Signed-off-by: Pradeep Jagadeesh --- hmp-commands-info.hx | 18 +++ hmp-commands.hx | 19 hmp.c| 62 hmp.h| 4

[Qemu-devel] [PATCH v7 2/6] qmp: Create IOThrottle structure

2017-07-04 Thread Pradeep Jagadeesh
This patch enables qmp interfaces for the fsdev devices. This provides two interfaces one for querying info of all the fsdev devices. The second one to set the IO limits for the required fsdev device. Signed-off-by: Pradeep Jagadeesh Reviewed-by: Greg Kurz Reviewed-by: Eric Blake Reviewed-by:

[Qemu-devel] [PATCH v7 6/6] fsdev: QMP interface for throttling

2017-07-04 Thread Pradeep Jagadeesh
This patch introduces qmp interfaces for the fsdev devices. This provides two interfaces one for querying info of all the fsdev devices. The second one to set the IO limits for the required fsdev device. Signed-off-by: Pradeep Jagadeesh --- Makefile| 4 +++ fsdev/qemu-fsdev

[Qemu-devel] [PATCH v7 0/6] fsdev: qmp interface for io throttling

2017-07-04 Thread Pradeep Jagadeesh
These patches provide the qmp interface, to query the io throttle status of the all fsdev devices that are present in a vm. also, it provides an interface to set the io throttle parameters of a fsdev to a required value. some of the patches also remove the duplicate code that was present in block

Re: [Qemu-devel] [Qemu-block] [PATCH v4 1/2] live-block-ops.txt: Rename, rewrite, and improve it

2017-07-04 Thread Kashyap Chamarthy
On Wed, Jun 28, 2017 at 03:33:49PM -0500, Eric Blake wrote: > On 06/28/2017 03:15 PM, Alberto Garcia wrote: > > On Wed 28 Jun 2017 04:58:00 PM CEST, Kashyap Chamarthy wrote: > >> This patch documents (including their QMP invocations) all the four > >> major kinds of live block operations: > >> > >>

[Qemu-devel] [PATCH v2 4/4] xen: don't use xenstore to save/restore physmap anymore

2017-07-04 Thread Igor Druzhinin
If we have a system with xenforeignmemory_map2() implemented we don't need to save/restore physmap on suspend/restore anymore. In case we resume a VM without physmap - try to recreate the physmap during memory region restore phase and remap map cache entries accordingly. The old code is left for co

[Qemu-devel] [PATCH v2 0/4] xen: don't save/restore the physmap on VM save/restore

2017-07-04 Thread Igor Druzhinin
Saving/restoring the physmap to/from xenstore was introduced to QEMU majorly in order to cover up the VRAM region restore issue. The sequence of restore operations implies that we should know the effective guest VRAM address *before* we have the VRAM region restored (which happens later). Unfortuna

[Qemu-devel] [PATCH v2 1/4] xen: move physmap saving into a separate function

2017-07-04 Thread Igor Druzhinin
Non-functional change. Signed-off-by: Igor Druzhinin --- hw/i386/xen/xen-hvm.c | 57 --- 1 file changed, 31 insertions(+), 26 deletions(-) diff --git a/hw/i386/xen/xen-hvm.c b/hw/i386/xen/xen-hvm.c index cffa7e2..d259cf7 100644 --- a/hw/i386/xen/x

[Qemu-devel] [PATCH v2 2/4] xen/mapcache: add an ability to create dummy mappings

2017-07-04 Thread Igor Druzhinin
Dummys are simple anonymous mappings that are placed instead of regular foreign mappings in certain situations when we need to postpone the actual mapping but still have to give a memory region to QEMU to play with. This is planned to be used for restore on Xen. Signed-off-by: Igor Druzhinin ---

[Qemu-devel] [PATCH v2 3/4] xen/mapcache: introduce xen_replace_cache_entry()

2017-07-04 Thread Igor Druzhinin
This new call is trying to update a requested map cache entry according to the changes in the physmap. The call is searching for the entry, unmaps it and maps again at the same place using a new guest address. If the mapping is dummy this call will make it real. This function makes use of a new xe

Re: [Qemu-devel] [PATCH v2 1/4] xen: move physmap saving into a separate function

2017-07-04 Thread Paul Durrant
> -Original Message- > From: Igor Druzhinin > Sent: 04 July 2017 16:48 > To: xen-de...@lists.xenproject.org; qemu-devel@nongnu.org > Cc: Igor Druzhinin ; sstabell...@kernel.org; > Anthony Perard ; Paul Durrant > ; pbonz...@redhat.com > Subject: [PATCH v2 1/4] xen: move physmap saving into

Re: [Qemu-devel] [PATCH v2 2/4] xen/mapcache: add an ability to create dummy mappings

2017-07-04 Thread Paul Durrant
> -Original Message- > From: Igor Druzhinin > Sent: 04 July 2017 16:48 > To: xen-de...@lists.xenproject.org; qemu-devel@nongnu.org > Cc: Igor Druzhinin ; sstabell...@kernel.org; > Anthony Perard ; Paul Durrant > ; pbonz...@redhat.com > Subject: [PATCH v2 2/4] xen/mapcache: add an ability to

Re: [Qemu-devel] [PATCH v7 4/4] net/socket: Improve -net socket error reporting

2017-07-04 Thread Markus Armbruster
Mao Zhongyi writes: > When -net socket fails, it first reports a specific error, then > a generic one, like this: > > $ qemu-system-x86_64 -net socket, > qemu-system-x86_64: -net socket: exactly one of fd=, listen=, connect=, > mcast= or udp= is required > qemu-system-x86_64: -net so

Re: [Qemu-devel] [PATCH v2 3/4] xen/mapcache: introduce xen_replace_cache_entry()

2017-07-04 Thread Paul Durrant
> -Original Message- > From: Igor Druzhinin > Sent: 04 July 2017 16:48 > To: xen-de...@lists.xenproject.org; qemu-devel@nongnu.org > Cc: Igor Druzhinin ; sstabell...@kernel.org; > Anthony Perard ; Paul Durrant > ; pbonz...@redhat.com > Subject: [PATCH v2 3/4] xen/mapcache: introduce > xen_r

Re: [Qemu-devel] [PATCH v2 3/4] xen/mapcache: introduce xen_replace_cache_entry()

2017-07-04 Thread Igor Druzhinin
On 04/07/17 17:27, Paul Durrant wrote: >> -Original Message- >> From: Igor Druzhinin >> Sent: 04 July 2017 16:48 >> To: xen-de...@lists.xenproject.org; qemu-devel@nongnu.org >> Cc: Igor Druzhinin ; sstabell...@kernel.org; >> Anthony Perard ; Paul Durrant >> ; pbonz...@redhat.com >> Subject:

Re: [Qemu-devel] [PATCH v2 3/4] xen/mapcache: introduce xen_replace_cache_entry()

2017-07-04 Thread Paul Durrant
> -Original Message- > From: Igor Druzhinin > Sent: 04 July 2017 17:34 > To: Paul Durrant ; xen-de...@lists.xenproject.org; > qemu-devel@nongnu.org > Cc: sstabell...@kernel.org; Anthony Perard ; > pbonz...@redhat.com > Subject: Re: [PATCH v2 3/4] xen/mapcache: introduce > xen_replace_cache_

Re: [Qemu-devel] [PATCH v2 3/4] xen/mapcache: introduce xen_replace_cache_entry()

2017-07-04 Thread Igor Druzhinin
On 04/07/17 17:42, Paul Durrant wrote: >> -Original Message- >> From: Igor Druzhinin >> Sent: 04 July 2017 17:34 >> To: Paul Durrant ; xen-de...@lists.xenproject.org; >> qemu-devel@nongnu.org >> Cc: sstabell...@kernel.org; Anthony Perard ; >> pbonz...@redhat.com >> Subject: Re: [PATCH v2 3/

Re: [Qemu-devel] [PATCH 3/7] s390x: fix error propagation in kvm-flic's realize

2017-07-04 Thread Cornelia Huck
On Tue, 4 Jul 2017 17:08:52 +0200 Halil Pasic wrote: > >>> cd.type = KVM_DEV_TYPE_FLIC; > >>> ret = kvm_vm_ioctl(kvm_state, KVM_CREATE_DEVICE, &cd); > >>> if (ret < 0) { > >>> -trace_flic_create_device(errno); > >>> -return; > >>> +error_setg_errno(&errp_loc

[Qemu-devel] [PATCH 2/3] memory.h: Add new utility function memory_region_allocate_aux_memory()

2017-07-04 Thread Peter Maydell
Add a new utility function memory_region_allocate_aux_memory() for board code to use to create auxiliary memory regions (such as display RAM or static RAMs). This parallels the existing memory_region_allocate_system_memory() and wraps up the very common sequence of: memory_region_init_ram(sram,

[Qemu-devel] [PATCH 1/3] include/hw/boards.h: Document memory_region_allocate_system_memory()

2017-07-04 Thread Peter Maydell
Add a documentation comment for memory_region_allocate_system_memory(). In particular, the reason for this function's existence and the requirement on board code to call it exactly once are non-obvious. Signed-off-by: Peter Maydell --- include/hw/boards.h | 28 1 fi

[Qemu-devel] [PATCH 0/3] Add new utility function memory_region_allocate_aux_memory()

2017-07-04 Thread Peter Maydell
Many board models and several devices need to create auxiliary regions of RAM (in addition to the main lump of 'system' memory), to model static RAMs, video memory, ROMs, etc. Currently they do this with a sequence like: memory_region_init_ram(sram, NULL, "sram", 0x1, &error_fatal);

[Qemu-devel] [PATCH 3/3] hw: Use new memory_region_allocate_aux_memory() function

2017-07-04 Thread Peter Maydell
Use the new utility function memory_region_allocate_aux_memory() instead of manually calling memory_region_init_ram() and then vmstate_register_ram_global(). Patch automatically created using the included coccinelle script: spatch --in-place -sp_file scripts/coccinelle/allocate_aux_mem.cocci -dir

Re: [Qemu-devel] [PATCH 3/7] s390x: fix error propagation in kvm-flic's realize

2017-07-04 Thread Christian Borntraeger
On 07/04/2017 06:59 PM, Cornelia Huck wrote: > On Tue, 4 Jul 2017 17:08:52 +0200 > Halil Pasic wrote: > > cd.type = KVM_DEV_TYPE_FLIC; > ret = kvm_vm_ioctl(kvm_state, KVM_CREATE_DEVICE, &cd); > if (ret < 0) { > -trace_flic_create_device(errno); > -

Re: [Qemu-devel] [PATCHv7 5/6] fw_cfg: move qdev_init_nofail() from fw_cfg_init1() to callers

2017-07-04 Thread Mark Cave-Ayland
On 03/07/17 10:39, Igor Mammedov wrote: > On Thu, 29 Jun 2017 15:07:19 +0100 > Mark Cave-Ayland wrote: > >> When looking to instantiate a TYPE_FW_CFG_MEM or TYPE_FW_CFG_IO device to be >> able to wire it up differently, it is much more convenient for the caller to >> instantiate the device and h

Re: [Qemu-devel] [PATCHv7 3/6] fw_cfg: switch fw_cfg_find() to locate the fw_cfg device by type rather than path

2017-07-04 Thread Mark Cave-Ayland
On 03/07/17 10:42, Igor Mammedov wrote: > On Thu, 29 Jun 2017 15:07:17 +0100 > Mark Cave-Ayland wrote: > >> This will enable the fw_cfg device to be placed anywhere within the QOM tree >> regardless of its machine location. >> >> Signed-off-by: Mark Cave-Ayland >> --- >> hw/nvram/fw_cfg.c |

[Qemu-devel] Managing architectural restrictions with -device and libvirt

2017-07-04 Thread Mark Cave-Ayland
Hi all, I've been working on a patchset that brings the sun4u machine on qemu-system-sparc64 much closer to a real Ultra 5, however due to various design restrictions I need to be able to restrict how devices are added to the machine with -device. On a real Ultra 5, the root PCI bus (sabre) has 2

Re: [Qemu-devel] [PATCH 14/22] tcg: add CONFIG_TCG guards in headers

2017-07-04 Thread Richard Henderson
On 07/04/2017 01:12 AM, Paolo Bonzini wrote: From: Yang Zhong Add the CONFIG_TCG for exec-all.h. Since function tlb_set_page_with_attrs() is defined in ./accel/tcg/cputlb.c, which will be disabled if tcg is disabled. This function need be implemented in accel/stubs/tcg-stub.c for disable-tcg. S

Re: [Qemu-devel] [PATCH 16/22] target/i386: move cpu_sync_bndcs_hflags() function

2017-07-04 Thread Richard Henderson
On 07/04/2017 01:12 AM, Paolo Bonzini wrote: From: Yang Zhong Move cpu_sync_bndcs_hflags() function from mpx_helper.c to helper.c because mpx_helper.c need be disabled when tcg is disabled. Signed-off-by: Yang Zhong Signed-off-by: Paolo Bonzini --- v2: moved cpu_report_tpr_access hunk l

Re: [Qemu-devel] [PATCH 18/22] target/i386: split cpu_set_mxcsr() and make cpu_set_fpuc() inline

2017-07-04 Thread Richard Henderson
On 07/04/2017 01:12 AM, Paolo Bonzini wrote: From: Yang Zhong Split the cpu_set_mxcsr() and make cpu_set_fpuc() inline with specific tcg code. Signed-off-by: Yang Zhong Signed-off-by: Paolo Bonzini --- v2: renamed tcg_update_mxcsr [Richard], added missing call to cpu_post_load

Re: [Qemu-devel] [PATCH 20/22] target/i386: add the tcg_enabled() in target/i386/

2017-07-04 Thread Richard Henderson
On 07/04/2017 01:12 AM, Paolo Bonzini wrote: From: Yang Zhong Add the tcg_enabled() where the x86 target needs to disable TCG-specific code. Signed-off-by: Yang Zhong Signed-off-by: Paolo Bonzini --- v2: do not touch bpt_helper.c, adjust caller in machine.c [Richard] Reviewed-by: Rich

[Qemu-devel] [PATCH 2/5] migration: Close file on failed migration load

2017-07-04 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Closing the file before exit on a failure allows the source to cleanup better, especially with RDMA. Partial fix for https://bugs.launchpad.net/qemu/+bug/1545052 Signed-off-by: Dr. David Alan Gilbert --- migration/migration.c | 1 + 1 file changed, 1 insertion(+

[Qemu-devel] [PATCH 1/5] migration/rdma: Fix race on source

2017-07-04 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Fix a race where the destination might try and send the source a WRID_READY before the source has done a post-recv for it. rdma_post_recv has to happen after the qp exists, and we're OK since we've already called qemu_rdma_source_init that calls qemu_alloc_qp. Thi

[Qemu-devel] [PATCH 4/5] migration/rdma: Safely convert control types

2017-07-04 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" control_desc[] is an array of strings that correspond to a series of message types; they're used only for error messages, but if the message type is seriously broken then we could go off the end of the array. Convert the array to a function control_desc() that boun

[Qemu-devel] [PATCH 0/5] A bunch of RDMA fixes

2017-07-04 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Hi, This is a bunch of RDMA fixes, the first is a race I spotted a while ago that you don't hit during normal operation; the rest are to do with migration failure and cancellation that I started looking at because of lp1545052 which is a failure to recover on the

[Qemu-devel] [PATCH 3/5] migration/rdma: Allow cancelling while waiting for wrid

2017-07-04 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" When waiting for a WRID, if the other side dies we end up waiting for ever with no way to cancel the migration. Cure this by poll()ing the fd first with a timeout and checking error flags and migration state. Signed-off-by: Dr. David Alan Gilbert --- migration/rd

[Qemu-devel] [PATCH 5/5] migration/rdma: Send error during cancelling

2017-07-04 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" When we issue a cancel and clean up the RDMA channel send a CONTROL_ERROR to get the destination to quit. The rdma_cleanup code waits for the event to come back from the rdma_disconnect; but that wont happen until the destination quits and there's currently nothing

Re: [Qemu-devel] [PATCH v11 04/29] target: [tcg] Add generic translation framework

2017-07-04 Thread Lluís Vilanova
Richard Henderson writes: > On 06/28/2017 05:32 AM, Lluís Vilanova wrote: >> +void (*init_disas_context)(DisasContextBase *db, CPUState *cpu); >> +void (*init_globals)(DisasContextBase *db, CPUState *cpu); >> +void (*tb_start)(DisasContextBase *db, CPUState *cpu); >> +void (*insn_s

[Qemu-devel] [Bug 1545052] Re: RDMA migration will hang forever if target QEMU fails to load vmstate

2017-07-04 Thread Dr. David Alan Gilbert
Fix series posted upstream: 0001-migration-rdma-Fix-race-on-source.patch 0002-migration-Close-file-on-failed-migration-load.patch 0003-migration-rdma-Allow-cancelling-while-waiting-for-wr.patch 0004-migration-rdma-Safely-convert-control-types.patch 0005-migration-rdma-Send-error-during-cancelling.p

Re: [Qemu-devel] [PATCH v11 04/29] target: [tcg] Add generic translation framework

2017-07-04 Thread Peter Maydell
On 4 July 2017 at 19:59, Lluís Vilanova wrote: > Richard Henderson writes: > >> On 06/28/2017 05:32 AM, Lluís Vilanova wrote: >>> +void (*init_disas_context)(DisasContextBase *db, CPUState *cpu); >>> +void (*init_globals)(DisasContextBase *db, CPUState *cpu); >>> +void (*tb_start)(Disa

<    1   2   3   4   >