Re: [Qemu-devel] [PATCH 10/16] qapi: Use qapi_enum_parse() in input_type_enum()

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 10:46 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster Reviewed-by: Marc-André Lureau > --- > qapi/qapi-visit-core.c | 13 - > 1 file changed, 4 insertions(+), 9 deletions(-) > > diff --git a/qapi/qapi-visit-core.c b/qapi/qapi-visit-core.c >

Re: [Qemu-devel] [PATCH 11/16] qapi: Avoid unnecessary use of enum lookup table's sentinel

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 10:46 AM, Markus Armbruster wrote: > Currently, the FOO_lookup[] generated for QAPI enum types are > terminated by a NULL sentinel. > > A future patch will generate enums with "holes". NULL-termination > will cease to work then. > > To prepare for that, replace "have we re

Re: [Qemu-devel] [PATCH 13/16] qapi: Mechanically convert FOO_lookup[...] to FOO_str(...)

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 10:46 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster Looks like you got them all! Reviewed-by: Marc-André Lureau > --- > backends/hostmem.c | 2 +- > block/backup.c | 2 +- > block/file-posix.c

[Qemu-devel] [PATCH for-2.11] s390x/s390-stattrib: Mark the storage attribute as not user_creatable

2017-08-24 Thread Thomas Huth
The storage attribute devices are only meant to be instantiated one time, internally. They can not be used by the user, so mark them with user_creatable = false. Suggested-by: Claudio Imbrenda Signed-off-by: Thomas Huth --- hw/s390x/s390-stattrib-kvm.c | 4 hw/s390x/s390-stattrib.c | 4

Re: [Qemu-devel] [PATCH 14/16] qapi: Convert indirect uses of FOO_lookup[...] to qapi_enum_lookup()

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 10:46 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster Reviewed-by: Marc-André Lureau > --- > hw/core/qdev-properties.c | 7 +-- > qapi/qapi-visit-core.c| 2 +- > 2 files changed, 6 insertions(+), 3 deletions(-) > > diff --git a/hw/core/qdev-pro

[Qemu-devel] [PATCH 2/3] qapi-schema: Introspection doc is in the wrong section, fix

2017-08-24 Thread Markus Armbruster
Bug: introspection documentation is in section "Tracing commands". Cause: sub-schema qapi/introspect.json lacks a section header, and therefore goes into whatever section precedes its include. Fix: add a section header. Signed-off-by: Markus Armbruster --- qapi/introspect.json | 6 -- 1 fi

[Qemu-devel] [PATCH 0/3] qapi-schema: Generated doc structure fixes

2017-08-24 Thread Markus Armbruster
Markus Armbruster (3): qapi-schema: Document how generated documentation is ordered qapi-schema: Introspection doc is in the wrong section, fix qapi-schema: Rocker doc section contains unrelated stuff, fix qapi-schema.json | 21 +++-- qapi/introspect.json | 6 -- 2

[Qemu-devel] [PATCH 1/3] qapi-schema: Document how generated documentation is ordered

2017-08-24 Thread Markus Armbruster
Documentation generated with qapi2texi.py is in textual order, with included sub-schemas inserted at the first include directive (subsequent include directives have no effect). To get a sane and stable order, it's best to include each sub-schema just once, or include it first in qapi-schema.json.

[Qemu-devel] [PATCH 3/3] qapi-schema: Rocker doc section contains unrelated stuff, fix

2017-08-24 Thread Markus Armbruster
Bug: section "Rocker switch device" starts with the rocker stuff, but then has unrelated stuff, like ReplayMode, xen-load-devices-state, ... Cause: rocker.json is included in the middle of section "QMP commands". Fix: include it in a sane place, namely next to the other sub-schemas. Signed-off-b

[Qemu-devel] [PATCH v8 3/6] block: tidy ThrottleGroupMember initializations

2017-08-24 Thread Manos Pitsidianakis
Move the CoMutex and CoQueue inits inside throttle_group_register_tgm() which is called whenever a ThrottleGroupMember is initialized. There's no need for them to be separate. Reviewed-by: Alberto Garcia Reviewed-by: Stefan Hajnoczi Signed-off-by: Manos Pitsidianakis --- block/block-backend.c

[Qemu-devel] [PATCH v8 1/6] block: move ThrottleGroup membership to ThrottleGroupMember

2017-08-24 Thread Manos Pitsidianakis
This commit eliminates the 1:1 relationship between BlockBackend and throttle group state. Users will be able to create multiple throttle nodes, each with its own throttle group state, in the future. The throttle group state cannot be per-BlockBackend anymore, it must be per-throttle node. This i

[Qemu-devel] [PATCH v8 2/6] block: add aio_context field in ThrottleGroupMember

2017-08-24 Thread Manos Pitsidianakis
timer_cb() needs to know about the current Aio context of the throttle request that is woken up. In order to make ThrottleGroupMember backend agnostic, this information is stored in an aio_context field instead of accessing it from BlockBackend. Reviewed-by: Alberto Garcia Reviewed-by: Stefan Haj

[Qemu-devel] [PATCH v8 5/6] block: add throttle block filter driver

2017-08-24 Thread Manos Pitsidianakis
block/throttle.c uses existing I/O throttle infrastructure inside a block filter driver. I/O operations are intercepted in the filter's read/write coroutines, and referred to block/throttle-groups.c The driver can be used with the syntax -drive driver=throttle,file.filename=foo.qcow2,throttle-grou

[Qemu-devel] [PATCH v8 4/6] block: convert ThrottleGroup to object with QOM

