Re: [Qemu-devel] [PATCH v2 02/21] sysbus: Set user_creatable=false by default on TYPE_SYS_BUS_DEVICE

2017-04-05 Thread Juergen Gross
On 04/04/17 22:24, Eduardo Habkost wrote: > commit 33cd52b5d7b9adfd009e95f07e6c64dd88ae2a31 unset > cannot_instantiate_with_device_add_yet in TYPE_SYSBUS, making all > sysbus devices appear on "-device help" and lack the "no-user" > flag in "info qdm". > > To fix this, we can set user_creatable=fa

Re: [Qemu-devel] [PATCH v3 02/13] pci: Reduce scope of error injection

2017-04-05 Thread Marcel Apfelbaum
On 04/05/2017 10:47 PM, Eric Blake wrote: No one outside of pcie_aer.h was using error injection; mark them static for internal use. Signed-off-by: Eric Blake --- v3: new patch, suggested by Markus --- include/hw/pci/pcie_aer.h | 4 hw/pci/pcie_aer.c | 4 ++-- 2 files changed, 2

Re: [Qemu-devel] [PATCH v3 01/13] pci: Use struct instead of QDict to pass back parameters

2017-04-05 Thread Marcel Apfelbaum
On 04/05/2017 10:47 PM, Eric Blake wrote: It's simpler to just use a C struct than it is to bundle things into a QDict in one function just to pull them back out in the caller. Plus, doing this gets rid of one more user of dynamic JSON through qobject_from_jsonf(), as well as a memory leak of th

Re: [Qemu-devel] [PATCH 04/21] ppc/pnv: enable only one LPC bus

2017-04-05 Thread David Gibson
On Wed, Apr 05, 2017 at 02:41:29PM +0200, Cédric Le Goater wrote: > Multi chip systems only have one LPC bus, on chip 0. The PnvLPC object > will still be created under the PnvChip objects but only the one under > chip 0 will be advertise in the device tree. > > Also remove the comment which is sl

Re: [Qemu-devel] [PATCH 03/21] ppc/pnv: Add support for POWER8+ LPC Controller

