[Qemu-devel] guest host time synchronization

2017-04-11 Thread Jiahuan Zhang
Dear QEMU developers, I made a test to check the time difference of QEMU emulated ARM-based Linux guest and the Windows host. The result is, the guest time is around 0.2 second faster than the host. I used the "-rtc base" option. So can I say that, the time precision of QEMU emulation is in secon

[Qemu-devel] [PULL for-2.9 0/2] qxl bugfixes

2017-04-11 Thread Gerd Hoffmann
7-04-07 10:29:56 +0100) are available in the git repository at: git://git.kraxel.org/qemu tags/pull-fixes-20170411-1 for you to fetch changes up to 86dbcdd9c7590d06db89ca256c5eaf0b4aba8858: qxl: add migration blocker to avoid pre-save assert (2017-04-11 08:38

[Qemu-devel] [PULL 1/2] qxl: switch display on entering VGA

2017-04-11 Thread Gerd Hoffmann
From: Marc-André Lureau Since commit cd958edb1fae85d, same size console resize is skipped. This change broke QXL incoming migration in VGA mode, qemu_spice_display_switch() is no longer called during qxl_post_load(), because default message surface is of the same size, and during displaychangelis

[Qemu-devel] [PULL 2/2] qxl: add migration blocker to avoid pre-save assert

2017-04-11 Thread Gerd Hoffmann
Cc: 1635...@bugs.launchpad.net Signed-off-by: Gerd Hoffmann Reviewed-by: Marc-André Lureau Message-id: 20170410113131.2585-1-kra...@redhat.com --- hw/display/qxl.h | 1 + hw/display/qxl.c | 31 +++ 2 files changed, 32 insertions(+) diff --git a/hw/display/qxl.h b/hw

Re: [Qemu-devel] [PATCH v2 2/8] ppc/pnv: enable only one LPC bus

2017-04-11 Thread Cédric Le Goater
On 04/11/2017 04:40 AM, David Gibson wrote: > On Mon, Apr 10, 2017 at 03:56:52PM +0200, Cédric Le Goater wrote: >> The firmware (skiboot) chooses the default LPC bus of a multichip >> systems using a "primary" property. The LPC bus of chip 0 should be >> the only connected in the system. Let's adve

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

2017-04-11 Thread Sameeh Jubran
After triggering a freeze command without any following thaw command, qemu-ga will not respond to stop operation. This behaviour is wanted on Linux as there is no time limit for a freeze command and we want to prevent quitting in the middle of freeze, on the other hand on Windows the time limit for

Re: [Qemu-devel] First contribution - Interested in Outreachy

2017-04-11 Thread Kevin Wolf
Hi Prerna, Am 10.04.2017 um 21:59 hat Prerna Garg geschrieben: > The previous patch was incorrect. Sorry for the inconvenience. Please consider > this as my first contribution. Please read this wiki page about how to submit patches to QEMU: http://wiki.qemu-project.org/Contribute/SubmitAPat

[Qemu-devel] [Bug 1681439] Re: qemu-system-x86_64: hw/ide/core.c:685: ide_cancel_dma_sync: Assertion `s->bus->dma->aiocb == NULL' failed.

2017-04-11 Thread Michał Kępień via Qemu-devel
> I don't think the assert you are talking about in the subject is added > by 9972354856. That assertion was added by 86698a12f and has been > present since QEMU 2.6. I don't see the relation immediately to > AioContext patches. You are right, of course. Sorry for misleading you about this. What

Re: [Qemu-devel] KVM call for 2017-04-11

2017-04-11 Thread Juan Quintela
Juan Quintela wrote: Hi As there is no agenda, the call for this week gets cancelled. Happy hacking. > Hi > > Please, send any topic that you are interested in covering. > > At the end of Monday I will send an email with the agenda or the > cancellation of the call, so hurry up. > > After dis

[Qemu-devel] KVM call for agenda for 2017-04-25

2017-04-11 Thread Juan Quintela
Hi Please, send any topic that you are interested in covering. At the end of Monday I will send an email with the agenda or the cancellation of the call, so hurry up. After discussions on the QEMU Summit, we are going to have always open a KVM call where you can add topics. Call details: By

[Qemu-devel] [Bug 1681688] [NEW] qemu live migration failed

2017-04-11 Thread Lidong Chen
Public bug reported: qemu live migration failed the dest qemu report this error. Receiving block device images Completed 0 %^Mqemu-system-x86_64: block/io.c:1348: bdrv_aligned_pwritev: Assertion `child->perm & BLK_PERM_WRITE' failed. this bug is caused by this patch: http://git.qemu-project.or

Re: [Qemu-devel] [RFC PATCH 2/4] nvdimm: add functions to initialize and perform flush on back store

2017-04-11 Thread Haozhong Zhang
On 04/06/17 19:52 +0800, Xiao Guangrong wrote: > > > On 03/31/2017 04:41 PM, Haozhong Zhang wrote: > > fsync() is used to persist modifications to the back store. If the > > host NVDIMM is used as the back store, fsync() on Linux will trigger > > the write to the host flush hint address. > > > >

Re: [Qemu-devel] [RFC PATCH 2/4] nvdimm: add functions to initialize and perform flush on back store

2017-04-11 Thread Haozhong Zhang
On 04/11/17 16:22 +0800, Haozhong Zhang wrote: > On 04/06/17 19:52 +0800, Xiao Guangrong wrote: > > > > > > On 03/31/2017 04:41 PM, Haozhong Zhang wrote: > > > fsync() is used to persist modifications to the back store. If the > > > host NVDIMM is used as the back store, fsync() on Linux will tri

