Re: [Qemu-devel] [PATCH 08/12] pci: allow 0 address for PCI IO regions

2014-08-27 Thread Michael S. Tsirkin
On Mon, Aug 18, 2014 at 07:21:54PM -0500, Michael Roth wrote: > Some kernels program a 0 address for io regions. PCI 3.0 spec > section 6.2.5.1 doesn't seem to disallow this. > > Signed-off-by: Michael Roth Yes the PCI spec does not care. But unfortunately as documented in the comment, at least

Re: [Qemu-devel] [Qemu-trivial] [PATCH] curl: The macro that you have to uncomment to get debugging is DEBUG_CURL.

2014-08-27 Thread Michael Tokarev
Applied to -trivial ;), thank you! /mjt

Re: [Qemu-devel] [PATCH v6 2/7] tests: Add virtio device initialization

2014-08-27 Thread Stefan Hajnoczi
On Mon, Aug 25, 2014 at 10:36:08AM +0200, Marc Marí wrote: > +static uint16_t qvirtio_pci_config_readw(QVirtioDevice *d, void *addr) > +{ > +QVirtioPCIDevice *dev = (QVirtioPCIDevice *)d; > +return qpci_io_readw(dev->pdev, addr); > +} > + > +static uint32_t qvirtio_pci_config_readl(QVirtioD

Re: [Qemu-devel] [RFC PATCH v2 07/13] spapr_rtas: Add Dynamic DMA windows (DDW) RTAS calls support

2014-08-27 Thread Alexey Kardashevskiy
On 08/27/2014 07:36 PM, Alexander Graf wrote: > > > On 15.08.14 12:12, Alexey Kardashevskiy wrote: >> This adds support for Dynamic DMA Windows (DDW) option defined by >> the SPAPR specification which allows to have additional DMA window(s) >> which can support page sizes other than 4K. >> >> The

Re: [Qemu-devel] [PATCH v6 3/7] libqos: Added basic virtqueue support to virtio implementation

2014-08-27 Thread Stefan Hajnoczi
On Mon, Aug 25, 2014 at 10:36:09AM +0200, Marc Marí wrote: > Add status changing and feature negotiation. > Add basic virtqueue support for adding and sending virtqueue requests. > Add ISR checking. > > Signed-off-by: Marc Marí > --- > tests/libqos/virtio-pci.c | 82 + > te

Re: [Qemu-devel] [PATCH v6 4/7] libqos: Added indirect descriptor support to virtio implementation

2014-08-27 Thread Stefan Hajnoczi
On Mon, Aug 25, 2014 at 10:36:10AM +0200, Marc Marí wrote: > Add functions necessary for working with indirect descriptors. > Add test using new functions. > > Signed-off-by: Marc Marí > --- > tests/libqos/virtio-pci.c | 10 + > tests/libqos/virtio.c | 64

Re: [Qemu-devel] [PATCH] acpi-build: Set FORCE_APIC_CLUSTER_MODEL bit of FADT flags

2014-08-27 Thread Michael S. Tsirkin
On Thu, Aug 21, 2014 at 04:37:29PM +0800, zhanghailiang wrote: > If we start Windows 2008 R2 DataCenter with number of cpu less than 8, > The system will use APIC Flat Logical destination mode as default > configuration, > Which has an upper limit of 8 CPUs. > > The fault is that VM can not show

Re: [Qemu-devel] [PATCH v6 5/7] libqos: Added test case for configuration changes in virtio-blk test

2014-08-27 Thread Stefan Hajnoczi
On Mon, Aug 25, 2014 at 10:36:11AM +0200, Marc Marí wrote: > Signed-off-by: Marc Marí > --- > tests/virtio-blk-test.c | 34 ++ > 1 file changed, 34 insertions(+) Reviewed-by: Stefan Hajnoczi pgpS8uuDgammt.pgp Description: PGP signature

Re: [Qemu-devel] [PATCH v6 0/7] Virtio PCI libqos driver

2014-08-27 Thread Stefan Hajnoczi
On Mon, Aug 25, 2014 at 10:36:06AM +0200, Marc Marí wrote: > v3: Solved problems, added indirect descriptor support and test for > configuration changes > v4: Solved bugs, changed some interfaces, added MSI-X and event_idx support. > v5: Simplified virtio-blk-test, solved bugs, avoid patches al

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Eduardo Habkost
On Wed, Aug 27, 2014 at 03:36:51PM +0200, Paolo Bonzini wrote: > Il 26/08/2014 20:01, Eduardo Habkost ha scritto: > > On Tue, Aug 26, 2014 at 02:56:21PM +0200, Paolo Bonzini wrote: > >> Il 25/08/2014 22:45, Eduardo Habkost ha scritto: > >>> > >>> TCG users expect the default CPU model to contain mo

Re: [Qemu-devel] [PATCH v2] qcow2: Add bdrv_discard support

2014-08-27 Thread Stefan Hajnoczi
On Mon, Aug 25, 2014 at 12:38:06AM +0800, Jun Li wrote: > Why bdrv_discard does not yet pass the discard on to the underlying file > system driver? And this exist a potential issue: host cluster leak for > qcow2. As qcow2 image can be created on RAW disk, > so this is not just "does not yet pass th

Re: [Qemu-devel] [PATCH] blockdev: fix drive-mirror 'granularity' error message

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 14:29:59 (+0100), Stefan Hajnoczi wrote : > Name the 'granularity' parameter and give its expected value range. > Previously the device name was mistakingly reported as the parameter > name. > > Note that the error class is unchanged from ERROR_CLASS_GENERIC_ERROR. > >

Re: [Qemu-devel] [PATCH v2 1/6] qapi.py: avoid Python 2.5+ any() function

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 12:08:51 (+0100), Stefan Hajnoczi wrote : > There is one instance of any() in qapi.py that breaks builds on older > distros that ship Python 2.4 (like RHEL5): > > GEN qmp-commands.h > Traceback (most recent call last): > File "build/scripts/qapi-commands.py", line

Re: [Qemu-devel] [PATCH v2 3/6] trace: avoid Python 2.5 all() in tracetool

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 12:08:53 (+0100), Stefan Hajnoczi wrote : > Red Hat Enterprise Linux 5 ships Python 2.4.3. The all() function was > added in Python 2.5 so we cannot use it. > > Signed-off-by: Stefan Hajnoczi > --- > scripts/tracetool/backend/__init__.py | 3 ++- > 1 file changed, 2

Re: [Qemu-devel] [PATCH v2 4/6] mirror: fix uninitialized variable delay_ns warnings

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 12:08:54 (+0100), Stefan Hajnoczi wrote : > The gcc 4.1.2 compiler warns that delay_ns may be uninitialized in > mirror_iteration(). > > There are two break statements in the do ... while loop that skip over > the delay_ns assignment. These are probably the cause of th

[Qemu-devel] Some guest VCPUs are missing local timer interrupts upon migration

2014-08-27 Thread Rom Freiman
Hi, Im trying to migrate a VM (Ubuntu 14.04 which uses a tickless kernel) from node to node (2-4 vcpus, kvm is used), but once the VM is migrated, some of the VCPUs do not get local timer interrupts. Other interrupts are functional (cat /proc/interrupts). Which flow is in charge of "injecting" the

Re: [Qemu-devel] [RFC PATCH v2 13/13] spapr: Add pseries-2.2 machine with default "ddw" option

2014-08-27 Thread Alexey Kardashevskiy
On 08/27/2014 07:44 PM, Alexander Graf wrote: > > > On 15.08.14 12:12, Alexey Kardashevskiy wrote: >> This defines new "pseries" machine version which is capable of DDW >> (dynamic DMA windows) by default. >> >> Signed-off-by: Alexey Kardashevskiy > > This machine should also be the new default

Re: [Qemu-devel] [PATCH v2 5/6] block: sort formats alphabetically in bdrv_iterate_format()

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 12:08:55 (+0100), Stefan Hajnoczi wrote : > Format names are best consumed in alphabetical order. This makes > human-readable output easy to produce. > > bdrv_iterate_format() already has an array of format strings. Sort them > before invoking the iteration callback.

Re: [Qemu-devel] Using cache=writeback safely on qemu 1.4.0 and later

2014-08-27 Thread Andrew Martin
- Original Message - > From: "Paolo Bonzini" > To: "Andrew Martin" , "Stefan Hajnoczi" > > Cc: "qemu-devel" > Sent: Tuesday, August 26, 2014 2:03:18 AM > Subject: Re: Using cache=writeback safely on qemu 1.4.0 and later > > > In the case of the files uploaded by apache2, they were adde

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Liang, Kan
> > Dear KVM developers: > I am trying use perf stat inside a VM to obtain some hardware cache > performance counter values. > The perf stat can report some numbers for L1 and TLB related counters. But > for the LLC-loads and LLC-load-misses, the numbers are always 0. It seems > that the these o

Re: [Qemu-devel] [PATCH v5 0/8] modify boot order of guest, and take effect after rebooting

2014-08-27 Thread Gerd Hoffmann
Hi, > 1. Does have ready-to-wear interface to get QOM path by qdev id,? You can simply use the id directly. Try this: qemu-system-x86_64 \ -qmp unix:/tmp/qmp,server,nowait \ -device virtio-scsi-pci,id=scsi \ -drive if=none,id=cdrom,media=cdrom \ -device scsi-cd,id=testcd,drive=cdr

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Paolo Bonzini
Il 27/08/2014 16:05, Eduardo Habkost ha scritto: > On Wed, Aug 27, 2014 at 03:36:51PM +0200, Paolo Bonzini wrote: >> Il 26/08/2014 20:01, Eduardo Habkost ha scritto: >>> So maybe that's good news, as things can be simpler if we make both TCG >>> and KVM have similar behavior: >>> >>> * qemu64: a co

Re: [Qemu-devel] [PATCH] block: Introduce "null" driver

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 14:22:56 (+0800), Fam Zheng wrote : > This is an analogue to Linux null_blk. It can be used for testing block > device emulation and general block layer functionalities such as > coroutines and throttling, where disk IO is not necessary or wanted. > > Signed-off-by: Fam

Re: [Qemu-devel] Using cache=writeback safely on qemu 1.4.0 and later

2014-08-27 Thread Paolo Bonzini
Il 27/08/2014 16:23, Andrew Martin ha scritto: > Thanks for the info about this bug - I am using QEMU 1.4.0 (released on > 02/15/13) > and ef5bc96268 was added on 09/20/13, so the bug had not been fixed in the > version > of QEMU I am using. I have had trouble reproducing it on-demand - was there

Re: [Qemu-devel] [PATCH v2 6/6] Revert "qemu-img: sort block formats in help message"

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 12:08:56 (+0100), Stefan Hajnoczi wrote : > This reverts commit 1a443c1b8b4314d365e82bddeb1de5b4b1c15fb3 and the > later commit 395071a76328189f50c778f4dee6dabb90503dd9. > > GSequence was introduced in glib 2.14. RHEL 5 fails to compile since it > uses glib 2.12.3. >

Re: [Qemu-devel] [PATCH 3/4] quorum: Fix leak of opts in quorum_open

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 14:02:35 (+0800), Fam Zheng wrote : > Signed-off-by: Fam Zheng > --- > block/quorum.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/block/quorum.c b/block/quorum.c > index 0de07bb..ffe8bd9 100644 > --- a/block/quorum.c > +++ b/block/quorum

Re: [Qemu-devel] [PATCH 4/4] qcow2: Fix leak of opts in qcow2_open

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 14:02:36 (+0800), Fam Zheng wrote : > Not all the error paths release opts, fix it by moving it after the fail > label. > > Signed-off-by: Fam Zheng > --- > block/qcow2.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/block/qcow2.c b/bl

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Steven
Hi, Kan, Thanks for your reply. 1. If the guest is non-paravirt, can I get the LLC-loads number? 2. Do you know any method that can capture the LLC-loads for the guest? Thanks. - Hui On Wed, Aug 27, 2014 at 9:05 AM, Liang, Kan wrote: > > >> >> Dear KVM developers: >> I am trying use perf stat i

Re: [Qemu-devel] [PATCH 2/4] blkverify: Fix leak of opts in blkverify_open

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 14:02:34 (+0800), Fam Zheng wrote : > Signed-off-by: Fam Zheng > --- > block/blkverify.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/block/blkverify.c b/block/blkverify.c > index 7c78ca4..163064c 100644 > --- a/block/blkverify.c > +++ b/block/blkverify.c

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Steven
Hi, Kan, Thanks for your reply. 1. If the guest is non-paravirt, can I get the LLC-loads number? 2. Do you know any method that can capture the LLC-loads for the guest? Thanks. - Hui On Wed, Aug 27, 2014 at 9:05 AM, Liang, Kan wrote: > > > > > > > Dear KVM developers: > > I am trying use perf

Re: [Qemu-devel] [PATCH 1/4] nfs: Fix leak of opts in nfs_file_open

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 14:02:33 (+0800), Fam Zheng wrote : > Signed-off-by: Fam Zheng > --- > block/nfs.c | 7 +-- > 1 file changed, 5 insertions(+), 2 deletions(-) > > diff --git a/block/nfs.c b/block/nfs.c > index 93d87f3..36e8057 100644 > --- a/block/nfs.c > +++ b/block/nfs.c > @@ -3

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Steven
Hi, Kan, The dTLB-load-misses is 0, but it shows 80.00%hit, does that mean the TLB-load miss is 0.8 * (dTLB-loads). Thanks. Performance counter stats for './parsecmgmt -a run -i native -c gcc-hooks -n 1 -p freqmine': 0 dTLB-load-misses #0.00% of all dTLB cache hit

[Qemu-devel] block IO latency tracker without using QMP socket.

2014-08-27 Thread Anshul Makkar
Hi, I am writing a block IO latency tracker. As obvious, I am calculating the latency by tracking the interval between start of IO and end of IO. (firing my latency tracker from function BlockDriverAIOCB *raw_aio_submit() raw-posix.c when job is submitted). The latency data per QEMU process wil

Re: [Qemu-devel] glusterfs: do not log to stdout if daemonized

2014-08-27 Thread Stefan Hajnoczi
On Fri, Aug 22, 2014 at 11:57:18AM +, Dietmar Maurer wrote: > Else stdout is not closed correctly. glfs_set_logging(glfs, "-", 4) uses stderr, not stdout. The intention is to log errors along with QEMU's own error messages that go to stderr. Can you explain the details of the problem? pgpl

Re: [Qemu-devel] block IO latency tracker without using QMP socket.

2014-08-27 Thread Benoît Canet
The Wednesday 27 Aug 2014 à 16:58:12 (+0200), Anshul Makkar wrote : > Hi, > > I am writing a block IO latency tracker. > > As obvious, I am calculating the latency by tracking the interval between > start of IO and end of IO. > (firing my latency tracker from function BlockDriverAIOCB *raw_aio_s

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Eduardo Habkost
On Wed, Aug 27, 2014 at 04:33:54PM +0200, Paolo Bonzini wrote: > Il 27/08/2014 16:05, Eduardo Habkost ha scritto: > > On Wed, Aug 27, 2014 at 03:36:51PM +0200, Paolo Bonzini wrote: > >> Il 26/08/2014 20:01, Eduardo Habkost ha scritto: > >>> So maybe that's good news, as things can be simpler if we

Re: [Qemu-devel] [PATCH 09/12] rtl8139: adding new fields to vmstate

2014-08-27 Thread Paolo Bonzini
Il 27/08/2014 12:48, Pavel Dovgaluk ha scritto: >> From: Paolo Bonzini [mailto:pbonz...@redhat.com] >> Il 27/08/2014 12:30, Pavel Dovgaluk ha scritto: From: Paolo Bonzini [mailto:pbonz...@redhat.com] Il 27/08/2014 12:15, Pavel Dovgaluk ha scritto: >>> Again, this is only needed in you

Re: [Qemu-devel] [Qemu-stable] [PATCH] stream: fix the deadlock bug when stream finish

2014-08-27 Thread Michael Roth
Quoting Liu Yu (2014-08-22 22:43:00) > From: Liu Yu > > The patch against branch stable-2.0 Hi Liu, 2.0.2 was the last planned released for stable-2.0. Are you still seeing this issue with 2.1.0 or master? 2.1.1 is release is planned for September 9th so we can work on getting this included the

[Qemu-devel] [PATCH] mc146818rtc: reinitialize irq_reinject_on_ack_count on reset

2014-08-27 Thread Paolo Bonzini
This field was forgotten, and it makes the state after reset non-deterministic. Signed-off-by: Paolo Bonzini --- hw/timer/mc146818rtc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/timer/mc146818rtc.c b/hw/timer/mc146818rtc.c index 233fc70..4df650f 100644 --- a/hw/timer/mc146818rtc.c +

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Andreas Färber
Am 27.08.2014 17:42, schrieb Eduardo Habkost: > On Wed, Aug 27, 2014 at 04:33:54PM +0200, Paolo Bonzini wrote: >> Il 27/08/2014 16:05, Eduardo Habkost ha scritto: >>> On Wed, Aug 27, 2014 at 03:36:51PM +0200, Paolo Bonzini wrote: Il 26/08/2014 20:01, Eduardo Habkost ha scritto: > So maybe

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Eduardo Habkost
On Wed, Aug 27, 2014 at 05:58:49PM +0200, Andreas Färber wrote: > Am 27.08.2014 17:42, schrieb Eduardo Habkost: > > On Wed, Aug 27, 2014 at 04:33:54PM +0200, Paolo Bonzini wrote: > >> Il 27/08/2014 16:05, Eduardo Habkost ha scritto: > >>> On Wed, Aug 27, 2014 at 03:36:51PM +0200, Paolo Bonzini wrot

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Andreas Färber
Am 27.08.2014 18:08, schrieb Eduardo Habkost: > On Wed, Aug 27, 2014 at 05:58:49PM +0200, Andreas Färber wrote: >> Am 27.08.2014 17:42, schrieb Eduardo Habkost: >>> On Wed, Aug 27, 2014 at 04:33:54PM +0200, Paolo Bonzini wrote: Il 27/08/2014 16:05, Eduardo Habkost ha scritto: > On Wed, Aug

[Qemu-devel] [PATCH] spapr_pci: map the MSI window in each PHB

2014-08-27 Thread Greg Kurz
On sPAPR, virtio devices are connected to the PCI bus and use MSI-X. Commit cc943c36faa192cd4b32af8fe5edb31894017d35 has modified MSI-X so that writes are made using the bus master address space. Unfortunately, this address space does not have a MSI window: the notification is silently dropped in u

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Paolo Bonzini
Il 27/08/2014 18:08, Eduardo Habkost ha scritto: > > Might that be an opportunity to reconsider a -cpu best or so, > > independent of its implementation, to avoid "host"? Nowadays we have CPU models added way before silicon is available, and "-cpu host" in practice should be migratable (the big ex

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Liang, Kan
> > 1. If the guest is non-paravirt, can I get the LLC-loads number? No, the guest will crash. > 2. Do you know any method that can capture the LLC-loads for the guest? I don't know. > Thanks. >

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Liang, Kan
> > Hi, Kan, > > > > The dTLB-load-misses is 0, but it shows 80.00%hit, does that mean the > > TLB- load miss is 0.8 * (dTLB-loads). Thanks. > > > > Performance counter stats for './parsecmgmt -a run -i native -c > > gcc-hooks -n > > 1 -p freqmine': I'm not familiar with parsecmgmt. What’s

Re: [Qemu-devel] [Qemu-stable] [PATCH] stream: fix the deadlock bug when stream finish

2014-08-27 Thread Paolo Bonzini
Il 27/08/2014 17:53, Michael Roth ha scritto: >> In case VM does IO while we run a stream job. >> When stream finishes, the stream coroutine drains all IOs before >> close the unused image, in bdrv_drain_all() it may find >> a pending request which is submitted by guest IO coroutine. >> In order to

Re: [Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with "enforce" out of the box

2014-08-27 Thread Eduardo Habkost
On Wed, Aug 27, 2014 at 06:18:13PM +0200, Paolo Bonzini wrote: > Il 27/08/2014 18:08, Eduardo Habkost ha scritto: > > > Might that be an opportunity to reconsider a -cpu best or so, > > > independent of its implementation, to avoid "host"? > > Nowadays we have CPU models added way before silicon i

Re: [Qemu-devel] [PATCH] spapr_pci: map the MSI window in each PHB

2014-08-27 Thread Greg Kurz
On Wed, 27 Aug 2014 18:17:12 +0200 Greg Kurz wrote: > On sPAPR, virtio devices are connected to the PCI bus and use MSI-X. > Commit cc943c36faa192cd4b32af8fe5edb31894017d35 has modified MSI-X > so that writes are made using the bus master address space. ...and follow the IOMMU path. > Unfortuna

Re: [Qemu-devel] [Qemu-stable] [PATCH] stream: fix the deadlock bug when stream finish

2014-08-27 Thread Michael Roth
Quoting Paolo Bonzini (2014-08-27 11:28:23) > Il 27/08/2014 17:53, Michael Roth ha scritto: > >> In case VM does IO while we run a stream job. > >> When stream finishes, the stream coroutine drains all IOs before > >> close the unused image, in bdrv_drain_all() it may find > >> a pending request wh

[Qemu-devel] [PATCH] curl: Don't deref NULL pointer in call to aio_poll.

2014-08-27 Thread Richard W.M. Jones
Signed-off-by: Richard W.M. Jones --- block/curl.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/block/curl.c b/block/curl.c index 46f1082..8b69f28 100644 --- a/block/curl.c +++ b/block/curl.c @@ -355,7 +355,7 @@ static void curl_multi_timeout_do(void *arg) #endif

[Qemu-devel] [PATCH] curl: Don't deref NULL pointer in call to aio_poll.

2014-08-27 Thread Richard W.M. Jones
The original code in block/curl.c dereferences state *after* checking that it is NULL. That's obviously wrong, and indeed I can easily provoke a segfault when talking to a VMware vCenter server. I'm not as sure that this fix is the correct one, so please review it carefully. However it does at l

[Qemu-devel] Patch Round-up for stable 2.1.1, freeze on 2014-09-03

2014-08-27 Thread Michael Roth
Hi everyone, The following new patches are queued for QEMU stable v2.1.1: https://github.com/mdroth/qemu/commits/stable-2.1-staging The release is planned for 2014-09-08: http://wiki.qemu.org/Planning/2.1 Please respond here or CC qemu-sta...@nongnu.org on any patches you think should be i

[Qemu-devel] [PATCH 02/25] qdev-monitor: include QOM properties in -device FOO, help output

2014-08-27 Thread Michael Roth
From: Stefan Hajnoczi Update -device FOO,help to include QOM properties in addition to qdev properties. Devices are gradually adding more QOM properties that are not reflected as qdev properties. It is important to report all device properties since management tools like libvirt use this inform

[Qemu-devel] [PATCH 07/25] hw:i386: typo fix: MEMORY_HOPTLUG_DEVICE -> MEMORY_HOTPLUG_DEVICE

2014-08-27 Thread Michael Roth
From: Hu Tao Cc: qemu-sta...@nongnu.org Signed-off-by: Hu Tao Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin (cherry picked from commit 41d2f71376fe401a1fdb7deda023769207511790) Signed-off-by: Michael Roth --- hw/i386/acpi-dsdt.dsl | 4 ++-- hw/i386/acpi-dsdt.he

[Qemu-devel] [PATCH 08/25] pc-dimm: validate node property

2014-08-27 Thread Michael Roth
From: Hu Tao If user specifies a node number that exceeds the available numa nodes in emulated system for pc-dimm device, the device will report an invalid _PXM to OSPM. Fix this by checking the node property value. Cc: qemu-sta...@nongnu.org Signed-off-by: Hu Tao Reviewed-by: Michael S. Tsirki

[Qemu-devel] [PATCH 03/25] vfio: Fix MSI-X vector expansion

2014-08-27 Thread Michael Roth
From: Alex Williamson When new MSI-X vectors are enabled we need to disable MSI-X and re-enable it with the correct number of vectors. That means we need to reprogram the eventfd triggers for each vector. Prior to f4d45d47 vector->use tracked whether a vector was masked or unmasked and we could

[Qemu-devel] [PATCH 06/25] pci: Use bus master address space for delivering MSI/MSI-X messages

2014-08-27 Thread Michael Roth
From: Jan Kiszka The spec says (and real HW confirms this) that, if the bus master bit is 0, the device will not generate any PCI accesses. MSI and MSI-X messages fall among these, so we should use the corresponding address space to deliver them. This will prevent delivery if bus master support i

[Qemu-devel] [PATCH 05/25] ide: only constrain read/write requests to drive size, not other types

2014-08-27 Thread Michael Roth
From: Michael Tokarev Commit 58ac321135a introduced a check to ide dma processing which constrains all requests to drive size. However, apparently, some valid requests (like TRIM) does not fit in this constraint, and fails in 2.1. So check the range only for reads and writes. Cc: qemu-sta...@n

[Qemu-devel] [PATCH 12/25] virtio-blk: fix reference a pointer which might be freed

2014-08-27 Thread Michael Roth
From: zhanghailiang In function virtio_blk_handle_request, it may freed memory pointed by req, So do not access member of req after calling this function. Cc: qemu-sta...@nongnu.org Reviewed-by: Michael S. Tsirkin Reviewed-by: Stefan Hajnoczi Signed-off-by: zhanghailiang Signed-off-by: Kevin

[Qemu-devel] [PATCH 04/25] l2tpv3 (configure): it is linux-specific

2014-08-27 Thread Michael Roth
From: Michael Tokarev Some non-linux systems, for example a system with FreeBSD kernel and glibc, may declare struct mmsghdr (in glibc) but may not have linux-specific header file linux/ip.h. The actual implementation in qemu includes this linux-specific header file unconditionally, so compilati

[Qemu-devel] [PATCH 13/25] target-arm: Fix return address for A64 BRK instructions

2014-08-27 Thread Michael Roth
From: Peter Maydell When we take an exception resulting from a BRK instruction, the architecture requires that the "preferred return address" reported to the exception handler is the address of the BRK itself, not the following instruction (like undefined insns, and in contrast with SVC, HVC and

[Qemu-devel] [PATCH 01/25] qmp: hide "hotplugged" device property from device-list-properties

2014-08-27 Thread Michael Roth
From: Stefan Hajnoczi The "hotplugged" device property was not reported before commit f4eb32b590bf58c1c67570775eb78beb09964fad ("qmp: show QOM properties in device-list-properties"). Fix this difference. Signed-off-by: Stefan Hajnoczi Reviewed-by: Eric Blake (cherry picked from commit 4115dd6

[Qemu-devel] [PATCH 10/25] numa: show hex number in error message for consistency and prefix them with 0x

2014-08-27 Thread Michael Roth
From: Hu Tao The error messages before and after patch are: before: qemu-system-x86_64: total memory for NUMA nodes (134217728) should equal RAM size (2000) after: qemu-system-x86_64: total memory for NUMA nodes (0x800) should equal RAM size (0x2000) Cc: qemu-sta...@nongnu.org Si

[Qemu-devel] [PATCH 11/25] acpi: align RSDP

2014-08-27 Thread Michael Roth
From: "Michael S. Tsirkin" RSDP should be aligned at a 16-byte boundary. This would by chance at the moment, fix up acpi build to make it robust. Cc: qemu-sta...@nongnu.org Signed-off-by: Michael S. Tsirkin Reviewed-by: Laszlo Ersek (cherry picked from commit d67aadccfa0bd3330a7b8e7e0a1726117b

[Qemu-devel] [PATCH 17/25] raw-posix: fix O_DIRECT short reads

2014-08-27 Thread Michael Roth
From: Stefan Hajnoczi The following O_DIRECT read from a <512 byte file fails: $ truncate -s 320 test.img $ qemu-io -n -c 'read -P 0 0 512' test.img qemu-io: can't open device test.img: Could not read image for determining its format: Invalid argument Note that qemu-io completes successf

[Qemu-devel] [PATCH 21/25] hostmem: set MPOL_MF_MOVE

2014-08-27 Thread Michael Roth
From: "Michael S. Tsirkin" When memory is allocated on a wrong node, MPOL_MF_STRICT doesn't move it - it just fails the allocation. A simple way to reproduce the failure is with mlock=on realtime feature. The code comment actually says: "ensure policy won't be ignored" so setting MPOL_MF_MOVE se

[Qemu-devel] [PATCH 09/25] pc-dimm: fix up error message

2014-08-27 Thread Michael Roth
From: "Michael S. Tsirkin" - int should be printed using %d - print actual wrong value for property Cc: qemu-sta...@nongnu.org Signed-off-by: Michael S. Tsirkin (cherry picked from commit 988eba0f681bd4f82e9e02998da8106f165ed82c) Signed-off-by: Michael Roth --- hw/mem/pc-dimm.c | 5 +++-- 1 f

[Qemu-devel] [PATCH 15/25] arm/virt: Use PSCI v0.2 function IDs in the DT when KVM uses PSCI v0.2

2014-08-27 Thread Michael Roth
From: Christoffer Dall The current code supplies the PSCI v0.1 function IDs in the DT even when KVM uses PSCI v0.2. This will break guest kernels that only support PSCI v0.1 as they will use the IDs provided in the DT. Guest kernels with PSCI v0.2 support are not affected by this patch, because

[Qemu-devel] [PATCH 16/25] block/iscsi: fix memory corruption on iscsi resize

2014-08-27 Thread Michael Roth
From: Peter Lieven bs->total_sectors is not yet updated at this point. resulting in memory corruption if the volume has grown and data is written to the newly availble areas. CC: qemu-sta...@nongnu.org Signed-off-by: Peter Lieven Signed-off-by: Kevin Wolf (cherry picked from commit d832fb4d66e

[Qemu-devel] [PATCH 19/25] blkdebug: Delete BH in bdrv_aio_cancel

2014-08-27 Thread Michael Roth
From: Fam Zheng Otherwise error_callback_bh will access the already released acb. Cc: qemu-sta...@nongnu.org Signed-off-by: Fam Zheng Signed-off-by: Kevin Wolf (cherry picked from commit cbf95a0b117461473f05ab3cce4d01ba2b29e60a) Signed-off-by: Michael Roth --- block/blkdebug.c | 4 1 fi

Re: [Qemu-devel] [PATCH 4/4] qcow2: Fix leak of opts in qcow2_open

2014-08-27 Thread Max Reitz
On 27.08.2014 08:02, Fam Zheng wrote: Not all the error paths release opts, fix it by moving it after the fail label. Signed-off-by: Fam Zheng --- block/qcow2.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) This is pretty much the same patch as 'qcow2: Fix leak of QemuOpts in

[Qemu-devel] [PATCH 23/25] pc: reserve more memory for ACPI for new machine types

2014-08-27 Thread Michael Roth
From: "Michael S. Tsirkin" commit 868270f23d8db2cce83e4f082fe75e8625a5fbf9 acpi-build: tweak acpi migration limits broke kernel loading with -kernel/-initrd: it doubled the size of ACPI tables but did not reserve enough memory. As a result, issues on boot and halt are observed. Fix this up

[Qemu-devel] [PATCH 18/25] qemu-iotests: add test case 101 for short file I/O

2014-08-27 Thread Michael Roth
From: Stefan Hajnoczi Signed-off-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf (cherry picked from commit 8d9eb33ca0bbb8bca0f1775623ed3cf5f39760cd) Conflicts: tests/qemu-iotests/group *fix up context mismatches due to lack of 099 and 103 tests Signed-off-by: Michael Roth --- tests/

[Qemu-devel] [PATCH 24/25] thread-pool: avoid per-thread-pool EventNotifier

2014-08-27 Thread Michael Roth
From: Stefan Hajnoczi EventNotifier is implemented using an eventfd or pipe. It therefore consumes file descriptors, which can be limited by rlimits and should therefore be used sparingly. Switch from EventNotifier to QEMUBH in thread-pool.c. Originally EventNotifier was used because qemu_bh_s

[Qemu-devel] [PATCH 20/25] vmxnet3: Pad short frames to minimum size (60 bytes)

2014-08-27 Thread Michael Roth
From: Ben Draper When running VMware ESXi under qemu-kvm the guest discards frames that are too short. Short ARP Requests will be dropped, this prevents guests on the same bridge as VMware ESXi from communicating. This patch simply adds the padding on the network device itself. Signed-off-by: Be

[Qemu-devel] [PATCH 14/25] target-arm: Rename QEMU PSCI v0.1 definitions

2014-08-27 Thread Michael Roth
From: Christoffer Dall The function IDs for PSCI v0.1 are exported by KVM and defined as KVM_PSCI_FN_. To build using these defines in non-KVM code, QEMU defines these IDs locally and check their correctness against the KVM headers when those are available. However, the naming scheme used for Q

[Qemu-devel] [PATCH 25/25] thread-pool: avoid deadlock in nested aio_poll() calls

2014-08-27 Thread Michael Roth
From: Stefan Hajnoczi The thread pool has a race condition if two elements complete before thread_pool_completion_bh() runs: If element A's callback waits for element B using aio_poll() it will deadlock since pool->completion_bh is not marked scheduled when the nested aio_poll() runs. Fix

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Steven
Inside the guest, I am using "perf stat -e dTLB-load-misses -e dTLB-loads -e L1-dcache-loads -e L1-dcache-load-misses -e L1-dcache-prefetch-misses ", followed by the parsec command. Thanks. - Hui On Wed, Aug 27, 2014 at 12:28 PM, Liang, Kan wrote: > >> > Hi, Kan, >> > >> > The dTLB-load-misses

[Qemu-devel] [PATCH 1/1] Support ppc64le binfmt registration

2014-08-27 Thread Serge E. Hallyn
This is a part of a patch proposed by jaejunh at https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1358268 which enables running ppc64le binaries through qemu-user. Not sure if it's the right way to do it, but it does allow me to chroot into a ppc64el rootfs on amd64 host. Signed-off-by: Serge

Re: [Qemu-devel] [PATCH 1/1] Support ppc64le binfmt registration

2014-08-27 Thread Peter Maydell
On 27 August 2014 18:55, Serge E. Hallyn wrote: > This is a part of a patch proposed by jaejunh at > https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1358268 > which enables running ppc64le binaries through qemu-user. I'm confused -- wouldn't these be handled by the existing "ppc64le" support?

Re: [Qemu-devel] [PATCH v3 07/10] qcow2: Rebuild refcount structure during check

2014-08-27 Thread Max Reitz
On 25.08.2014 19:40, Benoît Canet wrote: On Fri, Aug 22, 2014 at 06:31:41PM +0200, Max Reitz wrote: The previous commit introduced the "rebuild" variable to qcow2's implementation of the image consistency check. Now make use of this by adding a function which creates a completely new refcount st

Re: [Qemu-devel] [PATCH 1/1] Support ppc64le binfmt registration

2014-08-27 Thread Serge E. Hallyn
Quoting Peter Maydell (peter.mayd...@linaro.org): > On 27 August 2014 18:55, Serge E. Hallyn wrote: > > This is a part of a patch proposed by jaejunh at > > https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1358268 > > which enables running ppc64le binaries through qemu-user. > > I'm confused -

Re: [Qemu-devel] Using cache=writeback safely on qemu 1.4.0 and later

2014-08-27 Thread Andrew Martin
- Original Message - > From: "Paolo Bonzini" > To: "Andrew Martin" > Cc: "Stefan Hajnoczi" , "qemu-devel" > > Sent: Wednesday, August 27, 2014 9:34:27 AM > Subject: Re: Using cache=writeback safely on qemu 1.4.0 and later > > Il 27/08/2014 16:23, Andrew Martin ha scritto: > > Thanks fo

Re: [Qemu-devel] [PATCH 1/1] Support ppc64le binfmt registration

2014-08-27 Thread Peter Maydell
[adding qemu-ppc] On 27 August 2014 19:45, Serge E. Hallyn wrote: > Quoting Peter Maydell (peter.mayd...@linaro.org): >> On 27 August 2014 18:55, Serge E. Hallyn wrote: >> > This is a part of a patch proposed by jaejunh at >> > https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1358268 >> > whi

[Qemu-devel] Suspend/Hibernation support status in RHEL7

2014-08-27 Thread Luiz Capitulino
Hi, After having debugged a hibernation BZ reported by QE, I got confused about the support status of suspend/hibernate in RHEL7. What I had in mind was that S3 was supported but S4 was not. Amit confirmed that S4 is not supported in RHEL7, but: 1. We document, or at least imply, that both S3 a

Re: [Qemu-devel] Suspend/Hibernation support status in RHEL7

2014-08-27 Thread Luiz Capitulino
On Wed, 27 Aug 2014 15:07:48 -0400 Luiz Capitulino wrote: > Hi, > > After having debugged a hibernation BZ reported by QE, I got confused > about the support status of suspend/hibernate in RHEL7. Please, disregard. Internal email :(

Re: [Qemu-devel] pert stat in KVM guest can not get LLC-loads hardware cache event

2014-08-27 Thread Liang, Kan
> > Inside the guest, I am using "perf stat -e dTLB-load-misses -e > > dTLB-loads -e L1-dcache-loads -e L1-dcache-load-misses -e > > L1-dcache-prefetch-misses ", followed by the parsec command. > > The misses/hit radio is the first number after "#". For your case, 0.00% is the misses/hit radi

[Qemu-devel] [BUG] Guest freezes when resuming from S3

2014-08-27 Thread Luiz Capitulino
Hi, I won't have time to keep debugging this so I'll just report what I have. The basic problem is: you suspend a Linux guest to RAM, and the screen (or maybe the guest) freezes when resuming. Here's some debugging info: v1.6.0: last fully working version v1.7.0: doesn't exactly freeze, but the

[Qemu-devel] [PATCH v4 01/10] qcow2: Fix leaks in dirty images

2014-08-27 Thread Max Reitz
When opening dirty images, qcow2's repair function should not only repair errors but leaks as well. Signed-off-by: Max Reitz Reviewed-by: Eric Blake Reviewed-by: Benoît Canet --- block/qcow2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/qcow2.c b/block/qcow2.c ind

[Qemu-devel] [PATCH v4 02/10] qcow2: Split qcow2_check_refcounts()

2014-08-27 Thread Max Reitz
Put the code for calculating the reference counts and comparing them during qemu-img check into own functions. Signed-off-by: Max Reitz Reviewed-by: Benoît Canet --- block/qcow2-refcount.c | 153 - 1 file changed, 102 insertions(+), 51 deletions(-

[Qemu-devel] [PATCH v4 00/10] qcow2: Fix image repairing

2014-08-27 Thread Max Reitz
As can be seen in the final patch of this series, there are certain cases where the current repair implementation of qcow2 actually damages the image further because it allocates new clusters for the refcount structure which overlap with existing but according to the on-disk refcounts (which are as

[Qemu-devel] [PATCH v4 04/10] qcow2: Reuse refcount table in calculate_refcounts()

2014-08-27 Thread Max Reitz
We will later call calculate_refcounts multiple times, so reuse the refcount table if possible. Signed-off-by: Max Reitz Reviewed-by: Benoît Canet --- block/qcow2-refcount.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/block/qcow2-refcount.c b/block/qcow2-ref

[Qemu-devel] [PATCH v4 03/10] qcow2: Pull check_refblocks() up

2014-08-27 Thread Max Reitz
Pull check_refblocks() before calculate_refcounts() so we can drop its static declaration. Signed-off-by: Max Reitz Reviewed-by: Benoît Canet --- block/qcow2-refcount.c | 102 - 1 file changed, 49 insertions(+), 53 deletions(-) diff --git a/block

[Qemu-devel] [PATCH v4 05/10] qcow2: Fix refcount blocks beyond image end

2014-08-27 Thread Max Reitz
If the qcow2 check function detects a refcount block located beyond the image end, grow the image appropriately. This cannot break anything and is the logical fix for such a case. Signed-off-by: Max Reitz --- block/qcow2-refcount.c | 62 ++ 1 file

[Qemu-devel] [PATCH v4 09/10] iotests: Fix test outputs

2014-08-27 Thread Max Reitz
039, 060 and 061 all create images with referenced clusters having a refcount of 0. Because previous commits changed handling of such errors, these tests now have a different output. Fix it. Furthermore, 060 created a refblock with a refcount greater than one which now results in having to rebuild

[Qemu-devel] [PATCH v4 10/10] iotests: Add test for potentially damaging repairs

2014-08-27 Thread Max Reitz
There are certain cases where repairing a qcow2 image might actually damage it further (or rather, where repairing it has in fact damaged it further with the old qcow2 check implementation). This should not happen, so add a test for these cases. Furthermore, the repair function now repairs refbloc

[Qemu-devel] [PATCH v4 06/10] qcow2: Do not perform potentially damaging repairs

2014-08-27 Thread Max Reitz
If a referenced cluster has a refcount of 0, increasing its refcount may result in clusters being allocated for the refcount structures. This may overwrite the referenced cluster, therefore we cannot simply increase the refcount then. In such cases, we can either try to replicate all the refcount

[Qemu-devel] [PATCH v4 07/10] qcow2: Rebuild refcount structure during check

2014-08-27 Thread Max Reitz
The previous commit introduced the "rebuild" variable to qcow2's implementation of the image consistency check. Now make use of this by adding a function which creates a completely new refcount structure based solely on the in-memory information gathered before. The old refcount structure will be

[Qemu-devel] [PATCH v4 08/10] qcow2: Clean up after refcount rebuild

2014-08-27 Thread Max Reitz
Because the old refcount structure will be leaked after having rebuilt it, we need to recalculate the refcounts and run a leak-fixing operation afterwards (if leaks should be fixed at all). Signed-off-by: Max Reitz Reviewed-by: Benoît Canet --- block/qcow2-refcount.c | 35 ++

<    1   2   3   >