Re: [PATCH v2 11/15] iotests: split linters.py out from 297

2021-10-28 Thread John Snow
On Thu, Oct 28, 2021, 6:34 AM Hanna Reitz wrote: > On 26.10.21 20:30, John Snow wrote: > > > > > > On Tue, Oct 26, 2021 at 6:51 AM Hanna Reitz wrote: > > > > On 19.10.21 16:49, John Snow wrote: > > > Now, 297 is just the iotests-specific incantations and > > linters.py is as > >

Re: [PATCH v4 00/25] block layer: split block APIs in global state and I/O

2021-10-28 Thread Stefan Hajnoczi
On Mon, Oct 25, 2021 at 06:17:10AM -0400, Emanuele Giuseppe Esposito wrote: > Currently, block layer APIs like block-backend.h contain a mix of > functions that are either running in the main loop and under the > BQL, or are thread-safe functions and run in iothreads performing I/O. > The

Re: [PATCH v4 14/25] include/systemu/blockdev.h: global state API

2021-10-28 Thread Stefan Hajnoczi
On Mon, Oct 25, 2021 at 06:17:24AM -0400, Emanuele Giuseppe Esposito wrote: > blockdev functions run always under the BQL lock. > > Signed-off-by: Emanuele Giuseppe Esposito > --- > include/sysemu/blockdev.h | 18 ++ > 1 file changed, 14 insertions(+), 4 deletions(-)

Re: [PATCH v4 00/25] block layer: split block APIs in global state and I/O