[Qemu-devel] [Bug 1681688] Re: qemu live migration failed

2017-04-11 Thread Lidong Chen
blk->root->perm is 1 when blk_new_open. the blk->root->perm is update to 3 during virtio_blk_device_realize. but after this commit, the blk->root->perm is still 1. and cause bdrv_aligned_pwritev failed. Breakpoint 1, blk_set_perm (blk=0x14c32b0, perm=3, shared_perm=29, errp=0x7fffd380) at b

Re: [Qemu-devel] [RFC PATCH qemu v3 1/4] memory/iommu: QOM'fy IOMMU MemoryRegion

2017-04-11 Thread Alexey Kardashevskiy
On 03/04/17 22:53, Philippe Mathieu-Daudé wrote: > On 04/01/2017 09:37 AM, Alexey Kardashevskiy wrote: >> This defines new QOM object - IOMMUMemoryRegion - with MemoryRegion >> as a parent. >> >> This moves IOMMU-related fields from MR to IOMMU MR. However to avoid >> dymanic QOM casting in fast pa

Re: [Qemu-devel] [RFC PATCH 0/4] nvdimm: enable flush hint address structure

2017-04-11 Thread Haozhong Zhang
On 04/06/17 20:02 +0800, Xiao Guangrong wrote: > > > On 04/06/2017 05:43 PM, Stefan Hajnoczi wrote: > > On Fri, Mar 31, 2017 at 04:41:43PM +0800, Haozhong Zhang wrote: > > > This patch series constructs the flush hint address structures for > > > nvdimm devices in QEMU. > > > > > > It's of cours

Re: [Qemu-devel] [PATCH v2 4/6] fdc-test: Avoid deprecated 'change' command

2017-04-11 Thread Markus Armbruster
Eric Blake writes: > On 01/19/2017 08:39 AM, Eric Blake wrote: >> On 01/19/2017 03:30 AM, Markus Armbruster wrote: >>> Eric Blake writes: >>> Use the preferred blockdev-change-medium command instead. Signed-off-by: Eric Blake Reviewed-by: John Snow --- tests/fdc-

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

2017-04-11 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] [RFC PATCH 1/4] pc-dimm: add 'reserved-size' to reserve address range after the ending address

2017-04-11 Thread Haozhong Zhang
On 04/07/17 14:46 +0100, Stefan Hajnoczi wrote: > On Thu, Apr 06, 2017 at 06:46:49PM +0800, Haozhong Zhang wrote: > > On 04/06/17 11:24 +0100, Stefan Hajnoczi wrote: > > > On Fri, Mar 31, 2017 at 04:41:44PM +0800, Haozhong Zhang wrote: > > > > If option 'reserved-size=RSVD' is present, QEMU will re

Re: [Qemu-devel] [RFC QEMU PATCH v2 10/10] qapi: extend 'query-memory-devices' to list devices of specified type

2017-04-11 Thread Markus Armbruster
Haozhong Zhang writes: > Add an optional argument 'devtype' to 'query-memory-devices', which > is either 'dimm' or 'nvdimm'. If 'devtype' is missed or 'dimm', all > memory devices will be listed. If 'devtype' is 'nvdimm', only nvdimm > devices will be listed. Basically, the argument provides lim

Re: [Qemu-devel] [PATCH 03/10] blockjob: introduce block_job_fail

2017-04-11 Thread Paolo Bonzini
On 10/04/2017 17:22, Stefan Hajnoczi wrote: >> >> Later on, block_job_fail will also have different locking than >> block_job_unref. > block_job_fail() sounds like it's *the* job failure API. > How about block_job_fail_early()? > > It indicates the API is only for the beginning of the job's life

Re: [Qemu-devel] [PATCH v2 4/6] fdc-test: Avoid deprecated 'change' command

2017-04-11 Thread Kevin Wolf
Am 11.04.2017 um 10:49 hat Markus Armbruster geschrieben: > Eric Blake writes: > > > On 01/19/2017 08:39 AM, Eric Blake wrote: > >> On 01/19/2017 03:30 AM, Markus Armbruster wrote: > >>> Eric Blake writes: > >>> > Use the preferred blockdev-change-medium command instead. > > Signe

Re: [Qemu-devel] [PATCH 09/10] blockjob: reorganize block_job_completed_txn_abort

2017-04-11 Thread Paolo Bonzini
On 11/04/2017 03:17, John Snow wrote: > One thing that I wonder about a little is the push-down of whether or > not to reset iostatus falling to block_job_cancel_async; it seemed to me > as if txn_abort really had the best knowledge as to whether or not we > wanted to reset iostatus, but as it st

Re: [Qemu-devel] [PATCH v3 1/1] qga: Add 'guest-get-users' command

2017-04-11 Thread Vinzenz Feenstra
PING > On Apr 4, 2017, at 7:51 AM, Vinzenz 'evilissimo' Feenstra > wrote: > > From: Vinzenz Feenstra > > A command that will list all currently logged in users, and the time > since when they are logged in. > > Examples: > > virsh # qemu-agent-command F25 '{ "execute": "guest-get-users" }' >

Re: [Qemu-devel] [PATCH for 2.9 v3 01/10] block: Make bdrv_parent_drained_begin/end public

2017-04-11 Thread Kevin Wolf
Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf

Re: [Qemu-devel] [PATCH for 2.9 v3 02/10] block: Quiesce old aio context during bdrv_set_aio_context

2017-04-11 Thread Kevin Wolf
Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > The fact that the bs->aio_context is changing can confuse the dataplane > iothread, because of the now fine granularity aio context lock. > bdrv_drain should rather be a bdrv_drained_begin/end pair, but since > bs->aio_context is changing, we can