2017-08-24 Thread Manos Pitsidianakis
ThrottleGroup is converted to an object. This will allow the future throttle block filter drive easy creation and configuration of throttle groups in QMP and cli. A new QAPI struct, ThrottleLimits, is introduced to provide a shared struct for all throttle configuration needs in QMP. ThrottleGroup

[Qemu-devel] [PATCH v8 0/6] add throttle block driver filter

2017-08-24 Thread Manos Pitsidianakis
This series adds a throttle block driver filter. Currently throttling is done at the BlockBackend level. Using block driver interfaces we can move the throttling to any point in the BDS graph using a throttle node which uses the existing throttling code. This allows for potentially more complex con

[Qemu-devel] [PATCH v8 6/6] qemu-iotests: add 184 for throttle filter driver

2017-08-24 Thread Manos Pitsidianakis
Reviewed-by: Alberto Garcia Signed-off-by: Manos Pitsidianakis --- tests/qemu-iotests/184 | 205 +++ tests/qemu-iotests/184.out | 300 + tests/qemu-iotests/group | 1 + 3 files changed, 506 insertions(+) create mode

Re: [Qemu-devel] [Qemu-block] [PATCH v5 08/13] tests: Rely more on global_qtest

2017-08-24 Thread Markus Armbruster
Paolo Bonzini writes: > On 24/08/2017 12:09, Markus Armbruster wrote: >> Cut-and-paste cuts both ways (pardon the pun): >> >> initialize with QTestState A >> frobnicate with QTestState A >> glomnify with QTestState A >> frobnicate with QTestState A >> initialize with QTestSta

Re: [Qemu-devel] [PATCH 2/3] qapi-schema: Introspection doc is in the wrong section, fix

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 2:02 PM, Markus Armbruster wrote: > Bug: introspection documentation is in section "Tracing commands". > > Cause: sub-schema qapi/introspect.json lacks a section header, and > therefore goes into whatever section precedes its include. > > Fix: add a section header. > > Sign

Re: [Qemu-devel] [PATCH v3 for-2.11 08/18] target/s390x: move gtod_*() declarations to s390-virtio.h

2017-08-24 Thread Cornelia Huck
On Fri, 18 Aug 2017 19:28:31 +0200 David Hildenbrand wrote: > On 18.08.2017 18:11, Thomas Huth wrote: > > Suggesting to add a patch description like: "The functions are not used > > in target/s390x/ so a header in hw/s390x/ is a better place" ? > > Sure, I will include that, thanks! No worrie

Re: [Qemu-devel] [PATCH 3/3] qapi-schema: Rocker doc section contains unrelated stuff, fix

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 2:02 PM, Markus Armbruster wrote: > Bug: section "Rocker switch device" starts with the rocker stuff, but > then has unrelated stuff, like ReplayMode, xen-load-devices-state, ... > > Cause: rocker.json is included in the middle of section "QMP commands". > > Fix: include it

[Qemu-devel] Structure / order of generated QAPI/QMP docs

2017-08-24 Thread Markus Armbruster
We've split sub-schemas off qapi-schema.json to enable proper MAINTAINERS coverage, and also because the complete schema has become rather large. The reference documentation generated with qapi2texi.py is in textual schema order, with included sub-schemas inserted at the first include directive (s

Re: [Qemu-devel] [PATCH 1/3] qapi-schema: Document how generated documentation is ordered

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 2:02 PM, Markus Armbruster wrote: > Documentation generated with qapi2texi.py is in textual order, with > included sub-schemas inserted at the first include directive > (subsequent include directives have no effect). To get a sane and > stable order, it's best to include e

Re: [Qemu-devel] [PATCH 3/3] qapi-schema: Rocker doc section contains unrelated stuff, fix

2017-08-24 Thread Marc-André Lureau
On Thu, Aug 24, 2017 at 2:02 PM, Markus Armbruster wrote: > Bug: section "Rocker switch device" starts with the rocker stuff, but > then has unrelated stuff, like ReplayMode, xen-load-devices-state, ... > > Cause: rocker.json is included in the middle of section "QMP commands". > > Fix: include it

Re: [Qemu-devel] [PATCH for-2.11] s390x/s390-stattrib: Mark the storage attribute as not user_creatable

2017-08-24 Thread Claudio Imbrenda
On Thu, 24 Aug 2017 14:00:29 +0200 Thomas Huth wrote: > The storage attribute devices are only meant to be instantiated one > time, internally. They can not be used by the user, so mark them with > user_creatable = false. > > Suggested-by: Claudio Imbrenda > Signed-off-by: Thomas Huth Reviewe

Re: [Qemu-devel] [PATCH v6 00/10] qemu.py: Pylint/style fixes

2017-08-24 Thread Stefan Hajnoczi
On Tue, Aug 22, 2017 at 04:07:09PM -0300, Eduardo Habkost wrote: > (CCing Cleber and Stefan) > > On Tue, Aug 22, 2017 at 07:19:45AM -0300, Philippe Mathieu-Daudé wrote: > [...] > > Can we predict how the python scripts will evolve? Only fast-testing? > > > > I guess it depends on how you define

[Qemu-devel] [PATCH QEMU v2] xen/pt: allow QEMU to request MSI unmasking at bind time

2017-08-24 Thread Roger Pau Monne
When a MSI interrupt is bound to a guest using xc_domain_update_msi_irq (XEN_DOMCTL_bind_pt_irq) the interrupt is left masked by default. This causes problems with guests that first configure interrupts and clean the per-entry MSIX table mask bit and afterwards enable MSIX globally. In such scenar

Re: [Qemu-devel] [PATCH for-2.11] s390x/s390-stattrib: Mark the storage attribute as not user_creatable

