[Qemu-devel] [PATCH v4 4/9] virtio: handle virtqueue_map_desc() errors

2016-09-20 Thread Stefan Hajnoczi
Errors can occur during virtqueue_pop(), especially in virtqueue_map_desc(). In order to handle this we must unmap iov[] before returning NULL. The caller will consider the virtqueue empty and the virtio_error() call will have marked the device broken. Signed-off-by: Stefan Hajnoczi

Re: [Qemu-devel] [PATCH 1/2] qemu-nbd: Shrink image size by specified offset

2016-09-20 Thread Eric Blake
On 09/20/2016 04:37 AM, Tomáš Golembiovský wrote: [meta-comment]: Your series came through without any threading (you sent three threads, instead of patch 1 and 2 being marked In-Reply-To the 0/2 cover letter). > When --offset is set the apparent device size has to be adjusted > accordingly.

Re: [Qemu-devel] [RFC v2] libvirt vGPU QEMU integration

2016-09-20 Thread Alex Williamson
On Tue, 20 Sep 2016 19:51:58 +0530 Kirti Wankhede wrote: > On 9/20/2016 3:06 AM, Alex Williamson wrote: > > On Tue, 20 Sep 2016 02:05:52 +0530 > > Kirti Wankhede wrote: > > > >> Hi libvirt experts, > >> > >> Thanks for valuable input on v1 version

[Qemu-devel] [PATCH] tests: Ignore test executables

2016-09-20 Thread Eric Blake
Commits 9ef8112a and efad6682 introduced new tests, but forgot to ignore the built executables from an in-tree build. Signed-off-by: Eric Blake --- tests/.gitignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/.gitignore b/tests/.gitignore index

Re: [Qemu-devel] [RFC PATCH] ppc/xics: introduce helpers to find an ICP from some (CPU) index

2016-09-20 Thread David Gibson
On Mon, Sep 19, 2016 at 10:54:10AM +0200, Cédric Le Goater wrote: > Today, the CPU index is used to index the icp array under xics. This > works correctly when the indexes are sync but that is an assumption > that could break future implementations. For instance, the PowerNV > platform CPUs use

Re: [Qemu-devel] [PATCH]MC146818 RTC: coordinate guest clock base to destination host after migration

2016-09-20 Thread zhong...@sangfor.com.cn
yes, the full options on clock is '-rtc driftfix=slew,clock=rt,base=localtime' zhong...@sangfor.com.cn From: Paolo Bonzini Date: 2016-09-20 16:17 To: zhong...@sangfor.com.cn; qemu-devel CC: Michael S. Tsirkin Subject: Re: [PATCH]MC146818 RTC: coordinate guest clock base to destination host

Re: [Qemu-devel] [PATCH v3 17/18] trace: pass trace-events to tracetool as a positional param

2016-09-20 Thread Daniel P. Berrange
On Mon, Sep 19, 2016 at 08:18:51PM +0200, Lluís Vilanova wrote: > Daniel P Berrange writes: > > > Instead of reading the contents of 'trace-events' from stdin, > > accept the filename as a positional parameter. This also > > allows for reading from multiple files, though this facility > > is not

Re: [Qemu-devel] [PATCH v3] virtio: add check for descriptor's mapped address

2016-09-20 Thread Stefan Hajnoczi
On Mon, Sep 19, 2016 at 11:55:45PM +0530, P J P wrote: > From: Prasad J Pandit > > virtio back end uses set of buffers to facilitate I/O operations. > If its size is too large, 'cpu_physical_memory_map' could return > a null address. This would result in a null

Re: [Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 15:51, Pavel Dovgalyuk wrote: >> From: Paolo Bonzini [mailto:pbonz...@redhat.com] >> On 20/09/2016 15:37, Pavel Dovgalyuk wrote: c) no rrsnapshot implies -snapshot: without overlay: -drive file=disk.raw,if=none,id=img-direct -drive

[Qemu-devel] [Bug 1625295] Re: qemu-arm dies with libarmmem inside ld.so.preload

2016-09-20 Thread Peter Maydell
This turns out to be nothing to do with setend. We're doing something wrong emulating the following nasty hack: https://github.com/bavison/arm-mem/blob/master/architecture.S .arm architecture: sub pc, pc, #1 @ is an interworking branch on ARMv7, not ARMv6 and a1, a4, a1

Re: [Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Pavel Dovgalyuk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 20/09/2016 15:37, Pavel Dovgalyuk wrote: > >> c) no rrsnapshot implies -snapshot: > >>without overlay: > >> -drive file=disk.raw,if=none,id=img-direct > >> -drive driver=blkreplay,if=none,image=img-direct,id=img-blkreplay > >>

Re: [Qemu-devel] steps towards deprecation of old boards and devices