Re: [Qemu-devel] [PULL] 9pfs fix for 2.9 2017-04-10

2017-04-11 Thread Peter Maydell
On 10 April 2017 at 15:21, Greg Kurz wrote: > The following changes since commit 5daf9b3025baef10ee7b77daa003d5696b58d5dc: > > Merge remote-tracking branch 'remotes/kevin/tags/for-upstream' into staging > (2017-04-07 15:23:48 +0100) > > are available in the git repository at: > > https://gith

Re: [Qemu-devel] [PATCH for 2.9 v3 03/10] tests/block-job-txn: Don't start block job before adding to txn

2017-04-11 Thread Kevin Wolf
Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > Previously, before test_block_job_start returns, the job can already > complete, as a result, the transactional state of other jobs added to > the same txn later cannot be handled correctly. > > Move the block_job_start() calls to callers after >

Re: [Qemu-devel] quick question about live VM migration

2017-04-11 Thread Daniel P. Berrange
On Mon, Apr 10, 2017 at 01:07:14PM -0700, Vinod Chegu wrote: > Hello, > > A very basic question... > > In a vanilla KVM env. (i.e. non open stack etc) when a VM is live migrated > to another host does the MAC address of the vNICs and the DHCP IP address > for these interfaces remain the same ?

Re: [Qemu-devel] [PATCH v1 3/5] cadence_gem: Only trigger interrupts if the status register is set

2017-04-11 Thread Peter Maydell
On 10 April 2017 at 23:23, Alistair Francis wrote: > On Mon, Apr 10, 2017 at 5:44 AM, Peter Maydell > wrote: >> Also the comment says "raise or lower interrupt based on current >> status", but the code will only ever do qemu_set_irq(..., 1), >> never 0. Which is right? > > This is a little confu

Re: [Qemu-devel] [PATCH v4 00/11] basic channel IO passthrough infrastructure based on vfio

2017-04-11 Thread Cornelia Huck
On Fri, 17 Mar 2017 04:19:17 +0100 Dong Jia Shi wrote: > The patch series introduce a basic channel I/O passthrough > infrastructure based on vfio. I think this is basically ready for 2.10, once the kernel changes hit master (they are queued in the s390 tree). (...) > default-configs/s390x-so

Re: [Qemu-devel] [PATCH v5] qga: Add `guest-get-timezone` command

2017-04-11 Thread Vinzenz Feenstra
PING? > On Apr 4, 2017, at 11:42 AM, Sameeh Jubran wrote: > > I have tested the patch on Windows 2012 R2 > > Reviewed-by: Sameeh Jubran mailto:sam...@daynix.com>> > Tested-by: Sameeh Jubran mailto:sam...@daynix.com>> > > On Thu, Mar 23, 2017 at 2:39 PM, Vinzenz 'evilissimo' Feenstra > mailto

Re: [Qemu-devel] [PATCH v2 1/3] libqtest: Ignore QMP events when parsing the response for HMP commands

2017-04-11 Thread Markus Armbruster
John Snow writes: > On 04/04/2017 03:31 AM, Thomas Huth wrote: >> On 03.04.2017 21:09, John Snow wrote: >>> >>> >>> On 03/30/2017 03:50 AM, Thomas Huth wrote: When running certain HMP commands (like "device_del") via QMP, we can sometimes get a QMP event in the response first, so that t

Re: [Qemu-devel] [PATCH 05/10] blockjob: separate monitor and blockjob APIs

2017-04-11 Thread Paolo Bonzini
On 11/04/2017 00:05, John Snow wrote: > > > On 04/08/2017 05:52 AM, Paolo Bonzini wrote: >> >> >> On 08/04/2017 08:03, John Snow wrote: >>> Looks clean, though it may be useful to do a few more things; >>> >>> - Demarcate what you think is the monitor API in this file >> >> It's already there:

Re: [Qemu-devel] [PATCH 4/4] pam: setup pc.bios

2017-04-11 Thread Paolo Bonzini
On 11/04/2017 09:42, Xu, Anthony wrote: >> I think this is wrong, the high copy should remain read-only or pflash >> stops working when you remove PAM. > > I tried to set pc.bios as read-only and isa.bios as read&write, > it doesn't work. render_memory_region doesn't honor readonly > field of al

Re: [Qemu-devel] [PATCH for 2.9 v3 10/10] block: Fix bdrv_co_flush early return

2017-04-11 Thread Paolo Bonzini
On 10/04/2017 23:05, Fam Zheng wrote: > bdrv_inc_in_flight and bdrv_dec_in_flight are mandatory for > BDRV_POLL_WHILE to work, even for the shortcut case where flush is > unnecessary. Move the if block to below bdrv_dec_in_flight, and BTW fix > the variable declaration position. > > Signed-off-b

Re: [Qemu-devel] [PATCH for-2.10 0/5] x86/vIOMMU: move init back to machine init phase

2017-04-11 Thread Markus Armbruster
Peter Xu writes: > On Fri, Mar 31, 2017 at 07:17:34PM +0300, Michael S. Tsirkin wrote: >> On Fri, Mar 31, 2017 at 03:36:28PM +0800, Peter Xu wrote: >> > At the very beginning, the x86 vIOMMUs are created via "-M iommu=on". >> > We moved one step further a year ago to have the vIOMMUs just like a

Re: [Qemu-devel] [PATCH for 2.9 v3 05/10] async: Introduce aio_co_enter and aio_co_enter_if_inactive

2017-04-11 Thread Kevin Wolf
Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > They start the coroutine on the specified context. > > Signed-off-by: Fam Zheng > --- > include/block/aio.h | 18 ++ > util/async.c| 14 +- > 2 files changed, 31 insertions(+), 1 deletion(-) > > diff --git a