2017-08-24 Thread Halil Pasic
On 08/24/2017 02:00 PM, Thomas Huth wrote: > The storage attribute devices are only meant to be instantiated one > time, internally. They can not be used by the user, so mark them with > user_creatable = false. > > Suggested-by: Claudio Imbrenda > Signed-off-by: Thomas Huth Reviewed-by: Hali

Re: [Qemu-devel] [PATCH for-2.11] hw/nvram/spapr_nvram: Device can not be created by the users

2017-08-24 Thread David Gibson
On Thu, Aug 24, 2017 at 09:41:33AM +0200, Thomas Huth wrote: > Trying to add a spapr-nvram device currently aborts QEMU like this: > > $ ppc64-softmmu/qemu-system-ppc64 -device spapr-nvram > qemu-system-ppc64: hw/ppc/spapr_rtas.c:407: spapr_rtas_register: > Assertion `!rtas_table[token].name' fa

Re: [Qemu-devel] Memory use with >100 virtio devices

2017-08-24 Thread David Gibson
On Thu, Aug 24, 2017 at 07:48:57PM +1000, Alexey Kardashevskiy wrote: > On 21/08/17 15:50, Alexey Kardashevskiy wrote: > > On 21/08/17 14:31, David Gibson wrote: > >> On Fri, Aug 18, 2017 at 02:18:53PM +0100, Stefan Hajnoczi wrote: > >>> On Fri, Aug 18, 2017 at 03:39:20PM +1000, Alexey Kardashevski

Re: [Qemu-devel] [PATCH v3 for-2.11 00/18] target/s390x: cleanup cpu.h

2017-08-24 Thread Cornelia Huck
On Fri, 18 Aug 2017 13:43:35 +0200 David Hildenbrand wrote: > ... now featuring even more cleanups. > > cpu.h is accessed outside of target/s390x. It should only contain > what is expected to be accessed outside of this folder. Therefore, create > internal.h and move a lot to that file. In addit

Re: [Qemu-devel] [PATCH v4 2/2] ACPI/unit-test: Add a new testcase for RAM allocation in numa node

2017-08-24 Thread Igor Mammedov
On Thu, 24 Aug 2017 09:42:28 +0800 Dou Liyang wrote: > Hi Igor, > > At 08/24/2017 01:47 AM, Igor Mammedov wrote: > > On Wed, 23 Aug 2017 21:35:29 +0800 > > Dou Liyang wrote: > > > >> Hi Igor, > >> > >> At 08/23/2017 08:45 PM, Igor Mammedov wrote: > >>> On Wed, 23 Aug 2017 20:12:51 +0800 > >

Re: [Qemu-devel] [PATCH v11 1/6] ACPI: add APEI/HEST/CPER structures and macros

2017-08-24 Thread Shannon Zhao
On 2017/8/18 22:23, Dongjiu Geng wrote: > (1) Add related APEI/HEST table structures and macros, these > definition refer to ACPI 6.1 and UEFI 2.6 spec. > (2) Add generic error status block and CPER memory section > definition, user space only handle memory section errors. > > Signed-of

Re: [Qemu-devel] [PATCH v6 00/10] qemu.py: Pylint/style fixes

2017-08-24 Thread Philippe Mathieu-Daudé
On 08/24/2017 09:15 AM, Stefan Hajnoczi wrote: On Tue, Aug 22, 2017 at 04:07:09PM -0300, Eduardo Habkost wrote: (CCing Cleber and Stefan) On Tue, Aug 22, 2017 at 07:19:45AM -0300, Philippe Mathieu-Daudé wrote: [...] Can we predict how the python scripts will evolve? Only fast-testing? I gue

Re: [Qemu-devel] [PATCH for-2.11] s390x/s390-stattrib: Mark the storage attribute as not user_creatable

2017-08-24 Thread Cornelia Huck
On Thu, 24 Aug 2017 14:00:29 +0200 Thomas Huth wrote: > The storage attribute devices are only meant to be instantiated one > time, internally. They can not be used by the user, so mark them with > user_creatable = false. > > Suggested-by: Claudio Imbrenda > Signed-off-by: Thomas Huth > --- >

Re: [Qemu-devel] [PATCH v11 2/6] ACPI: Add APEI GHES Table Generation support

2017-08-24 Thread Shannon Zhao
On 2017/8/18 22:23, Dongjiu Geng wrote: > This implements APEI GHES Table by passing the error CPER info > to the guest via a fw_cfg_blob. After a CPER info is recorded, an > SEA(Synchronous External Abort)/SEI(SError Interrupt) exception > will be injected into the guest OS. > > Below is the ta

Re: [Qemu-devel] [PATCH v11 3/6] ACPI: build and enable APEI GHES in the Makefile and configuration

2017-08-24 Thread Shannon Zhao
On 2017/8/18 22:23, Dongjiu Geng wrote: > Add CONFIG_ACPI_APEI configuration in the Makefile and > enable it in the arm-softmmu.mak > > Signed-off-by: Dongjiu Geng > --- > default-configs/arm-softmmu.mak | 1 + > hw/acpi/Makefile.objs | 1 + > 2 files changed, 2 insertions(+) > > di

Re: [Qemu-devel] [PATCH QEMU v2] xen/pt: allow QEMU to request MSI unmasking at bind time

2017-08-24 Thread Jan Beulich
>>> On 24.08.17 at 14:19, wrote: > When a MSI interrupt is bound to a guest using > xc_domain_update_msi_irq (XEN_DOMCTL_bind_pt_irq) the interrupt is > left masked by default. > > This causes problems with guests that first configure interrupts and > clean the per-entry MSIX table mask bit and a

[Qemu-devel] [Bug 1712818] [NEW] live migration with storage encounter assert(!(bs->open_flags & BDRV_O_INACTIVE)) crashes

2017-08-24 Thread meeho yuen
Public bug reported: The vm guest runs a iotest program, and i migrate it with virsh --copy- storage-all,then the qemu process on the source host happens to crash with the following message: kvm: block/io.c:1543: bdrv_co_pwritev: Assertion `!(bs->open_flags & 0x0800)' failed. 2017-08-24 11:43:45