2017-04-05 Thread David Gibson
On Wed, Apr 05, 2017 at 02:41:28PM +0200, Cédric Le Goater wrote: > From: Benjamin Herrenschmidt > > It adds the Naples chip which supports proper LPC interrupts via the > LPC controller rather than via an external CPLD. > > Signed-off-by: Benjamin Herrenschmidt > [clg: - updated for qemu-2.9 >

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-05 Thread 858585 jemmy
On Wed, Apr 5, 2017 at 6:44 PM, 858585 jemmy wrote: > On Wed, Apr 5, 2017 at 5:34 PM, Daniel P. Berrange > wrote: >> On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: >>> From: Lidong Chen >>> >>> when migration with high speed, mig_save_device_bulk invoke >>> bdrv_is_alloc

Re: [Qemu-devel] [Qemu-stable] [PATCH 00/81] Patch Round-up for stable 2.8.1, freeze on 2017-03-27

2017-04-05 Thread Gonglei (Arei)
> > > > > > > > > > > > > > > > > > > > > > > -Original Message- > > > > > > From: Michael Roth [mailto:mdr...@linux.vnet.ibm.com] > > > > > > Sent: Wednesday, April 05, 2017 12:09 PM > > > > > > To: Gonglei (Arei); qemu-devel@nongnu.org > > > > > > Cc: qemu-sta...@nongnu.org > > > > > > S

[Qemu-devel] [PATCH v5] Allow setting NUMA distance for different NUMA nodes

2017-04-05 Thread He Chen
This patch is going to add SLIT table support in QEMU, and provides additional option `dist` for command `-numa` to allow user set vNUMA distance by QEMU command. With this patch, when a user wants to create a guest that contains several vNUMA nodes and also wants to set distance among those nodes

Re: [Qemu-devel] [BUG/RFC] INIT IPI lost when VM starts

2017-04-05 Thread Herongguang (Stephen)
On 2017/4/6 0:16, Paolo Bonzini wrote: On 20/03/2017 15:21, Herongguang (Stephen) wrote: We encountered a problem that when a domain starts, seabios failed to online a vCPU. After investigation, we found that the reason is in kvm-kmod, KVM_APIC_INIT bit in vcpu->arch.apic->pending_events was

Re: [Qemu-devel] [PATCH v4 1/1] block: pass the right options for BlockDriver.bdrv_open()

2017-04-05 Thread Dong Jia Shi
* Max Reitz [2017-04-05 15:54:14 +0200]: > On 05.04.2017 11:19, Dong Jia Shi wrote: > > raw_open() expects the caller always passing in the right actual > > @options parameter. But when trying to applying snapshot on a RBD > > image, bdrv_snapshot_goto() calls raw_open() (by calling the > > bdrv_

Re: [Qemu-devel] [PATCH for-2.10 3/9] block: honor BDRV_O_ALLOW_RDWR when clearing bs->read_only

2017-04-05 Thread Jeff Cody
On Wed, Apr 05, 2017 at 08:20:28PM -0400, Jeff Cody wrote: > On Wed, Apr 05, 2017 at 02:26:53PM -0500, Eric Blake wrote: > > On 04/05/2017 02:20 PM, John Snow wrote: > > > > > Conceptually straightforward. > > > > > > looks like this might change behavior for... RBD and vvfat, right? > > > RBD is

Re: [Qemu-devel] [PATCH for-2.10 6/9] block: use bdrv_try_set_read_only() during reopen

2017-04-05 Thread Jeff Cody
On Wed, Apr 05, 2017 at 04:25:39PM -0400, John Snow wrote: > > > On 04/05/2017 02:28 PM, Jeff Cody wrote: > > Signed-off-by: Jeff Cody > > --- > > block.c | 14 -- > > 1 file changed, 8 insertions(+), 6 deletions(-) > > > > diff --git a/block.c b/block.c > > index ad958b9..3245fae

Re: [Qemu-devel] [PATCH for-2.10 5/9] block: introduce bdrv_try_set_read_only()

2017-04-05 Thread Jeff Cody
On Wed, Apr 05, 2017 at 04:28:44PM -0400, John Snow wrote: > > > On 04/05/2017 02:28 PM, Jeff Cody wrote: > > Introduce try function for setting read_only flags. Will return < 0 on > > error, with appropriate Error value set. Does not alter any flags. > > > > Signed-off-by: Jeff Cody > > ---

Re: [Qemu-devel] [PATCH for-2.10 3/9] block: honor BDRV_O_ALLOW_RDWR when clearing bs->read_only

2017-04-05 Thread Jeff Cody
On Wed, Apr 05, 2017 at 02:26:53PM -0500, Eric Blake wrote: > On 04/05/2017 02:20 PM, John Snow wrote: > > > Conceptually straightforward. > > > > looks like this might change behavior for... RBD and vvfat, right? > > RBD is the subject of this series so we'll just assume that was broken > > and

Re: [Qemu-devel] [PATCH for-2.10 2/9] block: do not set BDS read_only if copy_on_read enabled

2017-04-05 Thread Jeff Cody
On Wed, Apr 05, 2017 at 03:16:38PM -0400, John Snow wrote: > > > On 04/05/2017 02:28 PM, Jeff Cody wrote: > > A few block drivers will set the BDS read_only flag from their > > .bdrv_open() function. This means the bs->read_only flag could > > be set after we enable copy_on_read, as the BDRV_O_C

Re: [Qemu-devel] [PATCH 2/2] block: assert no image modification under BDRV_O_INACTIVE

2017-04-05 Thread Denis V. Lunev
On 04/05/2017 06:37 PM, Eric Blake wrote: > On 04/05/2017 10:18 AM, Denis V. Lunev wrote: >> As long as BDRV_O_INACTIVE is set, the image file is only opened so we >> have a file descriptor for it. We're definitely not supposed to modify >> the image, it's still owned by the migration source. >> >>

[Qemu-devel] [PATCH 3/3] move xen-mapcache.c to hw/i386/xen/

2017-04-05 Thread Anthony Xu
move xen-mapcache.c to hw/i386/xen/ Signed-off -by: Anthony Xu --- Makefile.target | 3 --- default-configs/i386-softmmu.mak | 1 - default-configs/x86_64-softmmu.mak | 1 - hw/i386/xen/Makefile.objs| 2 +- hw/i386/xen/tr

[Qemu-devel] [PATCH 1/3] move xen-common.c to hw/xen/

2017-04-05 Thread Anthony Xu
move xen-common.c to hw/xen/ Signed-off -by: Anthony Xu --- Makefile.target | 2 -- hw/xen/Makefile.objs| 2 +- xen-common.c => hw/xen/xen-common.c | 0 stubs/Makefile.objs | 1 + xen-common-stub.c => stubs/xen-common.c | 0 5

[Qemu-devel] [PATCH 2/3] move xen-hvm.c to hw/i386/xen/

2017-04-05 Thread Anthony Xu
move xen-hvm.c to hw/i386/xen/ Signed-off -by: Anthony Xu --- Makefile.target| 3 +-- hw/i386/xen/Makefile.objs | 2 +- hw/i386/xen/trace-events | 11 +++ xen-hvm.c => hw/i386/xen/xen-hvm.c | 2 +- stubs/Makefile.objs| 1 + x

[Qemu-devel] [PATCH 0/3] move xen related files to corresponding xen directory

2017-04-05 Thread Anthony Xu
move xen related files to corresponding xen directory move xen-common.c to hw/xen/ move xen-hvm.c to hw/i386/xen/ move xen-mapcache.c to hw/i386/xen/ Signed-off -by: Anthony Xu Makefile.target | 6 -- default-configs/i386-softmmu.mak |

Re: [Qemu-devel] [PATCH v6] vfio error recovery: kernel support

2017-04-05 Thread Alex Williamson
On Thu, 6 Apr 2017 01:36:31 +0300 "Michael S. Tsirkin" wrote: > On Wed, Apr 05, 2017 at 04:19:10PM -0600, Alex Williamson wrote: > > On Thu, 6 Apr 2017 00:50:22 +0300 > > "Michael S. Tsirkin" wrote: > > > > > On Wed, Apr 05, 2017 at 01:38:22PM -0600, Alex Williamson wrote: > > > > The previ

[Qemu-devel] Fw: Raspberry PI

2017-04-05 Thread John Bradley via Qemu-devel
 John BradleyTel: 07896 839635Skype: flypie125 125B Grove StreetEdge Hill Liverpool L7 7AF On Wednesday, 5 April 2017, 23:20, John Snow wrote: On 04/03/2017 02:17 PM, John Bradley wrote: > Hi, > > Not sure what I am doing at the moment. > > It is very little of my code, there are va

[Qemu-devel] Emulating external registers

2017-04-05 Thread Wu, Michael Y [US] (MS)
Hi, I've been doing some bare metal programming using the powerpc system emulator. I was able to run some of my code using the g3beige system emulation. I am now currently trying emulate some external registers. Simply a powerpc address will be mapped to a register. My plan is to write a bare m

Re: [Qemu-devel] [PATCH v6] vfio error recovery: kernel support

2017-04-05 Thread Michael S. Tsirkin
On Wed, Apr 05, 2017 at 04:19:10PM -0600, Alex Williamson wrote: > On Thu, 6 Apr 2017 00:50:22 +0300 > "Michael S. Tsirkin" wrote: > > > On Wed, Apr 05, 2017 at 01:38:22PM -0600, Alex Williamson wrote: > > > The previous intention of trying to handle all sorts of AER faults > > > clearly had more

Re: [Qemu-devel] [PATCH 1/3] move xen-common.c to hw/xen/

2017-04-05 Thread Xu, Anthony
Hi Eric, Will resend the patch. Thanks, Anthony > -Original Message- > From: Eric Blake [mailto:ebl...@redhat.com] > Sent: Wednesday, April 5, 2017 11:50 AM > To: Xu, Anthony ; 'qemu-devel@nongnu.org' > > Cc: anthony.per...@citrix.com; 'Paolo Bonzini' ; > sstabell...@kernel.org > Subjec

Re: [Qemu-devel] [PATCH v6] vfio error recovery: kernel support

2017-04-05 Thread Alex Williamson
On Thu, 6 Apr 2017 00:50:22 +0300 "Michael S. Tsirkin" wrote: > On Wed, Apr 05, 2017 at 01:38:22PM -0600, Alex Williamson wrote: > > The previous intention of trying to handle all sorts of AER faults > > clearly had more value, though even there the implementation and > > configuration requiremen

Re: [Qemu-devel] external snapshots freezes block device since qemu 2.8

2017-04-05 Thread John Snow
On 03/09/2017 07:26 AM, Dr. David Alan Gilbert wrote: > * Piotr Rybicki (piotr.rybi...@innervision.pl) wrote: >> Hello there. >> >> I discovered, that since qemu 2.8 , external snapshots (very similar to: >> http://wiki.libvirt.org/page/Live-disk-backup-with-active-blockcommit), >> freezes block

Re: [Qemu-devel] [PATCH v3 02/13] pci: Reduce scope of error injection

2017-04-05 Thread Michael S. Tsirkin
On Wed, Apr 05, 2017 at 02:47:30PM -0500, Eric Blake wrote: > No one outside of pcie_aer.h was using error injection; mark them > static for internal use. > > Signed-off-by: Eric Blake Reviewed-by: Michael S. Tsirkin > --- > v3: new patch, suggested by Markus > --- > include/hw/pci/pcie_aer.

Re: [Qemu-devel] [PATCH v3 01/13] pci: Use struct instead of QDict to pass back parameters

2017-04-05 Thread Michael S. Tsirkin
On Wed, Apr 05, 2017 at 02:47:29PM -0500, Eric Blake wrote: > It's simpler to just use a C struct than it is to bundle things > into a QDict in one function just to pull them back out in the > caller. Plus, doing this gets rid of one more user of dynamic > JSON through qobject_from_jsonf(), as wel

Re: [Qemu-devel] [PATCH v6] vfio error recovery: kernel support

2017-04-05 Thread Michael S. Tsirkin
On Wed, Apr 05, 2017 at 04:54:33PM +0800, Cao jin wrote: > Apparently, I don't have experience to induce non-fatal error, device > error is more of a chance related with the environment(temperature, > humidity, etc) as I understand. I'm not sure how to interpret this statement. I think what Alex i

Re: [Qemu-devel] [PATCH v6] vfio error recovery: kernel support

2017-04-05 Thread Michael S. Tsirkin
On Wed, Apr 05, 2017 at 01:38:22PM -0600, Alex Williamson wrote: > The previous intention of trying to handle all sorts of AER faults > clearly had more value, though even there the implementation and > configuration requirements restricted the practicality. For instance > is AER support actually

Re: [Qemu-devel] [PATCH v2 01/21] qdev: Replace cannot_instantiate_with_device_add_yet with !user_creatable

2017-04-05 Thread Peter Maydell
On 5 April 2017 at 22:25, Eduardo Habkost wrote: > It's true that q35 wouldn't break if it simply used > user_creatable after applying this series. But it will break if > one day we link code that registers a user-creatable non-x86 > device inside the qemu-system-x86_64 binary (even if by > accide

Re: [Qemu-devel] [PATCH v2 01/21] qdev: Replace cannot_instantiate_with_device_add_yet with !user_creatable

2017-04-05 Thread Eduardo Habkost
Forgot to answer this part on my previous message: On Wed, Apr 05, 2017 at 10:01:29PM +0300, Marcel Apfelbaum wrote: [...] > > When it was introduced, we had 54 > > cannot_instantiate_with_device_add_yet=true lines in the code. > > Today (3 years later) this number has not shrinked: we now have >

Re: [Qemu-devel] nbd: Possible regression in 2.9 RCs

2017-04-05 Thread Paolo Bonzini
On 05/04/2017 13:01, Kevin Wolf wrote: > Am 04.04.2017 um 17:09 hat Paolo Bonzini geschrieben: >> On 04/04/2017 16:53, Kevin Wolf wrote: The big question is how this fits into release management. We have another important regression from the op blocker work and only a week to go b

Re: [Qemu-devel] [PATCH v2 02/21] sysbus: Set user_creatable=false by default on TYPE_SYS_BUS_DEVICE

2017-04-05 Thread John Snow
On 04/04/2017 04:24 PM, Eduardo Habkost wrote: > commit 33cd52b5d7b9adfd009e95f07e6c64dd88ae2a31 unset > cannot_instantiate_with_device_add_yet in TYPE_SYSBUS, making all > sysbus devices appear on "-device help" and lack the "no-user" > flag in "info qdm". > > To fix this, we can set user_creat

Re: [Qemu-devel] [PATCH v3 12/13] fdc-test: Avoid deprecated 'change' command

2017-04-05 Thread John Snow
On 04/05/2017 03:47 PM, Eric Blake wrote: > Use the preferred blockdev-change-medium command instead. > > Admittedly, use of 'device' is also deprecated over the newer use > of 'id', but the test is exploiting that the name 'floppy0' is > auto-created by the board, and I could not figure out whe

[Qemu-devel] [PATCH] vfio/pci-quirks: Exclude non-ioport BAR from NVIDIA quirk

2017-04-05 Thread Alex Williamson
The NVIDIA BAR5 quirk is targeting an ioport BAR. Some older devices have a BAR5 which is not ioport and can induce a segfault here. Test the BAR type to skip these devices. Link: https://bugs.launchpad.net/qemu/+bug/1678466 Signed-off-by: Alex Williamson --- hw/vfio/pci-quirks.c |2 +- 1

Re: [Qemu-devel] [PATCH for-2.10 5/9] block: introduce bdrv_try_set_read_only()

2017-04-05 Thread John Snow
On 04/05/2017 02:28 PM, Jeff Cody wrote: > Introduce try function for setting read_only flags. Will return < 0 on > error, with appropriate Error value set. Does not alter any flags. > > Signed-off-by: Jeff Cody > --- > block.c | 14 +- > include/block/block.h | 1

Re: [Qemu-devel] [PATCH for-2.10 6/9] block: use bdrv_try_set_read_only() during reopen

2017-04-05 Thread John Snow
On 04/05/2017 02:28 PM, Jeff Cody wrote: > Signed-off-by: Jeff Cody > --- > block.c | 14 -- > 1 file changed, 8 insertions(+), 6 deletions(-) > > diff --git a/block.c b/block.c > index ad958b9..3245fae 100644 > --- a/block.c > +++ b/block.c > @@ -2785,6 +2785,7 @@ int bdrv_reopen_

Re: [Qemu-devel] [PATCH for-2.10 4/9] block: code movement

2017-04-05 Thread John Snow
On 04/05/2017 02:28 PM, Jeff Cody wrote: > Move bdrv_is_read_only() up with its friends. > > Signed-off-by: Jeff Cody > --- > block.c | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/block.c b/block.c > index 4a61ff0..8bfe7f4 100644 > --- a/block.c > +++ b/b

Re: [Qemu-devel] [PATCH v3 03/13] s390x: Drop useless casts

2017-04-05 Thread Philippe Mathieu-Daudé
On 04/05/2017 04:47 PM, Eric Blake wrote: An upcoming Coccinelle cleanup script wanted to reformat the casts present in this file - but on closer look, we don't need the casts at all because C automatically converts void* to any other pointer. Signed-off-by: Eric Blake Reviewed-by: Philippe M

Re: [Qemu-devel] [PATCH v3 02/13] pci: Reduce scope of error injection

2017-04-05 Thread Philippe Mathieu-Daudé
On 04/05/2017 04:47 PM, Eric Blake wrote: No one outside of pcie_aer.h was using error injection; mark them static for internal use. Signed-off-by: Eric Blake Reviewed-by: Philippe Mathieu-Daudé --- v3: new patch, suggested by Markus --- include/hw/pci/pcie_aer.h | 4 hw/pci/pcie_ae

Re: [Qemu-devel] [PATCH v3 07/13] block: Use simpler QDict/QList scalar insertion macros

2017-04-05 Thread Richard W.M. Jones
On Wed, Apr 05, 2017 at 02:47:35PM -0500, Eric Blake wrote: > We now have macros in place to make it less verbose to add a scalar > to QDict and QList, so use them. > > Patch created mechanically via: > spatch --sp-file scripts/coccinelle/qobject.cocci \ > --macro-file scripts/cocci-macro-fi

[Qemu-devel] [PATCH v3 09/13] qobject: Use simpler QDict/QList scalar insertion macros

2017-04-05 Thread Eric Blake
We now have macros in place to make it less verbose to add a scalar to QDict and QList, so use them. To make this patch smaller to review, a couple of subdirectories were done in earlier patches. Patch created mechanically via: spatch --sp-file scripts/coccinelle/qobject.cocci \ --macro-fil

[Qemu-devel] [PATCH v3 08/13] tests: Use simpler QDict/QList scalar insertion macros

2017-04-05 Thread Eric Blake
We now have macros in place to make it less verbose to add a scalar to QDict and QList, so use them. Patch created mechanically via: spatch --sp-file scripts/coccinelle/qobject.cocci \ --macro-file scripts/cocci-macro-file.h --dir tests --in-place then manually checked that no touch-ups were

[Qemu-devel] [PATCH v3 13/13] test-qga: Actually test 0xff sync bytes

2017-04-05 Thread Eric Blake
Commit 62c39b3 introduced test-qga, and at face value, appears to be testing the 'guest-sync' behavior that is recommended for guests in sending 0xff to QGA to force the parser to reset. But this aspect of the test has never actually done anything: the qmp_fd() call chain converts its string argum

[Qemu-devel] [PATCH v3 10/13] block: Simplify bdrv_append_temp_snapshot() logic

2017-04-05 Thread Eric Blake
Noticed while checking Coccinelle results. Naming a label 'out:' when it is only used on error paths is weird; meanwhile we know that snapshot_options is NULL on success and that QDECREF(NULL) is safe. So merge the two exit paths into one. Signed-off-by: Eric Blake --- block.c | 7 ++- 1 fi

[Qemu-devel] [PATCH v3 12/13] fdc-test: Avoid deprecated 'change' command

2017-04-05 Thread Eric Blake
Use the preferred blockdev-change-medium command instead. Admittedly, use of 'device' is also deprecated over the newer use of 'id', but the test is exploiting that the name 'floppy0' is auto-created by the board, and I could not figure out where the command line lives that would need to be tweake

[Qemu-devel] [PATCH v3 06/13] qobject: Add helper macros for common scalar insertions

2017-04-05 Thread Eric Blake
Rather than making lots of callers wrap a scalar in a QInt, QString, or QBool, provide helper macros that do the wrapping automatically. Update the Coccinelle script to make mass conversions easy, although the conversion itself will be done as a separate patches to ease review and backport efforts

[Qemu-devel] [PATCH v3 05/13] qobject: Drop useless QObject casts

2017-04-05 Thread Eric Blake
We have macros in place to make it less verbose to add a subtype of QObject to both QDict and QList. While we have made cleanups like this in the past (see commit fcfcd8ffc, for example), having it be automated by Coccinelle makes it easier to maintain. Patch created mechanically via: spatch --s

[Qemu-devel] [PATCH v3 01/13] pci: Use struct instead of QDict to pass back parameters

2017-04-05 Thread Eric Blake
It's simpler to just use a C struct than it is to bundle things into a QDict in one function just to pull them back out in the caller. Plus, doing this gets rid of one more user of dynamic JSON through qobject_from_jsonf(), as well as a memory leak of the QDict. While cleaning the code, fix thing

[Qemu-devel] [PATCH v3 11/13] QemuOpts: Simplify qemu_opts_to_qdict()

2017-04-05 Thread Eric Blake
Noticed while investigating Coccinelle cleanups. There is no need for a temporary variable when we can use the new macro to do the same thing with less typing. Signed-off-by: Eric Blake --- util/qemu-option.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/util/qemu-option

[Qemu-devel] [PATCH v3 07/13] block: Use simpler QDict/QList scalar insertion macros

2017-04-05 Thread Eric Blake
We now have macros in place to make it less verbose to add a scalar to QDict and QList, so use them. Patch created mechanically via: spatch --sp-file scripts/coccinelle/qobject.cocci \ --macro-file scripts/cocci-macro-file.h --dir block --in-place then touched up manually to fix a couple of

[Qemu-devel] [PATCH v3 04/13] coccinelle: Add script to remove useless QObject casts

2017-04-05 Thread Eric Blake
We have macros in place to make it less verbose to add a subtype of QObject to both QDict and QList. While we have made cleanups like this in the past (see commit fcfcd8ffc, for example), having it be automated by Coccinelle makes it easier to maintain. The script is separate from the cleanups, fo

[Qemu-devel] [PATCH v3 03/13] s390x: Drop useless casts

2017-04-05 Thread Eric Blake
An upcoming Coccinelle cleanup script wanted to reformat the casts present in this file - but on closer look, we don't need the casts at all because C automatically converts void* to any other pointer. Signed-off-by: Eric Blake --- target/s390x/cpu_models.c | 4 ++-- 1 file changed, 2 insertions

[Qemu-devel] [PATCH v3 02/13] pci: Reduce scope of error injection

2017-04-05 Thread Eric Blake
No one outside of pcie_aer.h was using error injection; mark them static for internal use. Signed-off-by: Eric Blake --- v3: new patch, suggested by Markus --- include/hw/pci/pcie_aer.h | 4 hw/pci/pcie_aer.c | 4 ++-- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/

[Qemu-devel] [PATCH v3 00/13] qapi-related cleanups

2017-04-05 Thread Eric Blake
This is a subset of my earlier post "Rip out dynamic JSON parsing"[1], and then a rebase of that work onto master. It is available here: git fetch git://repo.or.cz/qemu/ericb.git qapi-dynamic-json-v3 the tag name is a bit of a misnomer for the current series, but is historically accurate. Since

Re: [Qemu-devel] [PATCH v2 01/21] qdev: Replace cannot_instantiate_with_device_add_yet with !user_creatable

2017-04-05 Thread Eduardo Habkost
On Wed, Apr 05, 2017 at 10:01:29PM +0300, Marcel Apfelbaum wrote: > On 04/04/2017 11:24 PM, Eduardo Habkost wrote: > > cannot_instantiate_with_device_add_yet was introduced by commit > > 837d37167dc446af8a91189108b363c04609e296 to replace no_user. It > > was supposed to be a temporary measure. > >

Re: [Qemu-devel] [PATCH v6] vfio error recovery: kernel support

2017-04-05 Thread Alex Williamson
On Wed, 5 Apr 2017 16:54:33 +0800 Cao jin wrote: > Sorry for late. Distracted by other problem for a while. > > On 03/31/2017 02:16 AM, Alex Williamson wrote: > > On Thu, 30 Mar 2017 21:00:35 +0300 > > >> > >>> > >>> I also asked in my previous comments to provide examples

Re: [Qemu-devel] [PATCH 3/3] migration/i386: Remove support for pre-0.12 formats

2017-04-05 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Remove support for versions of the CPU state prior to 11 > which is the version used in qemu 0.12 - you'd be pretty > lucky if you got a migration stream to work from anything > that old anyway. This doesn't affect the ma

Re: [Qemu-devel] [PATCH for-2.10 3/9] block: honor BDRV_O_ALLOW_RDWR when clearing bs->read_only

2017-04-05 Thread Eric Blake
On 04/05/2017 02:20 PM, John Snow wrote: > Conceptually straightforward. > > looks like this might change behavior for... RBD and vvfat, right? > RBD is the subject of this series so we'll just assume that was broken > and stupid. > > What's vvfat's story? It always set the read-only property to

Re: [Qemu-devel] [PATCH 2/3] vmstatification: i386 FPReg

2017-04-05 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Convert the fpreg save/restore to use VMSTATE_ macros rather than > .get/.put. > > Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela But if you have to respin > +typedef struct x86_FPReg_tmp { > +FP

Re: [Qemu-devel] [PATCH for-2.10 3/9] block: honor BDRV_O_ALLOW_RDWR when clearing bs->read_only

2017-04-05 Thread John Snow
On 04/05/2017 02:28 PM, Jeff Cody wrote: > The BDRV_O_ALLOW_RDWR flag allows / prohibits the changing of > the BDS 'read_only' state, but there are a few places where it > is ignored. In the bdrv_set_read_only() helper, make sure to > honor the flag. > > Signed-off-by: Jeff Cody > --- > block

Re: [Qemu-devel] [PATCH for-2.10 2/9] block: do not set BDS read_only if copy_on_read enabled

2017-04-05 Thread John Snow
On 04/05/2017 02:28 PM, Jeff Cody wrote: > A few block drivers will set the BDS read_only flag from their > .bdrv_open() function. This means the bs->read_only flag could > be set after we enable copy_on_read, as the BDRV_O_COPY_ON_READ > flag check occurs prior to the call to bdrv->bdrv_open().

Re: [Qemu-devel] [PATCH 1/3] migration/i386: Remove old non-softfloat 64bit FP support

2017-04-05 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Long long ago, we used to support storing the x86 FP registers in > a 64bit format. > > Then c31da136a0bf8caad70c348f5ffc283206e9c7fc in v0.14-rc0 removed > the last support for writing that in the migration format. > Even

Re: [Qemu-devel] host stalls when qemu-system-aarch64 with kvm and pflash

2017-04-05 Thread Radha Mohan
On Fri, Mar 31, 2017 at 4:16 PM, Radha Mohan wrote: > On Thu, Mar 30, 2017 at 9:47 AM, Laszlo Ersek wrote: >> On 03/29/17 20:56, Christoffer Dall wrote: >>> On Tue, Mar 28, 2017 at 01:24:15PM -0700, Radha Mohan wrote: On Tue, Mar 28, 2017 at 1:16 PM, Christoffer Dall wrote: > Hi Radha,

Re: [Qemu-devel] [PATCH 0/3 for 2.10] migration/i386 cleanup

2017-04-05 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Hi, > This removes some qemu_get_ and qemu_put_ use from i386/machine.c > and cleans out some very old code. > It breaks migration compatibility from prior to 0.12 > for i386 and prior to ~0.14 for non-softfloat - it d

Re: [Qemu-devel] [PATCH v2 01/21] qdev: Replace cannot_instantiate_with_device_add_yet with !user_creatable

2017-04-05 Thread Marcel Apfelbaum
On 04/04/2017 11:24 PM, Eduardo Habkost wrote: cannot_instantiate_with_device_add_yet was introduced by commit 837d37167dc446af8a91189108b363c04609e296 to replace no_user. It was supposed to be a temporary measure. Hi Eduardo, When it was introduced, we had 54 cannot_instantiate_with_device

[Qemu-devel] [PATCH 3/3] migration/i386: Remove support for pre-0.12 formats

2017-04-05 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Remove support for versions of the CPU state prior to 11 which is the version used in qemu 0.12 - you'd be pretty lucky if you got a migration stream to work from anything that old anyway. This doesn't affect the machine type definition in any way. My main reason

[Qemu-devel] [Bug 1678466] Re: using x-vga=on with vfio-pci leads to segfault

2017-04-05 Thread sh-dvl
after applying the patch no segfault occures any more. thanks for quick fix. regarding my assumption the missing I/O may depend on bios/slot or similar: it doesn't. the card does not show the entry in either slot or even as only extra-card. -- You received this bug notification because you a

[Qemu-devel] [PATCH 1/3] migration/i386: Remove old non-softfloat 64bit FP support

2017-04-05 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Long long ago, we used to support storing the x86 FP registers in a 64bit format. Then c31da136a0bf8caad70c348f5ffc283206e9c7fc in v0.14-rc0 removed the last support for writing that in the migration format. Even before that, it was only used if you had softfloat d

[Qemu-devel] [PATCH 2/3] vmstatification: i386 FPReg

2017-04-05 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Convert the fpreg save/restore to use VMSTATE_ macros rather than .get/.put. Signed-off-by: Dr. David Alan Gilbert --- target/i386/machine.c | 52 +-- 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/

[Qemu-devel] [PATCH 0/3 for 2.10] migration/i386 cleanup

2017-04-05 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Hi, This removes some qemu_get_ and qemu_put_ use from i386/machine.c and cleans out some very old code. It breaks migration compatibility from prior to 0.12 for i386 and prior to ~0.14 for non-softfloat - it doesn't alter the machine type, it just removes some

Re: [Qemu-devel] [PATCH 1/3] move xen-common.c to hw/xen/

2017-04-05 Thread Eric Blake
On 04/05/2017 01:39 PM, Xu, Anthony wrote: > move xen-common.c to hw/xen/ > Your message failed to set the 'In-Reply-To:' header, and was therefore not threaded to your 0/3 cover letter. Please see if you can fix that before posting your next series. > > Signed-off -by: Anthony Xu > > > >

[Qemu-devel] [PATCH 3/3] move xen-mapcache.c to hw/i386/xen/

2017-04-05 Thread Xu, Anthony
move xen-mapcache.c to hw/i386/xen/ Signed-off -by: Anthony Xu --- Makefile.target| 3 - default-configs/i386-softmmu.mak | 1 - default-configs/x86_64-softmmu.mak | 1 - hw/i386/xen/Makefile.objs | 2 +- hw/i386/xen/trace-events | 6 + hw/i3

[Qemu-devel] [PATCH 1/3] move xen-common.c to hw/xen/

2017-04-05 Thread Xu, Anthony
move xen-common.c to hw/xen/ Signed-off -by: Anthony Xu --- hw/xen/xen-common.c | 158 stubs/xen-common.c | 14 + xen-common-stub.c | 14 - xen-common.c| 158 4 file

[Qemu-devel] [PATCH 2/3] move xen-hvm.c to hw/i386/xen/

2017-04-05 Thread Xu, Anthony
move xen-hvm.c to hw/i386/xen/ Signed-off -by: Anthony Xu --- Makefile.target |5 +- hw/i386/xen/Makefile.objs |2 +- hw/i386/xen/trace-events | 11 + hw/i386/xen/xen-hvm.c | 1422 + hw/xen/Makefile.objs |2 +- stub

[Qemu-devel] [PATCH 0/3] move xen related files to corresponding xen directory

2017-04-05 Thread Xu, Anthony
move xen related files to corresponding xen directory. move xen-common.c to hw/xen/ move xen-hvm.c to hw/i386/xen/ move xen-mapcache.c to hw/i386/xen/ Signed-off -by: Anthony Xu Makefile.target|6 - default-configs/i386-softmmu.mak |1 - default-configs/x86_64-s

[Qemu-devel] [PATCH for-2.10 9/9] block/rbd: Add support for reopen()

2017-04-05 Thread Jeff Cody
This adds support for reopen in rbd, for changing between r/w and r/o. Note, that this is only a flag change, but we will block a change from r/o to r/w if we are using an RBD internal snapshot. Signed-off-by: Jeff Cody --- block/rbd.c | 21 + 1 file changed, 21 insertions(+

[Qemu-devel] [PATCH for-2.10 8/9] block/rbd: do not blindly set bs->read_only

2017-04-05 Thread Jeff Cody
We do not want to just blindly set bs->read_only. The only time we need to set it with the current rbd driver, is if we are using an rbd snapshot. In that case, we must set it to read-only. Signed-off-by: Jeff Cody --- block/rbd.c | 13 + 1 file changed, 9 insertions(+), 4 deletion

[Qemu-devel] [PATCH for-2.10 5/9] block: introduce bdrv_try_set_read_only()

2017-04-05 Thread Jeff Cody
Introduce try function for setting read_only flags. Will return < 0 on error, with appropriate Error value set. Does not alter any flags. Signed-off-by: Jeff Cody --- block.c | 14 +- include/block/block.h | 1 + 2 files changed, 14 insertions(+), 1 deletion(-) diff

[Qemu-devel] [PATCH for-2.10 4/9] block: code movement

2017-04-05 Thread Jeff Cody
Move bdrv_is_read_only() up with its friends. Signed-off-by: Jeff Cody --- block.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/block.c b/block.c index 4a61ff0..8bfe7f4 100644 --- a/block.c +++ b/block.c @@ -192,6 +192,11 @@ void path_combine(char *dest, int des

[Qemu-devel] [PATCH for-2.10 7/9] block/rbd - update variable names to more apt names

2017-04-05 Thread Jeff Cody
Update 'clientname' to be 'user', which tracks better with both the QAPI and rados viarable naming. Update 'name' to be 'image_name', as it indicates the rbd image. Naming it 'image' would have been ideal, but we are using that for the rados_image_t value returned by rbd_open(). Signed-off-by: Je

[Qemu-devel] [PATCH for-2.10 3/9] block: honor BDRV_O_ALLOW_RDWR when clearing bs->read_only

2017-04-05 Thread Jeff Cody
The BDRV_O_ALLOW_RDWR flag allows / prohibits the changing of the BDS 'read_only' state, but there are a few places where it is ignored. In the bdrv_set_read_only() helper, make sure to honor the flag. Signed-off-by: Jeff Cody --- block.c | 7 +++ 1 file changed, 7 insertions(+) diff --git

[Qemu-devel] [PATCH for-2.10 2/9] block: do not set BDS read_only if copy_on_read enabled

2017-04-05 Thread Jeff Cody
A few block drivers will set the BDS read_only flag from their .bdrv_open() function. This means the bs->read_only flag could be set after we enable copy_on_read, as the BDRV_O_COPY_ON_READ flag check occurs prior to the call to bdrv->bdrv_open(). This adds an error return to bdrv_set_read_only()

[Qemu-devel] [PATCH for-2.10 1/9] block: add bdrv_set_read_only() helper function

2017-04-05 Thread Jeff Cody
We have a helper wrapper for checking for the BDS read_only flag, add a helper wrapper to set the read_only flag as well. Signed-off-by: Jeff Cody --- block.c | 5 + block/bochs.c | 2 +- block/cloop.c | 2 +- block/dmg.c | 2 +- block/rbd.c

[Qemu-devel] [PATCH for-2.10 6/9] block: use bdrv_try_set_read_only() during reopen

2017-04-05 Thread Jeff Cody
Signed-off-by: Jeff Cody --- block.c | 14 -- 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/block.c b/block.c index ad958b9..3245fae 100644 --- a/block.c +++ b/block.c @@ -2785,6 +2785,7 @@ int bdrv_reopen_prepare(BDRVReopenState *reopen_state, BlockReopenQueue *queue

[Qemu-devel] [PATCH for-2.10 0/9] RBD reopen, read_only cleanup

2017-04-05 Thread Jeff Cody
This series does two things: 1.) Cleans up some of the logic behind setting the read_only flag for a BDS in the block layer, so that it is done consistently (and rules are applied consistently), and 2.) Adds .bdrv_reopen_prepare() implementation for RBD, so that block jobs can be run

Re: [Qemu-devel] [PATCH 0/7] Provide support for the software TPM emulator

2017-04-05 Thread Stefan Berger
On 04/05/2017 01:49 PM, Marc-André Lureau wrote: Hi On Wed, Apr 5, 2017 at 7:32 PM Stefan Berger mailto:stef...@linux.vnet.ibm.com>> wrote: On 04/05/2017 11:08 AM, Marc-André Lureau wrote: > Hi > > On Wed, Apr 5, 2017 at 5:04 PM Stefan Berger mailto:stef...@linux.vnet.ibm.

Re: [Qemu-devel] [PATCH 0/7] Provide support for the software TPM emulator

2017-04-05 Thread Marc-André Lureau
Hi On Wed, Apr 5, 2017 at 7:32 PM Stefan Berger wrote: > On 04/05/2017 11:08 AM, Marc-André Lureau wrote: > > Hi > > > > On Wed, Apr 5, 2017 at 5:04 PM Stefan Berger > > > wrote: > > > >> On 04/05/2017 03:09 AM, Amarnath Valluri wrote: > >>> > >>> On 03.04.2017 20 <03%2004%2020%2017%2020> > <03

Re: [Qemu-devel] [PATCH v2] qga-win: Fix a bug where qemu-ga service is stuck during stop operation

2017-04-05 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Subject: [Qemu-devel] [PATCH v2] qga-win: Fix a bug where qemu-ga service is stuck during stop operation Message-id: 20170405104627.18140-1-sam...@daynix.com Type: series === TEST SCRIPT BEGIN === #

Re: [Qemu-devel] [PATCH 17/21] virtio-channel: parse qga stream for VMDUMP_INFO event

2017-04-05 Thread Daniel P. Berrange
On Wed, Apr 05, 2017 at 12:06:56PM -0500, Eric Blake wrote: > On 04/05/2017 11:12 AM, Daniel P. Berrange wrote: > > On Sat, Mar 11, 2017 at 05:22:52PM +0400, Marc-André Lureau wrote: > >> On virtio channel "org.qemu.guest_agent.0", parse the json stream until > >> the VMDUMP_INFO is received and re

Re: [Qemu-devel] [PATCH 0/7] Provide support for the software TPM emulator

2017-04-05 Thread Stefan Berger
On 04/05/2017 11:08 AM, Marc-André Lureau wrote: Hi On Wed, Apr 5, 2017 at 5:04 PM Stefan Berger wrote: On 04/05/2017 03:09 AM, Amarnath Valluri wrote: On 03.04.2017 20 <03%2004%2020%2017%2020>:07, Daniel P. Berrange wrote: On Fri, Mar 31, 2017 at 04:10:09PM +0300, Amarnath Valluri wrote:

Re: [Qemu-devel] [PATCH 17/21] virtio-channel: parse qga stream for VMDUMP_INFO event

2017-04-05 Thread Eric Blake
On 04/05/2017 11:12 AM, Daniel P. Berrange wrote: > On Sat, Mar 11, 2017 at 05:22:52PM +0400, Marc-André Lureau wrote: >> On virtio channel "org.qemu.guest_agent.0", parse the json stream until >> the VMDUMP_INFO is received and retrieve the dump details. >> > > so we just continually feed data i

Re: [Qemu-devel] [PATCH 17/21] virtio-channel: parse qga stream for VMDUMP_INFO event

2017-04-05 Thread Marc-André Lureau
Hi Le 5 avr. 2017 18:13, "Daniel P. Berrange" a écrit : On Sat, Mar 11, 2017 at 05:22:52PM +0400, Marc-André Lureau wrote: > On virtio channel "org.qemu.guest_agent.0", parse the json stream until > the VMDUMP_INFO is received and retrieve the dump details. > > Signed-off-by: Marc-André Lureau

Re: [Qemu-devel] MTD timeout on bootup

2017-04-05 Thread James Hanley
Thanks Alistair. Regarding the issue - when I tried to use any of the pre-built images off of http://www.wiki.xilinx.com/Zynq+Releases none would detect the MTD device in QEMU - they all had a timeout error. Single-stepping through QEMU with GDB as it booted up any of the kernels from Xilinx, I co

Re: [Qemu-devel] [BUG/RFC] INIT IPI lost when VM starts

2017-04-05 Thread Paolo Bonzini
On 20/03/2017 15:21, Herongguang (Stephen) wrote: > > We encountered a problem that when a domain starts, seabios failed to > online a vCPU. > > After investigation, we found that the reason is in kvm-kmod, > KVM_APIC_INIT bit in > vcpu->arch.apic->pending_events was overwritten by qemu, and th

Re: [Qemu-devel] [PATCH 17/21] virtio-channel: parse qga stream for VMDUMP_INFO event

2017-04-05 Thread Daniel P. Berrange
On Sat, Mar 11, 2017 at 05:22:52PM +0400, Marc-André Lureau wrote: > On virtio channel "org.qemu.guest_agent.0", parse the json stream until > the VMDUMP_INFO is received and retrieve the dump details. > > Signed-off-by: Marc-André Lureau > --- > include/sysemu/dump-info.h | 15 + >

[Qemu-devel] [Bug 1679126] Re: null pointer access on migration resume of systemrescuecd boot menu with qxl-vga

2017-04-05 Thread elmarco
Interesting, the culprit is: commit cd958edb1fae85d0c7d1e1acbff82d22724e8d64 Author: Marc-André Lureau Date: Fri Aug 26 13:47:11 2016 +0400 console: skip same-size resize virtio-gpu does a set-scanout at each frame (it might be a driver regression). qemu_console_resize() recre

Re: [Qemu-devel] qemu-2.9 crashes in tcg_handle_interrupt() during winx64 boot

2017-04-05 Thread Igor Mammedov
On Wed, 05 Apr 2017 14:26:35 +0100 Alex Bennée wrote: > Igor Mammedov writes: > > > On Fri, 31 Mar 2017 09:58:49 +0100 > > Alex Bennée wrote: > > > >> Igor Mammedov writes: > >> > >> > On Thu, 30 Mar 2017 16:05:58 +0100 > >> > Alex Bennée wrote: > >> > > >> >> Igor Mammedov writes: >

  1   2   3   >