Re: [Qemu-devel] [PATCH v2 1/1] qga: Add 'guest-get-host-name' command

2017-04-11 Thread Vinzenz Feenstra
Ping > On Apr 4, 2017, at 8:46 AM, Vinzenz 'evilissimo' Feenstra > wrote: > > From: Vinzenz Feenstra > > Retrieving the guest host name is a very useful feature for virtual management > systems. This information can help to have more user friendly VM access > details, instead of an IP there w

Re: [Qemu-devel] [PATCH v4 00/11] basic channel IO passthrough infrastructure based on vfio

2017-04-11 Thread Dong Jia Shi
* Cornelia Huck [2017-04-11 11:06:58 +0200]: > On Fri, 17 Mar 2017 04:19:17 +0100 > Dong Jia Shi wrote: > > > The patch series introduce a basic channel I/O passthrough > > infrastructure based on vfio. > > I think this is basically ready for 2.10, once the kernel changes hit > master (they ar

Re: [Qemu-devel] [Qemu-block] Making QMP 'block-job-cancel' transactionable

2017-04-11 Thread Markus Armbruster
Eric Blake writes: > On 04/04/2017 08:28 AM, Kashyap Chamarthy wrote: > >>> Minor or not, it is a useful viewpoint. Either way, as long as the new >>> way of getting a transactional non-pivot successful completion is >>> something that libvirt can learn via introspection, >> >> Can you elaborat

[Qemu-devel] [PATCH] simpletrace: document Analyzer method signatures

2017-04-11 Thread Stefan Hajnoczi
Users can inherit from the simpletrace.Analyzer class and receive callbacks when events of interest occur in a trace file. The method signature is a little magic because the timestamp and pid arguments are optional. Document this. Signed-off-by: Stefan Hajnoczi --- scripts/simpletrace.py | 23

Re: [Qemu-devel] [PATCH for 2.9 v3 09/10] block: Use bdrv_coroutine_enter to start I/O coroutines

2017-04-11 Thread Kevin Wolf
Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > BDRV_POLL_WHILE waits for the started I/O by releasing bs's ctx then polling > the main context, which relies on the yielded the coroutine would continue on > bs->ctx and notify qemu_aio_context with bdrv_wakeup(). Thus, using > qemu_coroutine_ent

Re: [Qemu-devel] [PATCH for-2.10 0/5] x86/vIOMMU: move init back to machine init phase

2017-04-11 Thread Peter Xu
On Tue, Apr 11, 2017 at 11:22:38AM +0200, Markus Armbruster wrote: > Peter Xu writes: > > > On Fri, Mar 31, 2017 at 07:17:34PM +0300, Michael S. Tsirkin wrote: > >> On Fri, Mar 31, 2017 at 03:36:28PM +0800, Peter Xu wrote: > >> > At the very beginning, the x86 vIOMMUs are created via "-M iommu=on

[Qemu-devel] [RFC 1/2] spec/vhost-user: Introduce secondary channel for slave initiated requests

2017-04-11 Thread Maxime Coquelin
This vhost-user specification update aims at enabling the slave to send requests to the master using a dedicated socket created by the master. It can be used for example when the slave implements a device IOTLB to send cache miss requests to the master. The message types list is updated with an "

[Qemu-devel] [RFC 0/2] vhost-user: Specify device IOTLB support

2017-04-11 Thread Maxime Coquelin
This two-patches series aims at specifying the protocol update required to support device IOTLB with user backends. The protocol is very close to kernel backends, except that a new communication channel is introduced to enable the slave to send requests to the master. While unix sockets are bidir

[Qemu-devel] [RFC 2/2] spec/vhost-user spec: Add IOMMU support

2017-04-11 Thread Maxime Coquelin
This patch specifies the master/slave communication to support device IOTLB implementation 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 s

Re: [Qemu-devel] [PATCH] debug: made printf always compile in debug output

2017-04-11 Thread Markus Armbruster
Stefan Hajnoczi writes: > On Mon, Mar 27, 2017 at 02:50:47PM +0300, Danil Antonov wrote: >> diff --git a/hw/acpi/pcihp.c b/hw/acpi/pcihp.c >> index 2b0f3e1..bf880c1 100644 >> --- a/hw/acpi/pcihp.c >> +++ b/hw/acpi/pcihp.c >> @@ -39,13 +39,16 @@ >> #include "qom/qom-qobject.h" >> #include "qapi/

Re: [Qemu-devel] [PATCH] spapr: remove the 'nr_servers' field from the machine

2017-04-11 Thread David Gibson
On Wed, Apr 05, 2017 at 08:37:44AM +0200, Cédric Le Goater wrote: > xics_system_init() does not need 'nr_servers' anymore as it is only > used to define the 'interrupt-controller' node in the device tree. So > let's just compute the value when calling spapr_dt_xics(). > > This also gives us an opp

Re: [Qemu-devel] [PATCH for 2.10] tcg: enable MTTCG by default for PPC64 on x86

2017-04-11 Thread David Gibson
On Mon, Apr 10, 2017 at 01:42:17PM +0530, Nikunj A Dadhania wrote: > This enables the multi-threaded system emulation by default for PPC64 > guests using the x86_64 TCG back-end. > > Signed-off-by: Nikunj A Dadhania > --- > > Depends on following patch which fixes the define name: > > https://p

Re: [Qemu-devel] [PATCH v2 2/8] ppc/pnv: enable only one LPC bus

2017-04-11 Thread David Gibson
On Tue, Apr 11, 2017 at 09:06:16AM +0200, Cédric Le Goater wrote: > On 04/11/2017 04:40 AM, David Gibson wrote: > > On Mon, Apr 10, 2017 at 03:56:52PM +0200, Cédric Le Goater wrote: > >> The firmware (skiboot) chooses the default LPC bus of a multichip > >> systems using a "primary" property. The L

Re: [Qemu-devel] [PATCH for 2.9 v3 01/10] block: Make bdrv_parent_drained_begin/end public

2017-04-11 Thread Stefan Hajnoczi
On Mon, Apr 10, 2017 at 11:05:33PM +0800, Fam Zheng wrote: > Signed-off-by: Fam Zheng > --- > block/io.c| 4 ++-- > include/block/block.h | 16 > 2 files changed, 18 insertions(+), 2 deletions(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signatu

Re: [Qemu-devel] [PATCH for 2.9 v3 02/10] block: Quiesce old aio context during bdrv_set_aio_context

2017-04-11 Thread Stefan Hajnoczi
On Mon, Apr 10, 2017 at 11:05:34PM +0800, Fam Zheng wrote: > The fact that the bs->aio_context is changing can confuse the dataplane > iothread, because of the now fine granularity aio context lock. > bdrv_drain should rather be a bdrv_drained_begin/end pair, but since > bs->aio_context is changing

Re: [Qemu-devel] [Qemu-block] Making QMP 'block-job-cancel' transactionable

2017-04-11 Thread Kashyap Chamarthy
On Tue, Apr 11, 2017 at 11:42:28AM +0200, Markus Armbruster wrote: > Eric Blake writes: > > > On 04/04/2017 08:28 AM, Kashyap Chamarthy wrote: > > > >>> Minor or not, it is a useful viewpoint. Either way, as long as the new > >>> way of getting a transactional non-pivot successful completion is >

Re: [Qemu-devel] [PATCH v4 7/9] qemu-img: add measure subcommand

2017-04-11 Thread Alberto Garcia
On Wed 05 Apr 2017 05:11:46 PM CEST, Stefan Hajnoczi wrote: > +QemuOptsList *create_opts = NULL; > +bool image_opts = false; > +uint64_t img_size = ~0ULL; Any reason to use ~0ULL instead of UINT64_MAX ? > --- a/qemu-img.texi > +++ b/qemu-img.texi > @@ -429,6 +429,31 @@ preallocated.

[Qemu-devel] [PATCH v1 0/3] Fix cputlb flush stats and exporting data

2017-04-11 Thread Alex Bennée
This is mostly just an RFC for discussion as I know a number of GSoC projects will involve a degree of instrumentation and measurement of the internals of the TCG. The first patch just fixes and expands the counters. The second uses (abuses?) the trace mechanism to export the data via the simpletr

[Qemu-devel] [PATCH v1 1/3] cputlb: fix and enhance TLB statistics

2017-04-11 Thread Alex Bennée
First this fixes the fact that statistics where only being updated if the build was built with DEBUG_TLB. Also it now counts the flush cases based on the degree of synchronisation required to run. This is a more useful discriminator for seeing what is slowing down the translation. Signed-off-by: A

[Qemu-devel] [PATCH v1 2/3] cpus: dump TLB flush counts as trace event

2017-04-11 Thread Alex Bennée
This can be pre-processed later from the trace file. Signed-off-by: Alex Bennée --- cpus.c | 6 ++ trace-events | 3 +++ 2 files changed, 9 insertions(+) diff --git a/cpus.c b/cpus.c index 740b8dc3f8..fae7344df5 100644 --- a/cpus.c +++ b/cpus.c @@ -50,6 +50,8 @@ #include "qapi-event.

[Qemu-devel] [PATCH v1 3/3] new script/analyse-tlb-flushes-simpletrace.py

2017-04-11 Thread Alex Bennée
This is a simple helper script to extract TLB flush stats from the a simpletrace file and plot the results. Signed-off-by: Alex Bennée --- scripts/analyse-tlb-flushes-simpletrace.py | 62 ++ 1 file changed, 62 insertions(+) create mode 100755 scripts/analyse-tlb-flus

Re: [Qemu-devel] [PATCH for 2.9 v3 00/10] block: Fixes regarding dataplane and management operations

2017-04-11 Thread Stefan Hajnoczi
On Mon, Apr 10, 2017 at 11:05:32PM +0800, Fam Zheng wrote: > v3: Respin the unmerged changes from v2 and include one new fix: > > (Yes, it is a big series for the last -rc, and I personally prefer the v2 > approach for the 4-9 part of the problem, which is much more mechanical.) > > -

Re: [Qemu-devel] [PATCH for 2.9 v3 00/10] block: Fixes regarding dataplane and management operations

2017-04-11 Thread Kevin Wolf
Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > v3: Respin the unmerged changes from v2 and include one new fix: > > (Yes, it is a big series for the last -rc, and I personally prefer the v2 > approach for the 4-9 part of the problem, which is much more mechanical.) > > - 1, 2 are

Re: [Qemu-devel] [PATCH for 2.9 v3 05/10] async: Introduce aio_co_enter and aio_co_enter_if_inactive

2017-04-11 Thread Fam Zheng
On Tue, 04/11 11:28, Kevin Wolf wrote: > Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > > They start the coroutine on the specified context. > > > > Signed-off-by: Fam Zheng > > --- > > include/block/aio.h | 18 ++ > > util/async.c| 14 +- > > 2 files cha

Re: [Qemu-devel] [Qemu-ppc] [PATCH 21/21] ppc/pnv: Create a default PCI layout

2017-04-11 Thread Andrea Bolognani
On Wed, 2017-04-05 at 14:41 +0200, Cédric Le Goater wrote: > From: Benjamin Herrenschmidt >  > This creates a legacy PCIe->PCI bridge under the PHB by default to which > a bunch of standard devices are attached. Currently: >  >   - VGA (as specified by -vga) >   - USB (with keyboard and mouse if g

[Qemu-devel] [PATCH for 2.9 v3 11/10] block, async: Remove unused *_enter_if_inactive()

2017-04-11 Thread Kevin Wolf
Signed-off-by: Kevin Wolf --- block.c | 5 - include/block/aio.h | 9 - include/block/block.h | 6 -- util/async.c | 7 --- 4 files changed, 27 deletions(-) diff --git a/block.c b/block.c index e65b906..086a12d 100644 --- a/block.c +++ b/block.c @@ -4

Re: [Qemu-devel] [PATCH v4 8/9] qemu-iotests: support per-format golden output files

2017-04-11 Thread Alberto Garcia
On Wed 05 Apr 2017 05:11:47 PM CEST, Stefan Hajnoczi wrote: > Some tests produce format-dependent output. Either the difference is > filtered out and ignored, or the test case is format-specific so we > don't need to worry about per-format output differences. > > There is a third case: the test sc

Re: [Qemu-devel] [PATCH 2/5] qdev: Export qdev_hot_removed

2017-04-11 Thread Markus Armbruster
Cc: Paolo for additional qdev expertise. Juan Quintela writes: > I need to move qdev_unplug to qdev-monitor in the following patch, and > it needs access to this variable. > > Signed-off-by: Juan Quintela > --- > hw/core/qdev.c | 2 +- > include/hw/qdev-core.h | 1 + > 2 files changed,

Re: [Qemu-devel] [PATCH 3/5] qdev: Move qdev_unplug() to qdev-monitor.c

2017-04-11 Thread Markus Armbruster
Juan Quintela writes: > It is not used by linux-user, otherwise I need to to create one stub > for migration_is_idle() on following patch. > > Signed-off-by: Juan Quintela > --- > hw/core/qdev.c | 34 -- > qdev-monitor.c | 34 ++ >

Re: [Qemu-devel] [PATCH for 2.9 v3 09/10] block: Use bdrv_coroutine_enter to start I/O coroutines

2017-04-11 Thread Fam Zheng
On Tue, 04/11 12:06, Kevin Wolf wrote: > > tests/qemu-iotests/109.out | 10 +- > > This one is curious. Why do we copy more data depending on how the job > coroutine is reentered? I did trace it and think the difference is not very important: on master, the second iteration of the mirror_

Re: [Qemu-devel] [PATCH v4 9/9] iotests: add test 178 for qemu-img measure

2017-04-11 Thread Alberto Garcia
On Wed 05 Apr 2017 05:11:48 PM CEST, Stefan Hajnoczi wrote: > Signed-off-by: Stefan Hajnoczi Reviewed-by: Alberto Garcia Berto

Re: [Qemu-devel] [PATCH for 2.9 v3 09/10] block: Use bdrv_coroutine_enter to start I/O coroutines

2017-04-11 Thread Paolo Bonzini
> So I think we should have another look at Sheepdog, the rest seems to be > fine. Sheepdog currently SEGVs and this might be the cause. I can look at it on Thursday. Paolo

[Qemu-devel] [PATCH v6] kvm: better MWAIT emulation for guests

2017-04-11 Thread Alexander Graf
From: "Michael S. Tsirkin" Guests that are heavy on futexes end up IPI'ing each other a lot. That can lead to significant slowdowns and latency increase for those guests when running within KVM. If only a single guest is needed on a host, we have a lot of spare host CPU time we can throw at the

Re: [Qemu-devel] [RFC PATCH 2/4] nvdimm: add functions to initialize and perform flush on back store

2017-04-11 Thread Xiao Guangrong
On 04/11/2017 04:29 PM, Haozhong Zhang wrote: On 04/11/17 16:22 +0800, Haozhong Zhang wrote: On 04/06/17 19:52 +0800, Xiao Guangrong wrote: On 03/31/2017 04:41 PM, Haozhong Zhang wrote: fsync() is used to persist modifications to the back store. If the host NVDIMM is used as the back store

Re: [Qemu-devel] [PATCH for 2.9 v3 00/10] block: Fixes regarding dataplane and management operations

2017-04-11 Thread Fam Zheng
On Tue, 04/11 13:05, Kevin Wolf wrote: > Am 10.04.2017 um 17:05 hat Fam Zheng geschrieben: > > v3: Respin the unmerged changes from v2 and include one new fix: > > > > (Yes, it is a big series for the last -rc, and I personally prefer the > > v2 > > approach for the 4-9 part of the proble

Re: [Qemu-devel] [PATCH v2] hw/misc: Add Exynos4210 Pseudo Random Number Generator

2017-04-11 Thread Krzysztof Kozlowski
On Mon, Apr 10, 2017 at 5:15 PM, Peter Maydell wrote: > On 4 April 2017 at 15:31, Krzysztof Kozlowski wrote: >> On Tue, Apr 04, 2017 at 03:05:09PM +0100, Peter Maydell wrote: >>> On 4 April 2017 at 14:44, Krzysztof Kozlowski wrote: >>> > On Tue, Apr 04, 2017 at 01:09:08PM +0100, Peter Maydell wr

Re: [Qemu-devel] [Qemu-block] Making QMP 'block-job-cancel' transactionable

2017-04-11 Thread Kevin Wolf
Am 03.04.2017 um 22:29 hat John Snow geschrieben: > On 03/24/2017 08:34 AM, Kashyap Chamarthy wrote: > > While debugging some other issue, I happened to stumble across an old > > libvirt commit[*] that adds support for pivot (whether QEMU should > > switch to a target copy or not) operation as a re

[Qemu-devel] [PATCH v4] migration/block: use blk_pwrite_zeroes for each zero cluster

2017-04-11 Thread jemmy858585
From: Lidong Chen BLOCK_SIZE is (1 << 20), qcow2 cluster size is 65536 by default, this maybe cause the qcow2 file size is bigger after migration. This patch check each cluster, use blk_pwrite_zeroes for each zero cluster. Signed-off-by: Lidong Chen --- migration/block.c | 33 +

[Qemu-devel] [Bug 1635339] Re: qxl_pre_save assertion failure on vm "save"

2017-04-11 Thread Marc Pignat
Did I miss something or this is a bug in the windows qxl driver and should be fixed there? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1635339 Title: qxl_pre_save assertion failure on vm "save"

Re: [Qemu-devel] [PATCH v2] hw/misc: Add Exynos4210 Pseudo Random Number Generator

2017-04-11 Thread Peter Maydell
On 11 April 2017 at 13:02, Krzysztof Kozlowski wrote: > But first I need to setup proper booting image + rootfs instead of > only initramfs. The sdhci node is failing (missing regulators or > capabilities) so essentially there is no storage now. > > How do you access any kind of disk image in case

Re: [Qemu-devel] [PATCH v9 03/13] qemu-io: Switch 'alloc' command to byte-based length

2017-04-11 Thread Eric Blake
On 04/10/2017 09:37 PM, Philippe Mathieu-Daudé wrote: > Hi Eric, > > On 04/10/2017 10:17 PM, Eric Blake wrote: >> For the 'alloc' command, accepting an offset in bytes but a length >> in sectors, and reporting output in sectors, is confusing. Do >> everything in bytes, and adjust the expected out

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

2017-04-11 Thread 858585 jemmy
On Mon, Apr 10, 2017 at 9:52 PM, Stefan Hajnoczi wrote: > On Sat, Apr 08, 2017 at 09:17:58PM +0800, 858585 jemmy wrote: >> On Fri, Apr 7, 2017 at 7:34 PM, Stefan Hajnoczi wrote: >> > On Fri, Apr 07, 2017 at 09:30:33AM +0800, 858585 jemmy wrote: >> >> On Thu, Apr 6, 2017 at 10:02 PM, Stefan Hajnoc

Re: [Qemu-devel] [PATCH v6] Allow setting NUMA distance for different NUMA nodes

2017-04-11 Thread Andrew Jones
On Tue, Apr 11, 2017 at 04:49:26PM +0800, He Chen wrote: > 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 >

[Qemu-devel] Windows 10 IoT Core Raspberry Pi 2 on top of Qemu

2017-04-11 Thread Sameeh Jubran
Hi all, I am trying to run Windows 10 IoT Core for Raspberry Pi 2 on top of Qemu with no luck. I am using this repository https://github.com/0xabu/qemu, and I am using a newer build of Windows IoT core (1607) as earlier versions aren't available to download from Microsoft. The first core is stuck

[Qemu-devel] [PULL 02/11] block: Quiesce old aio context during bdrv_set_aio_context

2017-04-11 Thread Fam Zheng
The fact that the bs->aio_context is changing can confuse the dataplane iothread, because of the now fine granularity aio context lock. bdrv_drain should rather be a bdrv_drained_begin/end pair, but since bs->aio_context is changing, we can just use aio_disable_external and bdrv_parent_drained_begi

[Qemu-devel] [PULL 00/11] Block patches for 2.9-rc4

2017-04-11 Thread Fam Zheng
The following changes since commit 17fa24b79ceaa8258e415822cf2e2cb23cf3facb: Merge remote-tracking branch 'remotes/kraxel/tags/pull-fixes-20170411-1' into staging (2017-04-11 10:03:51 +0100) are available in the git repository at: git://github.com/famz/qemu.git tags/block-pull-re

[Qemu-devel] [PULL 03/11] tests/block-job-txn: Don't start block job before adding to txn

2017-04-11 Thread Fam Zheng
Previously, before test_block_job_start returns, the job can already complete, as a result, the transactional state of other jobs added to the same txn later cannot be handled correctly. Move the block_job_start() calls to callers after block_job_txn_add_job() calls. Signed-off-by: Fam Zheng Ack

[Qemu-devel] [PULL 08/11] qemu-io-cmds: Use bdrv_coroutine_enter

2017-04-11 Thread Fam Zheng
qemu_coroutine_create associates @co to qemu_aio_context but we poll blk's context below. If the coroutine yields, it may never get resumed again. Use bdrv_coroutine_enter to make sure we are starting the I/O on the right context. Signed-off-by: Fam Zheng Acked-by: Stefan Hajnoczi Reviewed-by:

[Qemu-devel] [PULL 05/11] async: Introduce aio_co_enter

2017-04-11 Thread Fam Zheng
They start the coroutine on the specified context. Signed-off-by: Fam Zheng Acked-by: Stefan Hajnoczi Reviewed-by: Kevin Wolf --- include/block/aio.h | 9 + util/async.c| 7 ++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/include/block/aio.h b/include/blo

[Qemu-devel] [PULL 04/11] coroutine: Extract qemu_aio_coroutine_enter

2017-04-11 Thread Fam Zheng
It's a variant of qemu_coroutine_enter with an explicit AioContext parameter. Signed-off-by: Fam Zheng Acked-by: Stefan Hajnoczi Reviewed-by: Kevin Wolf --- include/qemu/coroutine.h | 5 + util/qemu-coroutine.c| 11 --- util/trace-events| 2 +- 3 files changed, 14 ins

[Qemu-devel] [PULL 01/11] block: Make bdrv_parent_drained_begin/end public

2017-04-11 Thread Fam Zheng
Signed-off-by: Fam Zheng Reviewed-by: Stefan Hajnoczi Acked-by: Stefan Hajnoczi Reviewed-by: Kevin Wolf --- block/io.c| 4 ++-- include/block/block.h | 16 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/block/io.c b/block/io.c index 7321dda..95986

[Qemu-devel] [PULL 09/11] block: Use bdrv_coroutine_enter to start I/O coroutines

2017-04-11 Thread Fam Zheng
BDRV_POLL_WHILE waits for the started I/O by releasing bs's ctx then polling the main context, which relies on the yielded coroutine continuing on bs->ctx before notifying qemu_aio_context with bdrv_wakeup(). Thus, using qemu_coroutine_enter to start I/O is wrong because if the coroutine is entere

[Qemu-devel] [PULL 07/11] blockjob: Use bdrv_coroutine_enter to start coroutine

2017-04-11 Thread Fam Zheng
Resuming and especially starting of the block job coroutine, could be issued in the main thread. However the coroutine's "home" ctx should be set to the same context as job->blk. Use bdrv_coroutine_enter to ensure that. Signed-off-by: Fam Zheng Acked-by: Stefan Hajnoczi Reviewed-by: Kevin Wolf

[Qemu-devel] [PULL 06/11] block: Introduce bdrv_coroutine_enter

2017-04-11 Thread Fam Zheng
Signed-off-by: Fam Zheng Acked-by: Stefan Hajnoczi Reviewed-by: Kevin Wolf --- block.c | 5 + include/block/block.h | 5 + 2 files changed, 10 insertions(+) diff --git a/block.c b/block.c index a995a8e..086a12d 100644 --- a/block.c +++ b/block.c @@ -4324,6 +4324,11 @@ Aio

[Qemu-devel] [PULL 11/11] sheepdog: Use bdrv_coroutine_enter before BDRV_POLL_WHILE

2017-04-11 Thread Fam Zheng
When called from main thread, the coroutine should run in the context of bs. Use bdrv_coroutine_enter to ensure that. Signed-off-by: Fam Zheng --- block/sheepdog.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/sheepdog.c b/block/sheepdog.c index 1b71fc8..14d6327 10064

[Qemu-devel] [PULL 10/11] block: Fix bdrv_co_flush early return

2017-04-11 Thread Fam Zheng
bdrv_inc_in_flight and bdrv_dec_in_flight are mandatory for BDRV_POLL_WHILE to work, even for the shortcut case where flush is unnecessary. Move the if block to below bdrv_dec_in_flight, and BTW fix the variable declaration position. Signed-off-by: Fam Zheng Acked-by: Stefan Hajnoczi Reviewed-by

Re: [Qemu-devel] [Qemu-ppc] [PATCH RFC v1 0/3] Enable MTTCG on PPC64

2017-04-11 Thread Cédric Le Goater
On 04/10/2017 07:20 PM, Alex Bennée wrote: > > Cédric Le Goater writes: > >> On 04/07/2017 08:07 AM, Cédric Le Goater wrote: >>> On 04/07/2017 07:24 AM, Nikunj A Dadhania wrote: Cédric Le Goater writes: > Hello Nikunj, > > On 04/06/2017 12:22 PM, Nikunj A Dadhania wrote: >

Re: [Qemu-devel] [PATCH] simpletrace: document Analyzer method signatures

2017-04-11 Thread Alex Bennée
Stefan Hajnoczi writes: > Users can inherit from the simpletrace.Analyzer class and receive > callbacks when events of interest occur in a trace file. The method > signature is a little magic because the timestamp and pid arguments are > optional. Document this. > > Signed-off-by: Stefan Hajno

Re: [Qemu-devel] [PATCH v6] kvm: better MWAIT emulation for guests

2017-04-11 Thread Gabriel L. Somlo
On Tue, Apr 11, 2017 at 01:45:35PM +0200, Alexander Graf wrote: > From: "Michael S. Tsirkin" > > Guests that are heavy on futexes end up IPI'ing each other a lot. That > can lead to significant slowdowns and latency increase for those guests > when running within KVM. > > If only a single guest

Re: [Qemu-devel] [PATCH v6] kvm: better MWAIT emulation for guests

2017-04-11 Thread Alexander Graf
On 04/11/2017 02:41 PM, Gabriel L. Somlo wrote: On Tue, Apr 11, 2017 at 01:45:35PM +0200, Alexander Graf wrote: From: "Michael S. Tsirkin" Guests that are heavy on futexes end up IPI'ing each other a lot. That can lead to significant slowdowns and latency increase for those guests when running

Re: [Qemu-devel] [PATCH v6] kvm: better MWAIT emulation for guests

2017-04-11 Thread Gabriel L. Somlo
On Tue, Apr 11, 2017 at 08:41:11AM -0400, Gabriel L. Somlo wrote: > On Tue, Apr 11, 2017 at 01:45:35PM +0200, Alexander Graf wrote: > > From: "Michael S. Tsirkin" > > > > Guests that are heavy on futexes end up IPI'ing each other a lot. That > > can lead to significant slowdowns and latency incre

[Qemu-devel] [PATCH] qga-win: Enable 'can-offline' field in 'guest-get-vcpus' reply

2017-04-11 Thread Sameeh Jubran
The QGA schema states: @can-offline: Whether offlining the VCPU is possible. This member is always filled in by the guest agent when the structure is returned, and always ignored on input (hence it can be omitted then). Currently 'can-offline' is missi

  1   2   3   >