Re: [Qemu-devel] [PATCH v2 09/54] hmp: use qapi_enum_parse() in hmp_migrate_set_parameter

2017-08-24 Thread Dr. David Alan Gilbert
* Markus Armbruster (arm...@redhat.com) wrote: > Marc-André Lureau writes: > > > Signed-off-by: Marc-André Lureau > > --- > > hmp.c | 139 > > -- > > 1 file changed, 68 insertions(+), 71 deletions(-) > > > > diff --git a/hmp.c b/h

Re: [Qemu-devel] [PATCH QEMU v2] xen/pt: allow QEMU to request MSI unmasking at bind time

2017-08-24 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20170824121919.78678-3-roger@citrix.com Subject: [Qemu-devel] [PATCH QEMU v2] xen/pt: allow QEMU to request MSI unmasking at bind time === TEST SCRIPT BEGIN === #!/bin/b

Re: [Qemu-devel] [PATCH v4 2/2] ACPI/unit-test: Add a new testcase for RAM allocation in numa node

2017-08-24 Thread Dou Liyang
Hi Igor, At 08/24/2017 08:33 PM, Igor Mammedov wrote: > test_acpi_one(" -numa node -numa node,mem=128", &data); > > but, the DSDT didn't match the default one. because, if we support > NUMA, the DSDT will give us "_PXM" to map the CPU to node. Ok, looks like you'll have to include your variant

Re: [Qemu-devel] [PATCH for-2.11 16/27] xtensa: replace cpu_xtensa_init() with cpu_generic_init()

2017-08-24 Thread Philippe Mathieu-Daudé
On 08/18/2017 07:08 AM, Igor Mammedov wrote: call xtensa_irq_init() at realize time which makes cpu_xtensa_init() like generic cpu creation function. As result we can replace it with cpu_generic_init() which does the same job, reducing code duplication a bit. Signed-off-by: Igor Mammedov Revi

[Qemu-devel] [PATCH v2 4/7] throttle: Remove throttle_fix_bucket() / throttle_unfix_bucket()

2017-08-24 Thread Alberto Garcia
The throttling code can change internally the value of bkt->max if it hasn't been set by the user. The problem with this is that if we want to retrieve the original value we have to undo this change first. This is ugly and unnecessary: this patch removes the throttle_fix_bucket() and throttle_unfix

[Qemu-devel] [PATCH v2 1/7] throttle: Fix wrong variable name in the header documentation

2017-08-24 Thread Alberto Garcia
The level of the burst bucket is stored in bkt.burst_level, not bkt.burst_length. Signed-off-by: Alberto Garcia Reviewed-by: Manos Pitsidianakis --- include/qemu/throttle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/qemu/throttle.h b/include/qemu/throttle.h inde

[Qemu-devel] [PATCH v2 3/7] throttle: Make throttle_is_valid() a bit less verbose

2017-08-24 Thread Alberto Garcia
Use a pointer to the bucket instead of repeating cfg->buckets[i] all the time. This makes the code more concise and will help us expand the checks later and save a few line breaks. Signed-off-by: Alberto Garcia --- util/throttle.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletion

[Qemu-devel] [PATCH v2 5/7] throttle: Make LeakyBucket.avg and LeakyBucket.max integer types

2017-08-24 Thread Alberto Garcia
Both the throttling limits set with the throttling.iops-* and throttling.bps-* options and their QMP equivalents defined in the BlockIOThrottle struct are integer values. Those limits are also reported in the BlockDeviceInfo struct and they are integers there as well. Therefore there's no reason

[Qemu-devel] [PATCH v2 7/7] throttle: Test the valid range of config values

2017-08-24 Thread Alberto Garcia
Signed-off-by: Alberto Garcia --- tests/test-throttle.c | 77 +++ 1 file changed, 77 insertions(+) diff --git a/tests/test-throttle.c b/tests/test-throttle.c index 41c0dd2529..bf7a5a648a 100644 --- a/tests/test-throttle.c +++ b/tests/test-throttle.

[Qemu-devel] [PATCH v2 0/7] Misc throttle fixes

2017-08-24 Thread Alberto Garcia
Hi, here's the new version of my patch series with misc fixes for the throttling code. Stefan, once this is reviewed, can you please remove the "Make LeakyBucket.avg and LeakyBucket.max integer types" commit (id 218f470639117a8e39) from your block-next branch? This series contains a new version o

Re: [Qemu-devel] [PATCH for-2.11 07/27] sparc: replace custom cpu feature parsing with cpu_legacy_parse_featurestr()

2017-08-24 Thread Philippe Mathieu-Daudé
On 08/18/2017 07:08 AM, Igor Mammedov wrote: with features converted to properties we can reuse shared with x86 cpu_legacy_parse_featurestr() for features parsing and drop legacy parser that manipulated CPU directly. With that in place and sparc_cpu_parse_features() providing generic CPUClass::p

[Qemu-devel] [PATCH v2 2/7] throttle: Update the throttle_fix_bucket() documentation

2017-08-24 Thread Alberto Garcia
The way the throttling algorithm works is that requests start being throttled once the bucket level exceeds the burst limit. When we get there the bucket leaks at the level set by the user (bkt->avg), and that leak rate is what prevents guest I/O from exceeding the desired limit. If we don't allow

[Qemu-devel] [PATCH v2 6/7] throttle: Make burst_length 64bit and add range checks