2016-09-20 Thread Markus Armbruster
Paolo Bonzini writes: > On 20/09/2016 13:04, Markus Armbruster wrote: >> I'm not proposing to get rid of -serial. I'm proposing to use it as >> indicator of old code in need of modernization. A properly QOMified >> serial device should be "configurable with non-legacy

Re: [Qemu-devel] [PATCH v2] add resolutions via command-line

2016-09-20 Thread G 3
On Sep 20, 2016, at 9:37 AM, Eric Blake wrote: On 09/19/2016 11:28 PM, G 3 wrote: Add the ability to add resolutions from the command-line. This patch works by looking for a property called 'resolutions' in the options node of OpenBIOS. If it is found all the resolutions are parsed and

Re: [Qemu-devel] steps towards deprecation of old boards and devices

2016-09-20 Thread Markus Armbruster
Andreas Färber writes: > Am 20.09.2016 um 10:08 schrieb Markus Armbruster: >> Peter Maydell writes: >> >>> If we're going to aim for deprecating and eventually removing >>> some of our unmaintained device and board models, it seems to >>> me that a

Re: [Qemu-devel] [Bug 1625295] Re: qemu-arm dies with libarmmem inside ld.so.preload

2016-09-20 Thread Stu
Awesome, cheers :) On 20 September 2016 at 14:29, Peter Maydell wrote: > Thanks. I can reproduce this with the current QEMU, so there is still a > problem of some kind here. > > -- > You received this bug notification because you are subscribed to the bug > report. >

Re: [Qemu-devel] [PATCH v3 13/18] trace: dynamically allocate event IDs at runtime

2016-09-20 Thread Daniel P. Berrange
On Mon, Sep 19, 2016 at 08:05:12PM +0200, Lluís Vilanova wrote: > Daniel P Berrange writes: > > > Instead of having the code generator assign event IDs and > > event VCPU IDs, assign them when the events are registered > > at runtime. This will allow us allow code to be generated > > from

[Qemu-devel] [PATCH/RFC] loader: enable roms, kernel and firmware files for KSM sharing

2016-09-20 Thread Christian Borntraeger
Early patch for feedback. With lots of similar small guests a big part of memory is consumed by the ROMs that are reloaded at each start. We can reduce the memory consumption by allowing KSM on this data. This patches reduces the memory consumption of 200 guests with a vmlinux as kernel + busybox

Re: [Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 15:37, Pavel Dovgalyuk wrote: >> c) no rrsnapshot implies -snapshot: >>without overlay: >> -drive file=disk.raw,if=none,id=img-direct >> -drive driver=blkreplay,if=none,image=img-direct,id=img-blkreplay >> >>with overlay: >> -drive

