Re: [PULL 00/10] Python patches

2021-10-12 Thread Richard Henderson
On 10/12/21 2:41 PM, John Snow wrote: The following changes since commit bfd9a76f9c143d450ab5545dedfa74364b39fc56: Merge remote-tracking branch 'remotes/stsquad/tags/pull-for-6.2-121021-2' into staging (2021-10-12 06:16:25 -0700) are available in the Git repository at:

[PATCH v3 2/7] python/machine: Handle QMP errors on close more meticulously

2021-10-12 Thread John Snow
To use the AQMP backend, Machine just needs to be a little more diligent about what happens when closing a QMP connection. The operation is no longer a freebie in the async world; it may return errors encountered in the async bottom half on incoming message receipt, etc. (AQMP's disconnect,

[PATCH v3 7/7] python, iotests: replace qmp with aqmp

2021-10-12 Thread John Snow
Swap out the synchronous QEMUMonitorProtocol from qemu.qmp with the sync wrapper from qemu.aqmp instead. Add an escape hatch in the form of the environment variable QEMU_PYTHON_LEGACY_QMP which allows you to cajole QEMUMachine into using the old implementatin, proving that both implementations

[PATCH v3 6/7] python/aqmp: Create sync QMP wrapper for iotests

2021-10-12 Thread John Snow
This is a wrapper around the async QMPClient that mimics the old, synchronous QEMUMonitorProtocol class. It is designed to be interchangeable with the old implementation. It does not, however, attempt to mimic Exception compatibility. Signed-off-by: John Snow --- python/qemu/aqmp/legacy.py |

[PATCH v3 5/7] iotests: Conditionally silence certain AQMP errors

2021-10-12 Thread John Snow
AQMP likes to be very chatty about errors it encounters. In general, this is good because it allows us to get good diagnostic information for otherwise complex async failures. For example, during a failed QMP connection attempt, we might see: +ERROR:qemu.aqmp.qmp_client.qemub-2536319:Negotiation

[PATCH v3 0/7] Switch iotests to using Async QMP

2021-10-12 Thread John Snow
Based-on: <20211012214152.802483-1-js...@redhat.com> [PULL 00/10] Python patches GitLab: https://gitlab.com/jsnow/qemu/-/commits/python-aqmp-iotest-wrapper CI: https://gitlab.com/jsnow/qemu/-/pipelines/387210591 Hiya, This series continues where the last two AQMP series left off and

[PATCH v3 3/7] python/aqmp: Remove scary message

2021-10-12 Thread John Snow
The scary message interferes with the iotests output. Coincidentally, if iotests works by removing this, then it's good evidence that we don't really need to scare people away from using it. Signed-off-by: John Snow --- python/qemu/aqmp/__init__.py | 12 1 file changed, 12

[PATCH v3 4/7] iotests: Accommodate async QMP Exception classes

2021-10-12 Thread John Snow
(But continue to support the old ones for now, too.) There are very few cases of any user of QEMUMachine or a subclass thereof relying on a QMP Exception type. If you'd like to check for yourself, you want to grep for all of the derivatives of QMPError, excluding 'AQMPError' and its derivatives.

[PATCH v3 1/7] python/machine: remove has_quit argument

2021-10-12 Thread John Snow
If we spy on the QMP commands instead, we don't need callers to remember to pass it. Seems like a fair trade-off. The one slightly weird bit is overloading this instance variable for wait(), where we use it to mean "don't issue the qmp 'quit' command". This means that wait() will "fail" if the

[PULL 10/10] python, iotests: remove socket_scm_helper

2021-10-12 Thread John Snow
It's not used anymore, now. Signed-off-by: John Snow Reviewed-by: Hanna Reitz Reviewed-by: Paolo Bonzini Message-id: 20210923004938.363-11-js...@redhat.com Signed-off-by: John Snow --- tests/qemu-iotests/socket_scm_helper.c | 136 - python/qemu/machine/machine.py

Re: [PATCH 10/12] block-backend: convert blk_aio_ functions to int64_t bytes paramter

2021-10-12 Thread Vladimir Sementsov-Ogievskiy
13.10.2021 00:37, Eric Blake wrote: On Tue, Oct 12, 2021 at 07:13:23PM +0300, Vladimir Sementsov-Ogievskiy wrote: @@ -1530,6 +1531,7 @@ BlockAIOCB *blk_aio_preadv(BlockBackend *blk, int64_t offset, QEMUIOVector *qiov, BdrvRequestFlags flags,

[PULL 07/10] python/aqmp: Disable logging messages by default

2021-10-12 Thread John Snow
AQMP is a library, and ideally it should not print error diagnostics unless a user opts into seeing them. By default, Python will print all WARNING, ERROR or CRITICAL messages to screen if no logging configuration has been created by a client application. In AQMP's case, ERROR logging statements

[PULL 09/10] python/qmp: add send_fd_scm directly to QEMUMonitorProtocol

2021-10-12 Thread John Snow
It turns out you can do this directly from Python ... and because of this, you don't need to worry about setting the inheritability of the fds or spawning another process. Doing this is helpful because it allows QEMUMonitorProtocol to keep its file descriptor and socket object as private

[PULL 08/10] python/qmp: clear events on get_events() call

2021-10-12 Thread John Snow
All callers in the tree *already* clear the events after a call to get_events(). Do it automatically instead and update callsites to remove the manual clear call. These semantics are quite a bit easier to emulate with async QMP, and nobody appears to be abusing some emergent properties of what

[PULL 06/10] python/aqmp: Reduce severity of EOFError-caused loop terminations

2021-10-12 Thread John Snow
When we encounter an EOFError, we don't know if it's an "error" in the perspective of the user of the library yet. Therefore, we should not log it as an error. Reduce the severity of this logging message to "INFO" to indicate that it's something that we expect to occur during the normal operation

[PULL 02/10] python/aqmp: add .empty() method to EventListener

2021-10-12 Thread John Snow
Synchronous clients may want to know if they're about to block waiting for an event or not. A method such as this is necessary to implement a compatible interface for the old QEMUMonitorProtocol using the new async internals. Signed-off-by: John Snow Reviewed-by: Hanna Reitz Reviewed-by: Paolo

[PULL 05/10] python/aqmp: Add dict conversion method to Greeting object

2021-10-12 Thread John Snow
The iotests interface expects to return the greeting as a dict; AQMP offers it as a rich object. Signed-off-by: John Snow Reviewed-by: Paolo Bonzini Reviewed-by: Eric Blake Message-id: 20210923004938.363-6-js...@redhat.com Signed-off-by: John Snow --- python/qemu/aqmp/models.py | 13

[PULL 04/10] python/aqmp: add send_fd_scm

2021-10-12 Thread John Snow
Add an implementation for send_fd_scm to the async QMP implementation. Like socket_scm_helper mentions, a non-empty payload is required for QEMU to process the ancillary data. A space is most useful because it does not disturb the parsing of subsequent JSON objects. A note on "voiding the

[PULL 03/10] python/aqmp: Return cleared events from EventListener.clear()

2021-10-12 Thread John Snow
This serves two purposes: (1) It is now possible to discern whether or not clear() removed any event(s) from the queue with absolute certainty, and (2) It is now very easy to get a List of all pending events in one chunk, which is useful for the sync bridge. Signed-off-by: John Snow

[PULL 01/10] python/aqmp: add greeting property to QMPClient

2021-10-12 Thread John Snow
Expose the greeting as a read-only property of QMPClient so it can be retrieved at-will. Signed-off-by: John Snow Reviewed-by: Hanna Reitz Reviewed-by: Paolo Bonzini Message-id: 20210923004938.363-2-js...@redhat.com Signed-off-by: John Snow --- python/qemu/aqmp/qmp_client.py | 5 + 1

[PULL 00/10] Python patches

2021-10-12 Thread John Snow
The following changes since commit bfd9a76f9c143d450ab5545dedfa74364b39fc56: Merge remote-tracking branch 'remotes/stsquad/tags/pull-for-6.2-121021-2' into staging (2021-10-12 06:16:25 -0700) are available in the Git repository at: https://gitlab.com/jsnow/qemu.git tags/python-pull-request

Re: [PATCH 10/12] block-backend: convert blk_aio_ functions to int64_t bytes paramter

2021-10-12 Thread Eric Blake
On Tue, Oct 12, 2021 at 07:13:23PM +0300, Vladimir Sementsov-Ogievskiy wrote: > > > @@ -1530,6 +1531,7 @@ BlockAIOCB *blk_aio_preadv(BlockBackend *blk, > > > int64_t offset, > > > QEMUIOVector *qiov, BdrvRequestFlags flags, > > >

Re: [PATCH v2 13/17] iotests: Accommodate async QMP Exception classes

2021-10-12 Thread John Snow
On Tue, Oct 12, 2021 at 12:06 PM Hanna Reitz wrote: > On 23.09.21 02:49, John Snow wrote: > > (But continue to support the old ones for now, too.) > > > > There are very few cases of any user of QEMUMachine or a subclass > > thereof relying on a QMP Exception type. If you'd like to check for > >

Re: [PATCH 04/15] pcie: Add callback preceding SR-IOV VFs update

2021-10-12 Thread Lukasz Maniak
On Tue, Oct 12, 2021 at 03:25:12AM -0400, Michael S. Tsirkin wrote: > On Thu, Oct 07, 2021 at 06:23:55PM +0200, Lukasz Maniak wrote: > > PCIe devices implementing SR-IOV may need to perform certain actions > > before the VFs are unrealized or vice versa. > > > > Signed-off-by: Lukasz Maniak > >

Re: [PATCH 10/12] block-backend: convert blk_aio_ functions to int64_t bytes paramter

2021-10-12 Thread Vladimir Sementsov-Ogievskiy
10/6/21 23:29, Eric Blake wrote: On Wed, Oct 06, 2021 at 03:17:16PM +0200, Vladimir Sementsov-Ogievskiy wrote: 1. Convert bytes in BlkAioEmAIOCB: aio->bytes is only passed to already int64_t interfaces, and set in blk_aio_prwv, which is updated here. 2. For all updated functions

Re: [PATCH v2 13/17] iotests: Accommodate async QMP Exception classes

2021-10-12 Thread Hanna Reitz
On 23.09.21 02:49, John Snow wrote: (But continue to support the old ones for now, too.) There are very few cases of any user of QEMUMachine or a subclass thereof relying on a QMP Exception type. If you'd like to check for yourself, you want to grep for all of the derivatives of QMPError,

Re: [PATCH v2 12/17] python/machine: Handle QMP errors on close more meticulously

2021-10-12 Thread Hanna Reitz
On 07.10.21 18:52, John Snow wrote: On Wed, Sep 22, 2021 at 8:50 PM John Snow wrote: To use the AQMP backend, Machine just needs to be a little more diligent about what happens when closing a QMP connection. The operation is no longer a freebie in the async world; it may

Re: [PATCH v2 11/17] python/machine: remove has_quit argument

2021-10-12 Thread Hanna Reitz
On 23.09.21 02:49, John Snow wrote: If we spy on the QMP commands instead, we don't need callers to remember to pass it. Seems like a fair trade-off. The one slightly weird bit is overloading this instance variable for wait(), where we use it to mean "don't issue the qmp 'quit' command". This

[PATCH V5] block/rbd: implement bdrv_co_block_status

2021-10-12 Thread Peter Lieven
the qemu rbd driver currently lacks support for bdrv_co_block_status. This results mainly in incorrect progress during block operations (e.g. qemu-img convert with an rbd image as source). This patch utilizes the rbd_diff_iterate2 call from librbd to detect allocated and unallocated (all zero

Re: [RFC PATCH] block/vpc: Support probing of fixed-size VHD images

2021-10-12 Thread Thomas Huth
On 19/05/2021 12.56, Kevin Wolf wrote: [...] We have a bug in vpc_open(), though: It sets the local variable disk_type correctly, but other functions use s->footer.type instead and we never check that it actually matches the disk type we think we're opening. So I think we need to add this check

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

2021-10-12 Thread Paolo Bonzini
On 12/10/21 10:48, Emanuele Giuseppe Esposito wrote: +/* Common functions that are neither I/O nor Global State */ + +DriveInfo *blk_legacy_dinfo(BlockBackend *blk); +int drive_get_max_devs(BlockInterfaceType type); + blk_legacy_dinfo should count as global state (blk->legacy_dinfo is

Re: [PATCH v3 08/25] block: introduce assert_bdrv_graph_writable

2021-10-12 Thread Paolo Bonzini
On 12/10/21 10:48, Emanuele Giuseppe Esposito wrote: We want to be sure that the functions that write the child and parent list of a bs are under BQL and drain. BQL prevents from concurrent writings from the GS API, while drains protect from I/O. TODO: drains are missing in some functions

Re: [PATCH v3 13/25] include/sysemu/blockdev.h: move drive_add and inline drive_def

2021-10-12 Thread Paolo Bonzini
On 12/10/21 10:48, Emanuele Giuseppe Esposito wrote: +if (type != IF_DEFAULT) { +qemu_opt_set(opts, "if", if_name[type], _abort); +} To avoid exporting if_name, this can be replaced by a string argument directly. But in any case this is okay for this series: Reviewed-by:

[PATCH v3 25/25] job.h: assertions in the callers of JobDriver funcion pointers

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- job.c | 9 + 1 file changed, 9 insertions(+) diff --git a/job.c b/job.c index dbfa67bb0a..94b142684f 100644 --- a/job.c +++ b/job.c @@ -380,6 +380,8 @@ void job_ref(Job *job) void job_unref(Job *job) { +

[PATCH v3 23/25] block-backend-common.h: split function pointers in BlockDevOps

2021-10-12 Thread Emanuele Giuseppe Esposito
Assertions in the callers of the funciton pointrs are already added by previous patches. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- include/sysemu/block-backend-common.h | 28 ++- 1 file changed, 23 insertions(+), 5 deletions(-) diff

[PATCH v3 22/25] block_int-common.h: assertions in the callers of BdrvChildClass function pointers

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- block.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/block.c b/block.c index 40c4729b8d..da80e89ad4 100644 --- a/block.c +++ b/block.c @@ -1462,6 +1462,7 @@ const BdrvChildClass child_of_bds = {

[PATCH v3 24/25] job.h: split function pointers in JobDriver

2021-10-12 Thread Emanuele Giuseppe Esposito
The job API will be handled separately in another serie. Signed-off-by: Emanuele Giuseppe Esposito --- include/qemu/job.h | 16 1 file changed, 16 insertions(+) diff --git a/include/qemu/job.h b/include/qemu/job.h index 6e67b6977f..7e9e59f4b8 100644 --- a/include/qemu/job.h

[PATCH v3 15/25] assertions for blockdev.h global state API

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Paolo Bonzini Reviewed-by: Stefan Hajnoczi --- block/block-backend.c | 2 ++ blockdev.c| 12 2 files changed, 14 insertions(+) diff --git a/block/block-backend.c b/block/block-backend.c index

[PATCH v3 21/25] block_int-common.h: split function pointers in BdrvChildClass

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- include/block/block_int-common.h | 51 1 file changed, 32 insertions(+), 19 deletions(-) diff --git a/include/block/block_int-common.h b/include/block/block_int-common.h index

[PATCH v3 16/25] include/block/snapshot: global state API + assertions

2021-10-12 Thread Emanuele Giuseppe Esposito
Snapshots run also under the BQL lock, so they all are in the global state API. The aiocontext lock that they hold is currently an overkill and in future could be removed. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Paolo Bonzini Reviewed-by: Stefan Hajnoczi --- block/snapshot.c

[PATCH v3 18/25] block/coroutines: I/O API

2021-10-12 Thread Emanuele Giuseppe Esposito
block coroutines functions run in different aiocontext, and are not protected by the BQL. Therefore are I/O. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Paolo Bonzini Reviewed-by: Stefan Hajnoczi --- block/coroutines.h | 7 +++ 1 file changed, 7 insertions(+) diff --git

[PATCH v3 20/25] block_int-common.h: assertion in the callers of BlockDriver function pointers

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- block.c | 17 + 1 file changed, 17 insertions(+) diff --git a/block.c b/block.c index 94bff5c757..40c4729b8d 100644 --- a/block.c +++ b/block.c @@ -1074,6 +1074,7 @@ int

[PATCH v3 19/25] block_int-common.h: split function pointers in BlockDriver

2021-10-12 Thread Emanuele Giuseppe Esposito
Similar to the header split, also the function pointers in BlockDriver can be split in I/O and global state. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- include/block/block_int-common.h | 458 --- 1 file changed, 237 insertions(+), 221

[PATCH v3 17/25] block/copy-before-write.h: global state API + assertions

2021-10-12 Thread Emanuele Giuseppe Esposito
copy-before-write functions always run under BQL lock. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Paolo Bonzini --- block/copy-before-write.c | 2 ++ block/copy-before-write.h | 7 +++ 2 files changed, 9 insertions(+) diff --git a/block/copy-before-write.c

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

2021-10-12 Thread Emanuele Giuseppe Esposito
blockdev functions run always under the BQL lock. Signed-off-by: Emanuele Giuseppe Esposito --- include/sysemu/blockdev.h | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/include/sysemu/blockdev.h b/include/sysemu/blockdev.h index 960b54d320..cc9dfb5181 100644

[PATCH v3 12/25] assertions for blockob.h global state API

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- blockjob.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/blockjob.c b/blockjob.c index fbd6c7d873..4982f6a2b5 100644 --- a/blockjob.c +++ b/blockjob.c @@ -61,6 +61,7 @@ static bool is_block_job(Job

[PATCH v3 11/25] include/block/blockjob.h: global state API

2021-10-12 Thread Emanuele Giuseppe Esposito
blockjob functions run always under the BQL lock. Signed-off-by: Emanuele Giuseppe Esposito --- include/block/blockjob.h | 9 + 1 file changed, 9 insertions(+) diff --git a/include/block/blockjob.h b/include/block/blockjob.h index d200f33c10..fa0c3f7a47 100644 ---

[PATCH v3 09/25] include/block/blockjob_int.h: split header into I/O and GS API

2021-10-12 Thread Emanuele Giuseppe Esposito
Since the I/O functions are not many, keep a single file. Also split the function pointers in BlockJobDriver. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- include/block/blockjob_int.h | 28 1 file changed, 28 insertions(+) diff --git

[PATCH v3 06/25] include/block/block_int: split header into I/O and global state API

2021-10-12 Thread Emanuele Giuseppe Esposito
Similarly to the previous patch, split block_int.h in block_int-io.h and block_int-global-state.h block_int-common.h contains the structures shared between the two headers, and the functions that can't be categorized as I/O or global state. Assertions are added in the next patch. Signed-off-by:

[PATCH v3 13/25] include/sysemu/blockdev.h: move drive_add and inline drive_def

2021-10-12 Thread Emanuele Giuseppe Esposito
drive_add is only used in softmmu/vl.c, so it can be a static function there, and drive_def is only a particular use case of qemu_opts_parse_noisily, so it can be inlined. Also remove drive_mark_claimed_by_board, as it is only defined but not implemented (nor used) anywhere. This also helps

[PATCH v3 10/25] assertions for blockjob_int.h

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- blockjob.c | 4 1 file changed, 4 insertions(+) diff --git a/blockjob.c b/blockjob.c index 4bad1408cb..fbd6c7d873 100644 --- a/blockjob.c +++ b/blockjob.c @@ -83,6 +83,7 @@ BlockJob *block_job_get(const char *id)

[PATCH v3 08/25] block: introduce assert_bdrv_graph_writable

2021-10-12 Thread Emanuele Giuseppe Esposito
We want to be sure that the functions that write the child and parent list of a bs are under BQL and drain. BQL prevents from concurrent writings from the GS API, while drains protect from I/O. TODO: drains are missing in some functions using this assert. Therefore a proper assertion will fail.

[PATCH v3 07/25] assertions for block_int global state API

2021-10-12 Thread Emanuele Giuseppe Esposito
Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- block.c | 17 + block/backup.c | 1 + block/block-backend.c | 3 +++ block/commit.c | 2 ++ block/dirty-bitmap.c| 1 +

[PATCH v3 04/25] include/sysemu/block-backend: split header into I/O and global state (GS) API

2021-10-12 Thread Emanuele Giuseppe Esposito
Similarly to the previous patches, split block-backend.h in block-backend-io.h and block-backend-global-state.h In addition, remove "block/block.h" include as it seems it is not necessary anymore, together with "qemu/iov.h" block-backend-common.h contains the structures shared between the two

[PATCH v3 03/25] assertions for block global state API

2021-10-12 Thread Emanuele Giuseppe Esposito
All the global state (GS) API functions will check that qemu_in_main_thread() returns true. If not, it means that the safety of BQL cannot be guaranteed, and they need to be moved to I/O. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- block.c| 136

[PATCH v3 05/25] block/block-backend.c: assertions for block-backend

2021-10-12 Thread Emanuele Giuseppe Esposito
All the global state (GS) API functions will check that qemu_in_main_thread() returns true. If not, it means that the safety of BQL cannot be guaranteed, and they need to be moved to I/O. Signed-off-by: Emanuele Giuseppe Esposito Reviewed-by: Stefan Hajnoczi --- block/block-backend.c | 90

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

2021-10-12 Thread Emanuele Giuseppe Esposito
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 functions running under BQL also take care of modifying the block graph, by using drain

[PATCH v3 02/25] include/block/block: split header into I/O and global state API

2021-10-12 Thread Emanuele Giuseppe Esposito
block.h currently contains a mix of functions: some of them run under the BQL and modify the block layer graph, others are instead thread-safe and perform I/O in iothreads. It is not easy to understand which function is part of which group (I/O vs GS), and this patch aims to clarify it. The "GS"

[PATCH v3 01/25] main-loop.h: introduce qemu_in_main_thread()

2021-10-12 Thread Emanuele Giuseppe Esposito
When invoked from the main loop, this function is the same as qemu_mutex_iothread_locked, and returns true if the BQL is held. When invoked from iothreads or tests, it returns true only if the current AioContext is the Main Loop. This essentially just extends qemu_mutex_iothread_locked to work

[PATCH] block/vpc: Add a sanity check that fixed-size images have the right type

2021-10-12 Thread Thomas Huth
The code in vpc.c uses BDRVVPCState->footer.type in various places to decide whether the image is a fixed-size (VHD_FIXED) or a dynamic (VHD_DYNAMIC) image. However, we never check that this field really contains VHD_FIXED if we detected a fixed size image in vpc_open(), so a wrong value here

Re: [PATCH v7 7/8] qmp: add QMP command x-debug-virtio-queue-element

2021-10-12 Thread Jonah Palmer
On 10/7/21 9:27 AM, Eric Blake wrote: On Tue, Oct 05, 2021 at 12:45:52PM -0400, Jonah Palmer wrote: From: Laurent Vivier This new command shows the information of a VirtQueue element. Signed-off-by: Jonah Palmer --- +++ b/qapi/virtio.json +## +# @VirtioRingAvail: +# +# @flags: VRingAvail

Re: [PATCH v7 1/8] virtio: drop name parameter for virtio_init()

2021-10-12 Thread Jonah Palmer
On 10/5/21 5:18 PM, Eric Blake wrote: On Tue, Oct 05, 2021 at 12:45:46PM -0400, Jonah Palmer wrote: This patch drops the name parameter for the virtio_init function. The pair between the numeric device ID and the string device ID (name) of a virtio device already exists, but not in a way that

Re: [PATCH] qcow2: Silence clang -m32 compiler warning

2021-10-12 Thread Hanna Reitz
On 11.10.21 18:24, Eric Blake wrote: On Mon, Oct 11, 2021 at 05:50:31PM +0200, Hanna Reitz wrote: With -m32, size_t is generally only a uint32_t. That makes clang complain that in the assertion assert(qiov->size <= INT64_MAX); the range of the type of qiov->size (size_t) is too small for

Re: [PATCH 04/15] pcie: Add callback preceding SR-IOV VFs update

2021-10-12 Thread Michael S. Tsirkin
On Thu, Oct 07, 2021 at 06:23:55PM +0200, Lukasz Maniak wrote: > PCIe devices implementing SR-IOV may need to perform certain actions > before the VFs are unrealized or vice versa. > > Signed-off-by: Lukasz Maniak Callbacks are annoying and easy to misuse though. VFs are enabled through a