2017-08-24 Thread Alberto Garcia
LeakyBucket.burst_length is defined as an unsigned integer but the code never checks for overflows and it only makes sure that the value is not 0. In practice this means that the user can set something like throttling.iops-total-max-length=4294967300 despite being larger than UINT_MAX and the fina

Re: [Qemu-devel] [PATCH for-2.11 03/27] sparc: convert cpu features to qdev properties

2017-08-24 Thread Philippe Mathieu-Daudé
On 08/18/2017 07:08 AM, Igor Mammedov wrote: SPARC is the last target that uses legacy way of parsing and initializing cpu features, drop legacy approach and convert features to properties so that SPARC could as minimum benefit from generic cpu_generic_init(), common with x86 +-feat parser PS: t

Re: [Qemu-devel] [PATCH for-2.11 19/27] arm: replace cpu_arm_init() with cpu_generic_init()

2017-08-24 Thread Philippe Mathieu-Daudé
On 08/18/2017 07:08 AM, Igor Mammedov wrote: it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Reviewed-by: Andrew Jones Tested-by: Philippe Mathieu-Daudé --- target/arm/cpu.h| 3 +-- hw/arm/musicpal.c | 2 +- hw/arm/omap1.c | 2 +

Re: [Qemu-devel] [PATCH for-2.11 06/27] x86: extract legacy cpu features format parser

2017-08-24 Thread Igor Mammedov
On Thu, 24 Aug 2017 11:18:52 +0200 Igor Mammedov wrote: > On Wed, 23 Aug 2017 14:58:39 -0300 > Eduardo Habkost wrote: > > > On Wed, Aug 23, 2017 at 07:37:39PM +0200, Igor Mammedov wrote: > > > On Wed, 23 Aug 2017 13:46:38 -0300 > > > Eduardo Habkost wrote: > > > > > > > On Wed, Aug 23,

Re: [Qemu-devel] [PATCH for-2.11 06/27] x86: extract legacy cpu features format parser

2017-08-24 Thread Eduardo Habkost
On Thu, Aug 24, 2017 at 11:18:52AM +0200, Igor Mammedov wrote: > On Wed, 23 Aug 2017 14:58:39 -0300 > Eduardo Habkost wrote: > > > On Wed, Aug 23, 2017 at 07:37:39PM +0200, Igor Mammedov wrote: > > > On Wed, 23 Aug 2017 13:46:38 -0300 > > > Eduardo Habkost wrote: > > > > > > > On Wed, Aug 23,

Re: [Qemu-devel] AVMF & OVMF blobs in QEMU tree???

2017-08-24 Thread Laszlo Ersek
On 08/24/17 12:55, Gerd Hoffmann wrote: > Hi, > >> Having all our precompiled blobs be in a submodule would >> maybe be handy for properly keeping them separate from the >> QEMU code -- would that be useful for downstream distro >> packagers? > > I like the clear separation. > > Also you don't

[Qemu-devel] [PATCH v5 2/2] ACPI/unit-test: Add a new testcase for RAM allocation in numa node

2017-08-24 Thread Dou Liyang
As QEMU supports the memory-less node, it is possible that there is no RAM in the first numa node(also be called as node0). eg: ... \ -m 128,slots=3,maxmem=1G \ -numa node -numa node,mem=128M \ But, this makes it hard for QEMU to build a known-to-work ACPI SRAT table. Only fixing it is not e

Re: [Qemu-devel] make check speed

2017-08-24 Thread Cleber Rosa
On 08/23/2017 08:13 AM, Lukáš Doktor wrote: > Dne 23.8.2017 v 14:01 Thomas Huth napsal(a): >> On 23.08.2017 13:51, Lukáš Doktor wrote: >>> Dne 23.8.2017 v 10:35 Thomas Huth napsal(a): On 23.08.2017 10:01, Paolo Bonzini wrote: > On 23/08/2017 09:49, Thomas Huth wrote: >> While we're a

Re: [Qemu-devel] [PATCH] virtio-serial: add enable_backend callback

2017-08-24 Thread Denis V. Lunev
On 07/07/2017 05:21 PM, Pavel Butsykin wrote: > We should guarantee that RAM will not be modified while VM has a stopped > state, otherwise it can lead to negative consequences during post-copy > migration. In RUN_STATE_FINISH_MIGRATE step, it's expected that RAM on > source side will not be modifi

Re: [Qemu-devel] [PATCH QEMU v2] xen/pt: allow QEMU to request MSI unmasking at bind time

2017-08-24 Thread Roger Pau Monne
On Thu, Aug 24, 2017 at 07:09:08AM -0600, Jan Beulich wrote: > >>> On 24.08.17 at 14:19, wrote: > > When a MSI interrupt is bound to a guest using > > xc_domain_update_msi_irq (XEN_DOMCTL_bind_pt_irq) the interrupt is > > left masked by default. > > > > This causes problems with guests that first

Re: [Qemu-devel] [RFC 26/29] vhost: Add VHOST_USER_POSTCOPY_END message

2017-08-24 Thread Dr. David Alan Gilbert
* Maxime Coquelin (maxime.coque...@redhat.com) wrote: > > > On 06/28/2017 09:00 PM, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > This message is sent just before the end of postcopy to get the > > client to stop using userfault since we wont respond to any more

[Qemu-devel] [PATCH QEMU v3] xen/pt: allow QEMU to request MSI unmasking at bind time

2017-08-24 Thread Roger Pau Monne
When a MSI interrupt is bound to a guest using xc_domain_update_msi_irq (XEN_DOMCTL_bind_pt_irq) the interrupt is left masked by default. This causes problems with guests that first configure interrupts and clean the per-entry MSIX table mask bit and afterwards enable MSIX globally. In such scenar

[Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Farhan Ali
Hi, There is an issue in QEMU bios which is exposed by commit commit 198c0d1f9df8c429502cb744fc26b6ba6e71db74 Author: Halil Pasic Date: Thu Jul 27 17:48:42 2017 +0200 s390x/css: check ccw address validity According to the PoP channel command words (CCW) must be doubleword aligne

[Qemu-devel] [PATCH QEMU v4] xen/pt: allow QEMU to request MSI unmasking at bind time

2017-08-24 Thread Roger Pau Monne
When a MSI interrupt is bound to a guest using xc_domain_update_msi_irq (XEN_DOMCTL_bind_pt_irq) the interrupt is left masked by default. This causes problems with guests that first configure interrupts and clean the per-entry MSIX table mask bit and afterwards enable MSIX globally. In such scenar

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Cornelia Huck
On Thu, 24 Aug 2017 11:05:08 -0400 Farhan Ali wrote: > Hi, > > There is an issue in QEMU bios which is exposed by commit > > commit 198c0d1f9df8c429502cb744fc26b6ba6e71db74 > Author: Halil Pasic > Date: Thu Jul 27 17:48:42 2017 +0200 > > s390x/css: check ccw address validity > >

Re: [Qemu-devel] [PATCH] qobject: Explain how QNum works, and why

2017-08-24 Thread Eric Blake
On 08/22/2017 01:52 AM, Markus Armbruster wrote: > Suggested-by: Max Reitz > Signed-off-by: Markus Armbruster > --- > include/qapi/qmp/qnum.h | 21 + > 1 file changed, 21 insertions(+) > > diff --git a/include/qapi/qmp/qnum.h b/include/qapi/qmp/qnum.h > index 09d745c..918212

[Qemu-devel] [PATCH 0/3] nbd-client: enter read_reply_co during init to avoid crash

2017-08-24 Thread Stefan Hajnoczi
See Patch 1 for the segfault fix. Patches 2 & 3 add qemu-iotests coverage. This is a rare crash that we'll probably only see in testing. It only seems to happen with UNIX domain sockets. Stefan Hajnoczi (3): nbd-client: enter read_reply_co during init to avoid crash qemu-iotests: improve nb

[Qemu-devel] [PATCH 3/3] qemu-iotests: test NBD over UNIX domain sockets in 083

2017-08-24 Thread Stefan Hajnoczi
083 only tests TCP. Some failures might be specific to UNIX domain sockets. A few adjustments are necessary: 1. Generating a port number and waiting for server startup is TCP-specific. Use the new nbd-fault-injector.py startup protocol to fetch the address. This is a little more elegant

[Qemu-devel] [PATCH 1/3] nbd-client: enter read_reply_co during init to avoid crash

2017-08-24 Thread Stefan Hajnoczi
The following segfault is encountered if the NBD server closes the UNIX domain socket immediately after negotiation: Program terminated with signal SIGSEGV, Segmentation fault. #0 aio_co_schedule (ctx=0x0, co=0xd3c0ff2ef0) at util/async.c:441 441 QSLIST_INSERT_HEAD_ATOMIC(&ctx->schedu

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Halil Pasic
On 08/24/2017 05:13 PM, Cornelia Huck wrote: > On Thu, 24 Aug 2017 11:05:08 -0400 > Farhan Ali wrote: > >> Hi, >> >> There is an issue in QEMU bios which is exposed by commit >> >> commit 198c0d1f9df8c429502cb744fc26b6ba6e71db74 >> Author: Halil Pasic >> Date: Thu Jul 27 17:48:42 2017 +0200

[Qemu-devel] [PATCH 2/3] qemu-iotests: improve nbd-fault-injector.py startup protocol

2017-08-24 Thread Stefan Hajnoczi
Currently 083 waits for the nbd-fault-injector.py server to start up by looping until netstat shows the TCP listen socket. The startup protocol can be simplified by passing a 0 port number to nbd-fault-injector.py. The kernel will allocate a port in bind(2) and the final port number can be printe

Re: [Qemu-devel] [PATCH v3 05/10] tests: Add FreeBSD image

2017-08-24 Thread Cleber Rosa
On 08/22/2017 12:41 AM, Fam Zheng wrote: > The image is prepared following instructions as in: > > https://wiki.qemu.org/Hosts/BSD > > Signed-off-by: Fam Zheng > --- > tests/vm/freebsd | 45 + > 1 file changed, 45 insertions(+) > create mode 100755

Re: [Qemu-devel] [PATCH 06/10] scsi, file-posix: add support for persistent reservation management

2017-08-24 Thread Eric Blake
On 08/22/2017 08:18 AM, Paolo Bonzini wrote: > It is a common requirement for virtual machine to send persistent > reservations, but this currently requires either running QEMU with > CAP_SYS_RAWIO, or using out-of-tree patches that let an unprivileged > QEMU bypass Linux's filter on SG_IO commands

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Thomas Huth
On 24.08.2017 17:13, Cornelia Huck wrote: > On Thu, 24 Aug 2017 11:05:08 -0400 > Farhan Ali wrote: > >> Hi, >> >> There is an issue in QEMU bios which is exposed by commit >> >> commit 198c0d1f9df8c429502cb744fc26b6ba6e71db74 >> Author: Halil Pasic >> Date: Thu Jul 27 17:48:42 2017 +0200 >> >>

Re: [Qemu-devel] [PATCH v3 00/10] tests: Add VM based build tests (for non-x86_64 and/or non-Linux)

2017-08-24 Thread Cleber Rosa
On 08/22/2017 12:41 AM, Fam Zheng wrote: > v3: Drop RFC. > Add Stefan's and Kamil's reviewed-bys. > Use optparse. [Stefan] > Drop the VGA patch. [Paolo, Stefan] > Improve exit/exit code/doc. [Stefan] > Drop unused line from basevm.py. [Stefan] > Drop "--target-list" form M

Re: [Qemu-devel] [PATCH v3 06/10] tests: Add NetBSD image

2017-08-24 Thread Cleber Rosa
On 08/22/2017 12:41 AM, Fam Zheng wrote: > The image is prepared following instructions as in: > > https://wiki.qemu.org/Hosts/BSD > > Signed-off-by: Fam Zheng > Reviewed-by: Kamil Rytarowski > --- > tests/vm/netbsd | 45 + > 1 file changed, 45 ins

Re: [Qemu-devel] [PATCH v3 07/10] tests: Add OpenBSD image

2017-08-24 Thread Cleber Rosa
On 08/22/2017 12:41 AM, Fam Zheng wrote: > The image is prepared following instructions as in: > > https://wiki.qemu.org/Hosts/BSD > > Signed-off-by: Fam Zheng > --- > tests/vm/openbsd | 46 ++ > 1 file changed, 46 insertions(+) > create mode 10075

Re: [Qemu-devel] [PATCH v3 04/10] tests: Add ubuntu.i386 image

2017-08-24 Thread Cleber Rosa
On 08/22/2017 12:41 AM, Fam Zheng wrote: > This adds a 32bit guest. > > The official LTS cloud image is downloaded and initialized with > cloud-init. > > Signed-off-by: Fam Zheng > --- > tests/vm/ubuntu.i386 | 88 > > 1 file changed, 88 in

Re: [Qemu-devel] [PATCH 08/10] scsi: build qemu-pr-helper

2017-08-24 Thread Eric Blake
On 08/22/2017 08:18 AM, Paolo Bonzini wrote: > Introduce a privileged helper to run persistent reservation commands. > This lets virtual machines send persistent reservations without using > CAP_SYS_RAWIO or out-of-tree patches. The helper uses Unix permissions > and SCM_RIGHTS to restrict access

Re: [Qemu-devel] [PATCH 06/10] scsi, file-posix: add support for persistent reservation management

2017-08-24 Thread Paolo Bonzini
On 24/08/2017 17:37, Eric Blake wrote: >> # >> # @filename:path to the image file >> +# @pr-manager: the if for the object that will handle persistent >> reservations > s/if/interface/ for legibility > "id" actually. Paolo signature.asc Description: OpenPGP digital signature

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Halil Pasic
On 08/24/2017 05:35 PM, Thomas Huth wrote: > On 24.08.2017 17:13, Cornelia Huck wrote: >> On Thu, 24 Aug 2017 11:05:08 -0400 >> Farhan Ali wrote: >> >>> Hi, >>> >>> There is an issue in QEMU bios which is exposed by commit >>> >>> commit 198c0d1f9df8c429502cb744fc26b6ba6e71db74 >>> Author: Halil

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Thomas Huth
On 24.08.2017 17:47, Halil Pasic wrote: > > > On 08/24/2017 05:35 PM, Thomas Huth wrote: >> On 24.08.2017 17:13, Cornelia Huck wrote: >>> On Thu, 24 Aug 2017 11:05:08 -0400 >>> Farhan Ali wrote: >>> Hi, There is an issue in QEMU bios which is exposed by commit commit 198

Re: [Qemu-devel] [PATCH 0/3] nbd-client: enter read_reply_co during init to avoid crash

2017-08-24 Thread Eric Blake
On 08/24/2017 10:33 AM, Stefan Hajnoczi wrote: > See Patch 1 for the segfault fix. Patches 2 & 3 add qemu-iotests coverage. > > This is a rare crash that we'll probably only see in testing. It only seems > to > happen with UNIX domain sockets. Rare enough that I don't think it is 2.10-rc4 mate

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Farhan Ali
On 08/24/2017 11:50 AM, Thomas Huth wrote: On 24.08.2017 17:47, Halil Pasic wrote: On 08/24/2017 05:35 PM, Thomas Huth wrote: On 24.08.2017 17:13, Cornelia Huck wrote: On Thu, 24 Aug 2017 11:05:08 -0400 Farhan Ali wrote: Hi, There is an issue in QEMU bios which is exposed by commit co

[Qemu-devel] [RFC v2 PATCH] tcg/softmmu: Increase size of TLB caches

2017-08-24 Thread Pranith Kumar
This patch increases the number of entries cached in the TLB. I went over a few architectures to see if increasing it is problematic. Only armv6 seems to have a limitation that only 8 bits can be used for indexing these entries. For other architectures, the number of TLB entries is increased to a 4

Re: [Qemu-devel] [RFC v2 PATCH] tcg/softmmu: Increase size of TLB caches

2017-08-24 Thread Pranith Kumar
On Thu, Aug 24, 2017 at 11:58 AM, Pranith Kumar wrote: > This patch increases the number of entries cached in the TLB. I went > over a few architectures to see if increasing it is problematic. Only > armv6 seems to have a limitation that only 8 bits can be used for > indexing these entries. For ot

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Halil Pasic
On 08/24/2017 05:53 PM, Farhan Ali wrote: > > > On 08/24/2017 11:50 AM, Thomas Huth wrote: >> On 24.08.2017 17:47, Halil Pasic wrote: >>> >>> >>> On 08/24/2017 05:35 PM, Thomas Huth wrote: On 24.08.2017 17:13, Cornelia Huck wrote: > On Thu, 24 Aug 2017 11:05:08 -0400 > Farhan Ali

Re: [Qemu-devel] [Qemu-block] [PATCH 0/3] nbd-client: enter read_reply_co during init to avoid crash

2017-08-24 Thread Stefan Hajnoczi
On Thu, Aug 24, 2017 at 4:52 PM, Eric Blake wrote: > On 08/24/2017 10:33 AM, Stefan Hajnoczi wrote: >> See Patch 1 for the segfault fix. Patches 2 & 3 add qemu-iotests coverage. >> >> This is a rare crash that we'll probably only see in testing. It only seems >> to >> happen with UNIX domain so

Re: [Qemu-devel] [PATCH] qemu-iotests: add 194 non-shared storage migration test

2017-08-24 Thread Eric Blake
On 08/23/2017 09:05 AM, Stefan Hajnoczi wrote: > Non-shared storage migration with NBD and drive-mirror is currently not > tested by qemu-iotests. This test case covers the basic migration > scenario. > > Signed-off-by: Stefan Hajnoczi > Based-on: <20170823134242.12080-1-f...@redhat.com> > --- >

Re: [Qemu-devel] S390 bios breaks in qemu 2.10.rc3

2017-08-24 Thread Peter Maydell
On 24 August 2017 at 16:53, Farhan Ali wrote: > > > On 08/24/2017 11:50 AM, Thomas Huth wrote: >> True, so that could still be an issue. Looking at the cio.h in the >> kernel, they define the struct like this: >> >> struct ccw1 { >> __u8 cmd_code; >> __u8 flags; >> __u16

Re: [Qemu-devel] [PATCH 1/3] nbd-client: enter read_reply_co during init to avoid crash

2017-08-24 Thread Paolo Bonzini
On 24/08/2017 17:33, Stefan Hajnoczi wrote: > This patch enters read_reply_co directly in > nbd_client_attach_aio_context(). This is safe because new_context is > acquired by the caller. This ensures that read_reply_co reaches its > first yield point and its ctx is set up. I'm not very confident

Re: [Qemu-devel] [PATCH 0/4] four zpci patches

2017-08-24 Thread Eric Blake
On 08/24/2017 03:48 AM, Yi Min Zhao wrote: > > > 在 2017/8/24 下午3:13, Cornelia Huck 写道: >> On Thu, 24 Aug 2017 13:20:12 +0800 >> Yi Min Zhao wrote: >> >>> Why can't I receive [Qemu-devel] prefixed patches? >> > I sent patches to qemu-devel@nongnu.org and cc you also myself. > But what I received

Re: [Qemu-devel] [PATCH] vga: stop passing pointers to vga_draw_line* functions

2017-08-24 Thread Eric Blake
On 08/24/2017 04:19 AM, Gerd Hoffmann wrote: > Instead pass around the address (aka offset into vga memory). > Add vga_read_* helper functions which apply vbe_size_mask to > the address, to make sure the address stays within the valid > range, simliar to the cirrus blitter fixes (commits ffaf857778

[Qemu-devel] [PATCH for-2.11 v3 01/25] qom: cpu: fix parsed feature string length

2017-08-24 Thread Igor Mammedov
since commit ( 9262685b cpu: Factor out cpu_generic_init() ) features parsed by it were truncated only to the 1st feature after CPU name due to fact that featurestr = strtok(NULL, ","); cc->parse_features(cpu, featurestr, &err); would extract exactly one feature and parse_features() callbac

[Qemu-devel] [PATCH for-2.11 v3 00/25] complete cpu QOMification and remove cpu_FOO_init() helpers

2017-08-24 Thread Igor Mammedov
ChangeLog since v2: * rebase on top of rc4 * fix latent bug in cpu_generic_init() [01/25] qom: cpu: fix parsed feature string length * drop [05/27] target-i386: cpu: convert plus/minus properties to global properties [06/27] x86: extract legacy cpu features format parser

[Qemu-devel] [PATCH for-2.11 v3 03/25] sparc: embed sparc_def_t into CPUSPARCState

2017-08-24 Thread Igor Mammedov
Make CPUSPARCState::def embedded so it would be allocated as part of cpu instance and we won't have to worry about cleaning def pointer up mannualy on cpu destruction. Signed-off-by: Igor Mammedov Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé --- Embedded CPUSPARCState::

[Qemu-devel] [PATCH for-2.11 v3 05/25] sparc: move adhoc CPUSPARCState initialization to realize time

2017-08-24 Thread Igor Mammedov
SPARCCPU::env was initialized from previously set properties (with help of sparc_cpu_parse_features) in cpu_sparc_register(). However there is not reason to keep it there as this task is typically done at realize time. So move post properties initialization into sparc_cpu_realizefn, which brings cp

[Qemu-devel] [PATCH for-2.11 v3 02/25] sparc: convert cpu models to SPARC cpu subclasses

2017-08-24 Thread Igor Mammedov
QOMfy cpu models handling introducing propper cpu types for each cpu model. Signed-off-by: Igor Mammedov Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé --- with this and conversion of features to properties, it would be possible to replace cpu_sparc_init() with cpu_generi

[Qemu-devel] [PATCH for-2.11 v3 09/25] alpha: replace cpu_alpha_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
cpu_alpha_init() used to provide default fallback if invalid (i.e. non existent) cpu_model were provided. dp264 machine provides its own default so sole user of fallback is [bsd|linux]-user targets which specifies 'any' cpu model that fallbacks to "ev67" in cpu_alpha_init(). Push fallback handling

[Qemu-devel] [PATCH for-2.11 v3 06/25] sparc: make cpu feature parsing property based

2017-08-24 Thread Igor Mammedov
with features converted to properties we can use the same approach as x86 for features parsing and drop legacy approach that manipulated CPU instance directly. New sparc_cpu_parse_features() will allow only +-feat and explicitly disable feat=on|off syntax for now. With that in place and sparc_cpu_

<    1   2   3   4   >