2021-10-28 Thread Stefan Hajnoczi
On Mon, Oct 25, 2021 at 04:09:41PM +0200, Philippe Mathieu-Daudé wrote: > On 10/25/21 12:17, Emanuele Giuseppe Esposito wrote: > [...] > > > Each function in the GS API will have an assertion, checking > > that it is always running under BQL. > > I/O functions are instead thread safe (or so

Re: [PATCH v5 2/8] python/machine: Handle QMP errors on close more meticulously

2021-10-28 Thread John Snow
On Thu, Oct 28, 2021, 6:01 AM Kevin Wolf wrote: > Am 27.10.2021 um 19:49 hat John Snow geschrieben: > > This reply is long, sorry. > > And after writing half of a very long reply myself, I noticed that I was > just very confused, so sorry for making you write a long text for no > real reason

Re: [PATCH v5 0/8] Switch iotests to using Async QMP

2021-10-28 Thread John Snow
On Thu, Oct 28, 2021 at 6:37 AM Kevin Wolf wrote: > Am 26.10.2021 um 19:56 hat John Snow geschrieben: > > GitLab: > https://gitlab.com/jsnow/qemu/-/commits/python-aqmp-iotest-wrapper > > CI: https://gitlab.com/jsnow/qemu/-/pipelines/395925703 > > > > Hiya, > > > > This series continues where the

Re: [PATCH] nbd/server: Advertise MULTI_CONN for shared writable exports

2021-10-28 Thread Kevin Wolf
Am 27.08.2021 um 17:09 hat Eric Blake geschrieben: > According to the NBD spec, a server advertising > NBD_FLAG_CAN_MULTI_CONN promises that multiple client connections will > not see any cache inconsistencies: when properly separated by a single > flush, actions performed by one client will be

Re: [RFC PATCH v2] hw/nvme:Adding Support for namespace management

2021-10-28 Thread Lukasz Maniak
On Thu, Aug 19, 2021 at 06:39:57PM +0530, Naveen Nagar wrote: > From: Naveen > > This patch supports namespace management : create and delete operations. > > Since v1: > - Modified and moved nvme_ns_identify_common in ns.c file > - Added check for CSI field in NS management > - Indentation fix

Re: [PATCH v5 0/8] Switch iotests to using Async QMP

2021-10-28 Thread Kevin Wolf
Am 26.10.2021 um 19:56 hat John Snow geschrieben: > GitLab: https://gitlab.com/jsnow/qemu/-/commits/python-aqmp-iotest-wrapper > CI: https://gitlab.com/jsnow/qemu/-/pipelines/395925703 > > Hiya, > > This series continues where the last two AQMP series left off and adds a > synchronous 'legacy'

Re: [PATCH v2 11/15] iotests: split linters.py out from 297

2021-10-28 Thread Hanna Reitz
On 26.10.21 20:30, John Snow wrote: On Tue, Oct 26, 2021 at 6:51 AM Hanna Reitz wrote: On 19.10.21 16:49, John Snow wrote: > Now, 297 is just the iotests-specific incantations and linters.py is as > minimal as I can think to make it. The only remaining element in here

[PATCH v2 0/9] Configurable policy for handling unstable interfaces

2021-10-28 Thread Markus Armbruster
Option -compat lets you configure what to do when deprecated interfaces get used. This series extends this to unstable interfaces. Works the same way. Intended for testing users of the management interfaces. It is experimental. To make it possible, I replace the "x-" naming convention by

[PATCH v2 2/9] qapi: Mark unstable QMP parts with feature 'unstable'

2021-10-28 Thread Markus Armbruster
Add special feature 'unstable' everywhere the name starts with 'x-', except for InputBarrierProperties member x-origin and MemoryBackendProperties member x-use-canonical-path-for-ramblock-id, because these two are actually stable. Signed-off-by: Markus Armbruster Reviewed-by: Juan Quintela

[PATCH v2 4/9] qapi: Tools for sets of special feature flags in generated code

2021-10-28 Thread Markus Armbruster
New enum QapiSpecialFeature enumerates the special feature flags. New helper gen_special_features() returns code to represent a collection of special feature flags as a bitset. The next few commits will put them to use. Signed-off-by: Markus Armbruster Reviewed-by: John Snow ---

[PATCH v2 8/9] qapi: Factor out compat_policy_input_ok()

2021-10-28 Thread Markus Armbruster
The code to check policy for handling deprecated input is triplicated. Factor it out into compat_policy_input_ok() before I mess with it in the next commit. Signed-off-by: Markus Armbruster Reviewed-by: Philippe Mathieu-Daudé --- include/qapi/compat-policy.h | 7 + qapi/qapi-visit-core.c

Re: [PATCH v2 12/15] iotests/linters: Add entry point for linting via Python CI

2021-10-28 Thread Hanna Reitz
On 26.10.21 21:45, John Snow wrote: On Tue, Oct 26, 2021 at 2:36 PM John Snow wrote: On Tue, Oct 26, 2021 at 6:57 AM Hanna Reitz wrote: On 19.10.21 16:49, John Snow wrote: > We need at least a tiny little shim here to join test file discovery > with

[PATCH v2 6/9] qapi: Generalize command policy checking

2021-10-28 Thread Markus Armbruster
The code to check command policy can see special feature flag 'deprecated' as command flag QCO_DEPRECATED. I want to make feature flag 'unstable' visible there as well, so I can add policy for it. To let me make it visible, add member @special_features (a bitset of QapiSpecialFeature) to

[PATCH v2 9/9] qapi: Extend -compat to set policy for unstable interfaces

2021-10-28 Thread Markus Armbruster
New option parameters unstable-input and unstable-output set policy for unstable interfaces just like deprecated-input and deprecated-output set policy for deprecated interfaces (see commit 6dd75472d5 "qemu-options: New -compat to set policy for deprecated interfaces"). This is intended for

[PATCH v2 7/9] qapi: Generalize enum member policy checking

2021-10-28 Thread Markus Armbruster
The code to check enumeration value policy can see special feature flag 'deprecated' in QEnumLookup member flags[value]. I want to make feature flag 'unstable' visible there as well, so I can add policy for it. Instead of extending flags[], replace it by @special_features (a bitset of

[PATCH v2 5/9] qapi: Generalize struct member policy checking

2021-10-28 Thread Markus Armbruster
The generated visitor functions call visit_deprecated_accept() and visit_deprecated() when visiting a struct member with special feature flag 'deprecated'. This makes the feature flag visible to the actual visitors. I want to make feature flag 'unstable' visible there as well, so I can add

[PATCH v2 3/9] qapi: Eliminate QCO_NO_OPTIONS for a slight simplification

2021-10-28 Thread Markus Armbruster
Signed-off-by: Markus Armbruster Reviewed-by: Juan Quintela Reviewed-by: John Snow --- include/qapi/qmp/dispatch.h | 1 - monitor/misc.c | 3 +-- scripts/qapi/commands.py| 5 + 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/include/qapi/qmp/dispatch.h

[PATCH v2 1/9] qapi: New special feature flag "unstable"

2021-10-28 Thread Markus Armbruster
By convention, names starting with "x-" are experimental. The parts of external interfaces so named may be withdrawn or changed incompatibly in future releases. The naming convention makes unstable interfaces easy to recognize. Promoting something from experimental to stable involves a name

[PATCH v3 4/4] iotests: add qemu-img-compare-stat test

2021-10-28 Thread Vladimir Sementsov-Ogievskiy
Test new feature qemu-img compare --stat. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- .../qemu-iotests/tests/qemu-img-compare-stat | 88 +++ .../tests/qemu-img-compare-stat.out | 106 ++ 2 files changed, 194 insertions(+)

[PATCH v3 1/4] qemu-img: implement compare --stat

2021-10-28 Thread Vladimir Sementsov-Ogievskiy
With new option qemu-img compare will not stop at first mismatch, but instead calculate statistics: how many clusters with different data, how many clusters with equal data, how many clusters were unallocated but become data and so on. We compare images chunk by chunk. Chunk size depends on what

[PATCH v3 2/4] qemu-img: make --block-size optional for compare --stat

2021-10-28 Thread Vladimir Sementsov-Ogievskiy
Let's detect block-size automatically if not specified by user: If both files define cluster-size, use minimum to be more precise. If both files don't specify cluster-size, use default of 64K If only one file specify cluster-size, just use it. Signed-off-by: Vladimir Sementsov-Ogievskiy ---

[PATCH v3 0/4] qemu-img compare --stat

2021-10-28 Thread Vladimir Sementsov-Ogievskiy
Hi all! Recently we faced the following task: Customer comes and say: incremental backup images are too fat. Does you incremental backup works correct? What to answer? We should check something. At least check that incremental images doesn't store same data twice. And we don't have a tool for

[PATCH v3 3/4] qemu-img: add --shallow option for qemu-img compare

2021-10-28 Thread Vladimir Sementsov-Ogievskiy
Allow compare only top images of backing chains. This is useful to compare images with same backing file or to compare incremental images from the chain of incremental backups with "--stat" option. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- docs/tools/qemu-img.rst

Re: [PATCH v2 2/4] qemu-img: make --block-size optional for compare --stat

2021-10-28 Thread Vladimir Sementsov-Ogievskiy
26.10.2021 11:07, Hanna Reitz wrote: On 21.10.21 12:12, Vladimir Sementsov-Ogievskiy wrote: Let's detect block-size automatically if not specified by user:   If both files define cluster-size, use minimum to be more precise.   If both files don't specify cluster-size, use default of 64K   If

Re: [PATCH v5 2/8] python/machine: Handle QMP errors on close more meticulously

2021-10-28 Thread Kevin Wolf
Am 27.10.2021 um 19:49 hat John Snow geschrieben: > This reply is long, sorry. And after writing half of a very long reply myself, I noticed that I was just very confused, so sorry for making you write a long text for no real reason (well, at least for my first point - for the second one, your

Re: [PATCH v8 0/8] hmp, qmp: Add commands to introspect virtio devices

2021-10-28 Thread Dr. David Alan Gilbert
* Jonah Palmer (jonah.pal...@oracle.com) wrote: > > On 10/27/21 07:55, Daniel P. Berrangé wrote: > > On Wed, Oct 27, 2021 at 07:41:41AM -0400, Jonah Palmer wrote: > > > This series introduces new QMP/HMP commands to dump the status of a > > > virtio device at different levels. > > > > > >

Re: [PATCH v2 0/3] virtio: increase VIRTQUEUE_MAX_SIZE to 32k

2021-10-28 Thread Stefan Hajnoczi
On Mon, Oct 25, 2021 at 05:03:25PM +0200, Christian Schoenebeck wrote: > On Montag, 25. Oktober 2021 12:30:41 CEST Stefan Hajnoczi wrote: > > On Thu, Oct 21, 2021 at 05:39:28PM +0200, Christian Schoenebeck wrote: > > > On Freitag, 8. Oktober 2021 18:08:48 CEST Christian Schoenebeck wrote: > > > >

Re: [PATCH 1/9] qapi: New special feature flag "unstable"

2021-10-28 Thread Markus Armbruster
Kevin Wolf writes: > Am 26.10.2021 um 11:37 hat Markus Armbruster geschrieben: >> Kevin Wolf writes: >> >> > Am 25.10.2021 um 07:25 hat Markus Armbruster geschrieben: >> >> By convention, names starting with "x-" are experimental. The parts >> >> of external interfaces so named may be

Re: [PATCH v8 5/8] qmp: decode feature & status bits in virtio-status

2021-10-28 Thread David Hildenbrand
On 28.10.21 09:56, Jonah Palmer wrote: > On 10/27/21 08:18, Laurent Vivier wrote: >> On 27/10/2021 13:59, David Hildenbrand wrote: >>> On 27.10.21 13:41, Jonah Palmer wrote: From: Laurent Vivier Display feature names instead of bitmaps for host, guest, and backend for

Re: [PATCH v8 5/8] qmp: decode feature & status bits in virtio-status

2021-10-28 Thread Jonah Palmer
On 10/27/21 08:18, Laurent Vivier wrote: On 27/10/2021 13:59, David Hildenbrand wrote: On 27.10.21 13:41, Jonah Palmer wrote: From: Laurent Vivier Display feature names instead of bitmaps for host, guest, and backend for VirtIODevice. Display status names instead of bitmaps for

Re: [PATCH v8 0/8] hmp, qmp: Add commands to introspect virtio devices

2021-10-28 Thread Jonah Palmer
On 10/27/21 07:55, Daniel P. Berrangé wrote: On Wed, Oct 27, 2021 at 07:41:41AM -0400, Jonah Palmer wrote: This series introduces new QMP/HMP commands to dump the status of a virtio device at different levels. [Jonah: Rebasing previous patchset from Oct. 5 (v7). Original patches are from