Re: [Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Pavel Dovgalyuk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 20/09/2016 14:39, Pavel Dovgalyuk wrote: > > > > +replay_snapshot = g_strdup(qemu_opt_get(opts, "rrsnapshot")); > > > > + > > > > replay_enable(fname, mode); > > > > > > > > > > Should you set snapshot = 1 here if there is no

Re: [Qemu-devel] [PATCH v3 08/18] trace: remove the TraceEventID and TraceEventVCPUID enums

2016-09-20 Thread Daniel P. Berrange
On Mon, Sep 19, 2016 at 07:48:59PM +0200, Lluís Vilanova wrote: > Daniel P Berrange writes: > > > The TraceEventID and TraceEventVCPUID enums constants are > > no longer actually used for anything critical. > > > The TRACE_EVENT_COUNT limit is used to determine the size > > of the TraceEvents

Re: [Qemu-devel] [PATCH v3 02/18] trace: convert code to use event iterators

2016-09-20 Thread Lluís Vilanova
Daniel P Berrange writes: > On Mon, Sep 19, 2016 at 06:59:17PM +0200, Lluís Vilanova wrote: >> Daniel P Berrange writes: >> >> > This converts the HMP/QMP monitor API implementations >> > and some internal trace control methods to use the new >> > trace event iterator APIs. >> >> > Reviewed-by:

Re: [Qemu-devel] [PATCH v2] add resolutions via command-line

2016-09-20 Thread Eric Blake
On 09/19/2016 11:28 PM, G 3 wrote: > Add the ability to add resolutions from the command-line. This patch > works by > looking for a property called 'resolutions' in the options node of > OpenBIOS. > If it is found all the resolutions are parsed and loaded. > > +/* strlen() implementation */ >

[Qemu-devel] [Bug 1625295] Re: qemu-arm dies with libarmmem inside ld.so.preload

2016-09-20 Thread Peter Maydell
Thanks. I can reproduce this with the current QEMU, so there is still a problem of some kind here. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1625295 Title: qemu-arm dies with libarmmem inside

Re: [Qemu-devel] [PATCH v3 0/8] replay additions

2016-09-20 Thread no-reply
Hi, Your series seems to have some coding style problems. See output below for more information: Message-id: 20160920123126.5400.29283.st...@pasha-isp.def.inno Subject: [Qemu-devel] [PATCH v3 0/8] replay additions Type: series === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log

Re: [Qemu-devel] [PATCH v3 00/10] virtio: avoid exit() when device enters invalid states

2016-09-20 Thread Stefan Hajnoczi
On Mon, Sep 19, 2016 at 06:07:40PM +0200, Cornelia Huck wrote: > Do you have a version that fits on current master? Thanks for reminding me about this series. I will send a rebased version. Stefan signature.asc Description: PGP signature

Re: [Qemu-devel] [V18 2/4] hw/i386/trace-events: Add AMD IOMMU trace events

2016-09-20 Thread Michael S. Tsirkin
On Tue, Sep 20, 2016 at 04:21:41PM +0300, David Kiarie wrote: > >     > +amdvi_mode_invalid(unsigned level, uint64_t addr)"error: > translation > >     level 0x%"PRIu8" translating addr 0x%"PRIx64 > > This is also wrong. Can you pls go over the traces? > > > I think you might be

Re: [Qemu-devel] [PATCH v3 06/18] trace: break circular dependancy in event-internal.h

2016-09-20 Thread Daniel P. Berrange
On Mon, Sep 19, 2016 at 07:08:57PM +0200, Lluís Vilanova wrote: > Typo in subject: dependancy -> dependency > > Daniel P Berrange writes: > > > Currently event-internal.h includes generated-events.h, > > while generated-events.h includes event-internal.h > > causing a circular dependency. > > >

Re: [Qemu-devel] [V18 2/4] hw/i386/trace-events: Add AMD IOMMU trace events

2016-09-20 Thread David Kiarie
On Tue, Sep 20, 2016 at 4:40 AM, Michael S. Tsirkin wrote: > On Tue, Sep 20, 2016 at 04:14:14AM +0300, David Kiarie wrote: > > > > > > On Tue, Sep 20, 2016 at 3:09 AM, Michael S. Tsirkin > wrote: > > > > On Tue, Sep 20, 2016 at 03:05:02AM +0300, David

[Qemu-devel] [PATCH v2 07/11] qemu-iotests/118: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/118 | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/tests/qemu-iotests/118

[Qemu-devel] [PATCH v2 10/11] qemu-iotests/141: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/141 | 24 ++-- tests/qemu-iotests/141.out | 24 2 files

Re: [Qemu-devel] [PATCH v3 02/18] trace: convert code to use event iterators

2016-09-20 Thread Daniel P. Berrange
On Mon, Sep 19, 2016 at 06:59:17PM +0200, Lluís Vilanova wrote: > Daniel P Berrange writes: > > > This converts the HMP/QMP monitor API implementations > > and some internal trace control methods to use the new > > trace event iterator APIs. > > > Reviewed-by: Stefan Hajnoczi

Re: [Qemu-devel] [PATCH]MC146818 RTC: coordinate guest clock base to destination host after migration

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 14:54, zhong...@sangfor.com.cn wrote: > Hi, Paolo > The reason that use rtc_flush_time/rtc_adjust_timebase pairs instead > of rtc_update_time/rtc_set_time is a trick. > what all we do is to coordinate the base point of time line for guest on > a new host. So, we don't flush

[Qemu-devel] [PATCH v2 11/11] block: Remove BB interface from blockdev-add/del

2016-09-20 Thread Kevin Wolf
With this patch, blockdev-add always works on a node level, i.e. it creates a BDS, but no BB. Consequently, x-blockdev-del doesn't need the 'device' option any more, but 'node-name' becomes mandatory. Signed-off-by: Kevin Wolf --- blockdev.c| 127

[Qemu-devel] [PATCH v2 09/11] qemu-iotests/139: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/139 | 178 +++-- tests/qemu-iotests/139.out | 4 +- 2 files

[Qemu-devel] [PATCH v2 03/11] qemu-iotests/071: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/071 | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/qemu-iotests/071

Re: [Qemu-devel] [PATCH v2] add resolutions via command-line

2016-09-20 Thread G 3
On Sep 20, 2016, at 5:01 AM, Benjamin Herrenschmidt wrote: On Tue, 2016-09-20 at 00:28 -0400, G 3 wrote: + RegEntryID *entry_id; + OSErr err; + OSStatus os_status = noErr; + Boolean is_done; + void *value; + RegPropertyValueSize property_size = -1; +

[Qemu-devel] [PATCH v2 08/11] qemu-iotests/124: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/124 | 17 ++--- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git

[Qemu-devel] [PATCH v2 06/11] qemu-iotests/117: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/117 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/qemu-iotests/117

[Qemu-devel] [PATCH v2 02/11] qemu-iotests/067: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. In order to keep the test meaningful, some instances of query-block that want to check whether the node still exists and would now turn up empty must be converted to

[Qemu-devel] [PATCH v2 05/11] qemu-iotests/087: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. The test cases that test conflicts between the 'id' option to blockdev-add and existing block devices or the 'node-name' of the same command can be removed because it won't be

[Qemu-devel] [PATCH v2 01/11] qemu-iotests/041: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/041 | 71 +++--- 1 file changed, 32 insertions(+), 39

[Qemu-devel] [PATCH v2 04/11] qemu-iotests/081: Avoid blockdev-add with id

2016-09-20 Thread Kevin Wolf
We want to remove the 'id' option for blockdev-add. This removes one user of the option and makes it use only node names. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/081 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/081

[Qemu-devel] [PATCH v2 00/11] block: Remove BB interface from blockdev-add/del

2016-09-20 Thread Kevin Wolf
This series makes the next step towards a QAPI interface that doesn't require clients to know about BlockBackends. By removing the support for 'id' from blockdev-add, it becomes a command that always only creates a BDS (with a node name). Existing interfaces have already been changed to accept

Re: [Qemu-devel] [Bug 1625295] Re: qemu-arm dies with libarmmem inside ld.so.preload

2016-09-20 Thread Stu
Are bash scripts OK ? I put everything into some scripts - I'm on ubuntu, debian should be similar - not sure about other platforms. # Grab scripts $ git clone https://github.com/stuaxo/raspbian-qemu-scripts $ cd raspbian-qemu-scripts # Download current raspbian lite to /tmp/raspbian: $

Re: [Qemu-devel] [PATCH v3 2/8] block: set snapshot option for block devices in blkreplay module

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 14:43, Pavel Dovgalyuk wrote: > > No, this is unnecessary. The image is unused in this case, so you can > > specify the overlay as image=foo.qcow2. > > This branch allows user do not bother about overlays at all. > Driver will automatically create temporary snapshot. See other

Re: [Qemu-devel] [PATCH v7 2/4] vfio: VFIO driver for mediated devices

2016-09-20 Thread Jike Song
On 08/25/2016 11:53 AM, Kirti Wankhede wrote: /* {snip} */ To show another possible implementation of vfio-mdev, which provides the thinnest framework and let the vendor physical drivers do whatever they want to. Again, it is diff-ed against Kirti's version 7, for demonstration only. -- Thanks,

Re: [Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 14:39, Pavel Dovgalyuk wrote: > > > +replay_snapshot = g_strdup(qemu_opt_get(opts, "rrsnapshot")); > > > + > > > replay_enable(fname, mode); > > > > > > > Should you set snapshot = 1 here if there is no rrsnapshot option? > > No, because there is default snapshot name

Re: [Qemu-devel] [PATCH v7 1/4] vfio: Mediated device Core driver

2016-09-20 Thread Jike Song
On 08/25/2016 11:53 AM, Kirti Wankhede wrote: /* {snip} */ To show a straight-forward way of introducing an independent struct device for the middle layer (in Kirti's patch the parent device, we changed it to mdev_host since 'parent' is something too generic or misleading) between physical device

Re: [Qemu-devel] [PATCH 2/2] qemu-nbd: Add --image-size option

2016-09-20 Thread Richard W.M. Jones
On Tue, Sep 20, 2016 at 01:35:29PM +0200, Tomáš Golembiovský wrote: > The second patch tries to solve the situation when you have file: > > || some data ; image ; some more data || > > In this case there is no way to say where the image ends and client may > also access content in the "some

Re: [Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Pavel Dovgalyuk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 20/09/2016 14:31, Pavel Dovgalyuk wrote: > > @@ -291,6 +292,8 @@ void replay_configure(QemuOpts *opts) > > exit(1); > > } > > > > +replay_snapshot = g_strdup(qemu_opt_get(opts, "rrsnapshot")); > > + > >

[Qemu-devel] [PATCH v3 7/8] replay: allow replay stopping and restarting

2016-09-20 Thread Pavel Dovgalyuk
This patch fixes bug with stopping and restarting replay through monitor. Signed-off-by: Pavel Dovgalyuk --- block/blkreplay.c| 15 +-- cpus.c |1 + include/sysemu/replay.h |4 replay/replay-events.c |8

Re: [Qemu-devel] [PATCH v3 2/8] block: set snapshot option for block devices in blkreplay module

2016-09-20 Thread Pavel Dovgalyuk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 20/09/2016 14:31, Pavel Dovgalyuk wrote: > > /* Open the image file */ > > bs->file = bdrv_open_child(NULL, options, "image", > > @@ -40,6 +112,43 @@ static int blkreplay_open(BlockDriverState *bs, QDict > > *options, int > flags,

[Qemu-devel] [PATCH v3 6/8] replay: vmstate for replay module

2016-09-20 Thread Pavel Dovgalyuk
This patch introduces vmstate for replay data structures. It allows saving and loading vmstate while replaying. Signed-off-by: Pavel Dovgalyuk --- replay/replay-internal.h |9 + replay/replay-snapshot.c | 40

[Qemu-devel] [PATCH v3 8/8] integratorcp: adding vmstate for save/restore

2016-09-20 Thread Pavel Dovgalyuk
From: Pavel Dovgalyuk VMState added by this patch preserves correct loading of the integratorcp device state. Signed-off-by: Pavel Dovgalyuk --- hw/arm/integratorcp.c | 62 + 1 file changed,

Re: [Qemu-devel] [PATCH v3 2/8] block: set snapshot option for block devices in blkreplay module

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 14:31, Pavel Dovgalyuk wrote: > /* Open the image file */ > bs->file = bdrv_open_child(NULL, options, "image", > @@ -40,6 +112,43 @@ static int blkreplay_open(BlockDriverState *bs, QDict > *options, int flags, > goto fail; > } > > +opts =

Re: [Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 14:31, Pavel Dovgalyuk wrote: > @@ -291,6 +292,8 @@ void replay_configure(QemuOpts *opts) > exit(1); > } > > +replay_snapshot = g_strdup(qemu_opt_get(opts, "rrsnapshot")); > + > replay_enable(fname, mode); > Should you set snapshot = 1 here if there is

[Qemu-devel] [PATCH v3 5/8] replay: move internal data to the structure

2016-09-20 Thread Pavel Dovgalyuk
This patch moves replay static variables into the structure to allow saving and loading them with savevm/loadvm. Reviewed-by: Paolo Bonzini Signed-off-by: Pavel Dovgalyuk --- replay/replay-events.c |2 +- replay/replay-internal.c | 19

[Qemu-devel] [PATCH v3 2/8] block: set snapshot option for block devices in blkreplay module

2016-09-20 Thread Pavel Dovgalyuk
This patch adds overlay option for blkreplay filter. It allows creating persistent overlay file for saving and reloading VM snapshots in record/replay modes. Signed-off-by: Pavel Dovgalyuk --- block/blkreplay.c | 119

[Qemu-devel] [PATCH v3 1/8] record/replay: add network support

2016-09-20 Thread Pavel Dovgalyuk
This patch adds support of recording and replaying network packets in irount rr mode. Record and replay for network interactions is performed with the network filter. Each backend must have its own instance of the replay filter as follows: -netdev user,id=net1 -device rtl8139,netdev=net1

[Qemu-devel] [PATCH v3 0/8] replay additions

2016-09-20 Thread Pavel Dovgalyuk
This set of patches includes several fixes for replay and adds network record/replay for network devices. It also makes possible saving/restoring vmstate in replay mode. Record and replay for network interactions is performed with the network filter. Each backend must have its own instance of the

[Qemu-devel] [PATCH v3 4/8] replay: save/load initial state

2016-09-20 Thread Pavel Dovgalyuk
This patch implements initial vmstate creation or loading at the start of record/replay. It is needed for rewinding the execution in the replay mode. v3 changes: - added rrsnapshot option Signed-off-by: Pavel Dovgalyuk --- docs/replay.txt | 12

[Qemu-devel] [PATCH v3 3/8] block: don't make snapshots for filters

2016-09-20 Thread Pavel Dovgalyuk
This patch disables snapshotting for block driver filters. It is needed, because snapshots should be created in underlying disk images, not in filters itself. Signed-off-by: Pavel Dovgalyuk --- block/snapshot.c |3 +++ 1 file changed, 3 insertions(+) diff --git

Re: [Qemu-devel] KVM-PR is broken with current QEMU

2016-09-20 Thread Cédric Le Goater
On 09/20/2016 01:44 PM, Thomas Huth wrote: > Hi, > > when I try to run my guest in KVM-PR mode, current QEMU refuses to start: > > $ sudo qemu-system-ppc64 -M pseries,accel=kvm,kvm-type=PR \ >-nographic -vga none -cpu POWER8 > qemu: fatal: Unknown MMU model

Re: [Qemu-devel] [PATCH v4 0/2] block: allow flush on devices with open tray

2016-09-20 Thread Kevin Wolf
Am 19.09.2016 um 22:58 hat Max Reitz geschrieben: > On 19.09.2016 18:44, John Snow wrote: > > Final re-send for wording. > > > > The move to blk_flush altered the behavior of migration and flushing > > nodes that are not reachable via the guest, but are still reachable > > via QEMU and may or may

[Qemu-devel] [PATCH] s390x/kvm: Fix potential deadlock in sigp handling

2016-09-20 Thread Christian Borntraeger
FYI, unless I find a better alternative, I plan to go with this patch. --snip-- [PATCH] s390x/kvm: Fix potential deadlock in sigp handling If two VCPUs exit at the same time and target each other with a sigp, both could run into a deadlock as run_on_cpu on CPU0 will free the BQL when

Re: [Qemu-devel] [PATCH v3 10/10] virtio: handle virtqueue_get_head() errors

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:34 +0100 Stefan Hajnoczi wrote: > Stop processing the vring if virtqueue_get_head() fetches an > out-of-bounds head index. > > Signed-off-by: Stefan Hajnoczi > --- > hw/virtio/virtio.c | 26 -- > 1

Re: [Qemu-devel] [PATCH v3 01/10] ppc/pnv: add skeleton PowerNV platform

2016-09-20 Thread David Gibson
On Thu, Sep 15, 2016 at 02:45:51PM +0200, Cédric Le Goater wrote: > From: Benjamin Herrenschmidt > > The goal is to emulate a PowerNV system at the level of the skiboot > firmware, which loads the OS and provides some runtime services. Power > Systems have a lower

Re: [Qemu-devel] [PATCH v5 3/3] target-ppc: tlbie/tlbivax should have global effect

2016-09-20 Thread David Gibson
On Mon, Sep 19, 2016 at 11:52:12AM +0530, Nikunj A Dadhania wrote: > tlbie (BookS) and tlbivax (BookE) plus the H_CALLs(pseries) should have > a global effect. > > Introduces TLB_NEED_GLOBAL_FLUSH flag. During lazy tlb flush, after > taking care of pending local flushes, check broadcast flush(at

Re: [Qemu-devel] [PATCH v1] spapr: Introduce sPAPRCPUCoreClass

2016-09-20 Thread David Gibson
On Mon, Sep 12, 2016 at 01:27:20PM +0530, Bharata B Rao wrote: > Each spapr cpu core type defines an instance_init routine which just > populates the CPU class name. This can be done in the class_init > commonly for all core types which simplifies the registration. > This is inspired by how

Re: [Qemu-devel] [PULL v3 0/8] Block layer patches

2016-09-20 Thread Peter Maydell
On 19 September 2016 at 22:45, Max Reitz wrote: > The following changes since commit 33e1666b4289313306371fee0740f5c85517e406: > > Merge remote-tracking branch 'remotes/armbru/tags/pull-qapi-2016-09-19' > into staging (2016-09-19 18:06:52 +0100) > > are available in the git

Re: [Qemu-devel] [PATCH v3 06/10] virtio: handle virtqueue_get_avail_bytes() errors

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:30 +0100 Stefan Hajnoczi wrote: > If the vring is invalid, tell the caller no bytes are available and mark > the device broken. > > Signed-off-by: Stefan Hajnoczi > --- > hw/virtio/virtio.c | 17 +++-- > 1 file

Re: [Qemu-devel] [PATCH v3 00/10] virtio: avoid exit() when device enters invalid states

2016-09-20 Thread Cornelia Huck
On Tue, 20 Sep 2016 11:26:57 +0200 Greg Kurz wrote: > Stefan's series still applies on the current head, except the virtio_config.h > patch which isn't needed anymore. I went through the patches, series generally looks good to me. > > And indeed there are a bunch of places

Re: [Qemu-devel] [PATCH v3 08/10] virtio: handle virtqueue_read_next_desc() errors

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:32 +0100 Stefan Hajnoczi wrote: > Stop processing the vring if an avail ring index is invalid. > > Signed-off-by: Stefan Hajnoczi > --- > hw/virtio/virtio.c | 45 - > 1 file

[Qemu-devel] KVM-PR is broken with current QEMU

2016-09-20 Thread Thomas Huth
Hi, when I try to run my guest in KVM-PR mode, current QEMU refuses to start: $ sudo qemu-system-ppc64 -M pseries,accel=kvm,kvm-type=PR \ -nographic -vga none -cpu POWER8 qemu: fatal: Unknown MMU model 851972 ... followed by a useless register dump. I've bisected

Re: [Qemu-devel] [PATCH v3 09/10] virtio: handle virtqueue_num_heads() errors

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:33 +0100 Stefan Hajnoczi wrote: > If the avail ring index is bogus virtqueue_num_heads() must return > -EINVAL. > > The only caller is virtqueue_get_avail_bytes(). Return saying no bytes > are available when virtqueue_num_heads() fails. > >

Re: [Qemu-devel] [PATCH v5 2/3] target-ppc: add flag in chech_tlb_flush()

2016-09-20 Thread David Gibson
On Mon, Sep 19, 2016 at 11:52:11AM +0530, Nikunj A Dadhania wrote: > We flush the qemu TLB lazily. check_tlb_flush is called whenever we hit > a context synchronizing event or instruction that requires a pending > flush to be performed. > > However, we fail to handle broadcast TLB flush

Re: [Qemu-devel] steps towards deprecation of old boards and devices

2016-09-20 Thread Andreas Färber
Am 20.09.2016 um 10:08 schrieb Markus Armbruster: > Peter Maydell writes: > >> If we're going to aim for deprecating and eventually removing >> some of our unmaintained device and board models, it seems to >> me that a good first step would be to come up with a

Re: [Qemu-devel] [PATCH 2/2] qemu-nbd: Add --image-size option

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 13:12, Daniel P. Berrange wrote: > On Tue, Sep 20, 2016 at 11:59:28AM +0200, Paolo Bonzini wrote: >> >> >> On 20/09/2016 11:41, Tomáš Golembiovský wrote: >>> When image is part of the file it makes sense to limit the length of the >>> image in the file. Otherwise it is assumed that

Re: [Qemu-devel] [PATCH v5 1/3] target-ppc: add TLB_NEED_LOCAL_FLUSH flag

2016-09-20 Thread David Gibson
On Mon, Sep 19, 2016 at 11:52:10AM +0530, Nikunj A Dadhania wrote: > Introduces bit-flag in CPUPPCState::tlb_need_flush: > > TLB_NEED_LOCAL_FLUSH (0x1) - Flush local tlb > > This would indicate a pending local tlb flush (isync instructions, > interrupts, ...) > > Signed-off-by: Nikunj A

Re: [Qemu-devel] [PATCH v3 07/10] virtio: use unsigned int for virtqueue_get_avail_bytes() index

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:31 +0100 Stefan Hajnoczi wrote: > The virtio code uses int, unsigned int, and uint16_t for virtqueue > indices. The uint16_t is used for the low-level descriptor layout in > virtio_ring.h while code that isn't concerned with descriptor layout can >

[Qemu-devel] [PATCH v3 08/10] block: Accept device model name for blockdev-change-medium

2016-09-20 Thread Kevin Wolf
In order to remove the necessity to use BlockBackend names in the external API, we want to allow qdev device names in all device related commands. This converts blockdev-change-medium to accept a qdev device name. Signed-off-by: Kevin Wolf --- blockdev.c| 18

[Qemu-devel] [PATCH v3 09/10] block: Accept device model name for block_set_io_throttle

2016-09-20 Thread Kevin Wolf
In order to remove the necessity to use BlockBackend names in the external API, we want to allow qdev device names in all device related commands. This converts block_set_io_throttle to accept a qdev device name. Signed-off-by: Kevin Wolf --- blockdev.c| 12

Re: [Qemu-devel] steps towards deprecation of old boards and devices

2016-09-20 Thread Paolo Bonzini
On 20/09/2016 13:04, Markus Armbruster wrote: > I'm not proposing to get rid of -serial. I'm proposing to use it as > indicator of old code in need of modernization. A properly QOMified > serial device should be "configurable with non-legacy means". Devices > that aren't are probably not

[Qemu-devel] [PATCH v3 10/10] qemu-iotests/118: Test media change with qdev name

2016-09-20 Thread Kevin Wolf
We just added the option to use qdev device names in all device related block QMP commands. This patch converts some of the test cases in 118 to use qdev device names instead of BlockBackend names to cover the new way. It converts cases for each of the media change commands, but only for CD-ROM

[Qemu-devel] [PATCH v3 04/10] block: Accept device model name for blockdev-open/close-tray

2016-09-20 Thread Kevin Wolf
In order to remove the necessity to use BlockBackend names in the external API, we want to allow qdev device names in all device related commands. This converts blockdev-open/close-tray to accept a qdev device name. Signed-off-by: Kevin Wolf --- blockdev.c| 61

[Qemu-devel] [PATCH v3 06/10] block: Accept device model name for x-blockdev-remove-medium

2016-09-20 Thread Kevin Wolf
In order to remove the necessity to use BlockBackend names in the external API, we want to allow qdev device names in all device related commands. This converts x-blockdev-remove-medium to accept a qdev device name. As the command is experimental, we can still remove the 'device' option that

Re: [Qemu-devel] [PATCH v3 05/10] virtio: handle virtqueue_map_desc() errors

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:29 +0100 Stefan Hajnoczi wrote: > Errors can occur during virtqueue_pop(), especially in > virtqueue_map_desc(). In order to handle this we must unmap iov[] > before returning NULL. The caller will consider the virtqueue empty and > the

[Qemu-devel] [PATCH v3 07/10] block: Accept device model name for eject

2016-09-20 Thread Kevin Wolf
In order to remove the necessity to use BlockBackend names in the external API, we want to allow qdev device names in all device related commands. This converts eject to accept a qdev device name. Signed-off-by: Kevin Wolf --- blockdev.c| 10 +++---

[Qemu-devel] [PATCH v3 02/10] qdev-monitor: Factor out find_device_state()

2016-09-20 Thread Kevin Wolf
Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake --- qdev-monitor.c | 16 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/qdev-monitor.c b/qdev-monitor.c index e19617f..bc0213f 100644 --- a/qdev-monitor.c +++ b/qdev-monitor.c

[Qemu-devel] [PATCH v3 03/10] qdev-monitor: Add blk_by_qdev_id()

2016-09-20 Thread Kevin Wolf
This finds the BlockBackend attached to the device model identified by its qdev ID. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake --- include/sysemu/block-backend.h | 1 + qdev-monitor.c | 18 ++ 2 files changed, 19

[Qemu-devel] [PATCH v3 05/10] block: Accept device model name for x-blockdev-insert-medium

2016-09-20 Thread Kevin Wolf
In order to remove the necessity to use BlockBackend names in the external API, we want to allow qdev device names in all device related commands. This converts x-blockdev-insert-medium to accept a qdev device name. As the command is experimental, we can still remove the 'device' option that

[Qemu-devel] [PATCH v3 01/10] block: Add blk_by_dev()

2016-09-20 Thread Kevin Wolf
This finds a BlockBackend given the device model that is attached to it. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake --- block/block-backend.c | 19 +++ include/sysemu/block-backend.h | 1 + 2 files changed, 20 insertions(+)

[Qemu-devel] [PATCH v3 00/10] block: Accept qdev IDs in device level QMP commands

2016-09-20 Thread Kevin Wolf
In order to remove the necessity to use BlockBackend names in the external API, we already converted all block layer QMP commands on the node level to accept node names instead of BlockBackend names. This series converts the second part, device level commands, to allow qdev device names instead of

Re: [Qemu-devel] [PATCH v3 04/10] virtio: migrate vdev->broken flag

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:28 +0100 Stefan Hajnoczi wrote: > Send a subsection if the vdev->broken flag is set. This allows live > migration of broken virtio devices. > > The subsection is only sent if vdev->broken has been set. In most cases > the flag will be clear and

Re: [Qemu-devel] [PATCH 2/2] qemu-nbd: Add --image-size option

2016-09-20 Thread Tomáš Golembiovský
On Tue, 20 Sep 2016 11:59:28 +0200 Paolo Bonzini wrote: > On 20/09/2016 11:41, Tomáš Golembiovský wrote: > > When image is part of the file it makes sense to limit the length of the > > image in the file. Otherwise it is assumed that the image spans to the > > end of the

Re: [Qemu-devel] [PATCH v3 03/10] virtio: stop virtqueue processing if device is broken

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:27 +0100 Stefan Hajnoczi wrote: > QEMU prints an error message and exits when the device enters an invalid > state. Terminating the process is heavy-handed. The guest may still be > able to function even if there is a bug in a virtio guest driver.

Re: [Qemu-devel] [PATCH v3 01/10] virtio: fix stray tab character

2016-09-20 Thread Cornelia Huck
On Tue, 12 Apr 2016 14:25:25 +0100 Stefan Hajnoczi wrote: > Fix a single occurrence of a tab character in a file that otherwise uses > spaces for indentation. > > Signed-off-by: Stefan Hajnoczi > Reviewed-by: Fam Zheng > --- > v3: >

Re: [Qemu-devel] [PATCH] docker: Handle exceptions when looking for docker command

2016-09-20 Thread Fam Zheng
On Tue, 09/20 08:05, Eduardo Habkost wrote: > When trying to run docker tests on a host without the docker > command, we get the following Python backtrace: > > $ make docker-test-quick@centos6 V=1 > .../qemu/tests/docker/docker.py build qemu:centos6 >

Re: [Qemu-devel] [PATCH 0/6] firmware-qemu_fw_cfg: Fine-tuning for four function implementations

2016-09-20 Thread Gabriel L. Somlo
On Sun, Sep 18, 2016 at 02:48:30PM +0200, SF Markus Elfring wrote: > From: Markus Elfring > Date: Sun, 18 Sep 2016 14:43:21 +0200 > > Some update suggestions were taken into account > from static source code analysis. > > Markus Elfring (6): > Use

Re: [Qemu-devel] [PATCH 2/2] qemu-nbd: Add --image-size option

2016-09-20 Thread Daniel P. Berrange
On Tue, Sep 20, 2016 at 11:59:28AM +0200, Paolo Bonzini wrote: > > > On 20/09/2016 11:41, Tomáš Golembiovský wrote: > > When image is part of the file it makes sense to limit the length of the > > image in the file. Otherwise it is assumed that the image spans to the > > end of the file. This

<    1   2   3   4   5   >