Re: [PATCH v7 00/11] hw/block/nvme: Support Namespace Types and Zoned Namespace Command Set

2020-10-19 Thread Niklas Cassel
On Mon, Oct 19, 2020 at 11:17:15AM +0900, Dmitry Fomichev wrote: (snip) > > Dmitry Fomichev (9): > hw/block/nvme: Add Commands Supported and Effects log > hw/block/nvme: Generate namespace UUIDs > hw/block/nvme: Support Zoned Namespace Command Set > hw/block/nvme: Introduce max active

[PATCH] hw/block/nvme: fix aer logic

2020-10-19 Thread Klaus Jensen
From: Klaus Jensen Fix same flawed logic in the handling of event masking. Before this patch the device would erroneously a) queue up events even though that event type is masked b) issue AERs for queued events in response to events getting cleared c) respond to new AERs with queued

Re: [PATCH v2 9/9] block: check availablity for preadv/pwritev on mac

2020-10-19 Thread Thomas Huth
On 19/10/2020 03.39, Joelle van Dyne wrote: > From: osy That "From:" line looks wrong ... could you please fix the "Author" of your patches / your git config? > macOS 11/iOS 14 added preadv/pwritev APIs. Due to weak linking, configure > will succeed with CONFIG_PREADV even when targeting a

Re: [PATCH v4 1/7] keyval: Fix and clarify grammar

2020-10-19 Thread Markus Armbruster
Eric Blake writes: > On 10/11/20 2:34 AM, Markus Armbruster wrote: >> The grammar has a few issues: >> * key-fragment = / [^=,.]* / >>Prose restricts key fragments: they "must be valid QAPI names or >>consist only of decimal digits". Technically, '' consists only of >>decimal

Re: [PATCH v7 05/11] hw/block/nvme: Support Zoned Namespace Command Set

2020-10-19 Thread Klaus Jensen
On Oct 19 11:17, Dmitry Fomichev wrote: > The emulation code has been changed to advertise NVM Command Set when > "zoned" device property is not set (default) and Zoned Namespace > Command Set otherwise. > > Define values and structures that are needed to support Zoned > Namespace Command Set

Re: [PATCH v3 01/13] block: return status from bdrv_append and friends

2020-10-19 Thread Kevin Wolf
Am 16.10.2020 um 19:10 hat Vladimir Sementsov-Ogievskiy geschrieben: > The recommended use of qemu error api assumes returning status together > with setting errp and avoid void functions with errp parameter. Let's > improve bdrv_append and some friends to reduce error-propagation > overhead in

Re: [PATCH v1 0/2] Add timeout mechanism to qmp actions

2020-10-19 Thread Zhenyu Ye
Hi Stefan, On 2020/10/13 18:00, Stefan Hajnoczi wrote: > > Sorry, I lost track of this on-going email thread. > > Thanks for the backtrace. It shows the io_submit call is done while the > AioContext lock is held. The monitor thread is waiting for the > IOThread's AioContext lock. vcpus threads

Re: [PATCH v3 12/13] block/qcow2: simplify qcow2_co_invalidate_cache()

2020-10-19 Thread Kevin Wolf
Am 16.10.2020 um 19:10 hat Vladimir Sementsov-Ogievskiy geschrieben: > qcow2_do_open correctly sets errp on each failure path. So, we can > simplify code in qcow2_co_invalidate_cache() and drop explicit error > propagation. qcow2_update_options_prepare() can return -EINVAL without setting errp:

Re: [PATCH v4 4/7] keyval: Parse help options

2020-10-19 Thread Markus Armbruster
Kevin Wolf writes: > Am 11.10.2020 um 09:35 hat Markus Armbruster geschrieben: >> From: Kevin Wolf >> >> This adds a special meaning for 'help' and '?' as options to the keyval >> parser. Instead of being an error (because of a missing value) or a >> value for an implied key, they now request

Re: [PATCH v4 4/7] keyval: Parse help options

2020-10-19 Thread Markus Armbruster
Eric Blake writes: > On 10/11/20 2:35 AM, Markus Armbruster wrote: >> From: Kevin Wolf >> This adds a special meaning for 'help' and '?' as options to the >> keyval >> parser. Instead of being an error (because of a missing value) or a >> value for an implied key, they now request help, which

Re: [PATCH v2 03/15] python: add VERSION file

2020-10-19 Thread Daniel P . Berrangé
On Mon, Oct 19, 2020 at 11:45:09AM +0200, Andrea Bolognani wrote: > On Wed, 2020-10-14 at 10:29 -0400, John Snow wrote: > > Python infrastructure as it exists today is not capable reliably of > > single-sourcing a package version from a parent directory. The authors > > of pip are working to

Re: [PATCH v7 05/11] hw/block/nvme: Support Zoned Namespace Command Set

2020-10-19 Thread Klaus Jensen
On Oct 19 11:17, Dmitry Fomichev wrote: > diff --git a/hw/block/nvme-ns.h b/hw/block/nvme-ns.h > index d6b2808b97..170cbb8cdc 100644 > --- a/hw/block/nvme-ns.h > +++ b/hw/block/nvme-ns.h > @@ -34,6 +45,18 @@ typedef struct NvmeNamespace { > const uint32_t *iocs; > uint8_t csi; > >

Re: [PATCH v4 0/7] qemu-storage-daemon: Remove QemuOpts from --object

2020-10-19 Thread Markus Armbruster
Kevin Wolf writes: > Am 11.10.2020 um 09:34 hat Markus Armbruster geschrieben: >> This replaces the QemuOpts-based help code for --object in the storage >> daemon with code based on the keyval parser. >> >> Review of v3 led me to preexisting issues. Instead of posting my >> fixes separately,

Re: [PATCH] qemu-img: add support for rate limit in qemu-img convert

2020-10-19 Thread Alberto Garcia
On Sun 18 Oct 2020 08:34:39 AM CEST, Zhengui li wrote: > @@ -2729,6 +2757,10 @@ out: > qemu_opts_del(opts); > qemu_opts_free(create_opts); > qemu_opts_del(sn_opts); > +if (s.target && rate_limit && > +blk_get_public(s.target)->throttle_group_member.throttle_state) { > +

Re: [PATCH v7 08/11] hw/block/nvme: Add injection of Offline/Read-Only zones

2020-10-19 Thread Klaus Jensen
On Oct 19 11:17, Dmitry Fomichev wrote: > ZNS specification defines two zone conditions for the zones that no > longer can function properly, possibly because of flash wear or other > internal fault. It is useful to be able to "inject" a small number of > such zones for testing purposes. > > This

Re: [PATCH v2 03/15] python: add VERSION file

2020-10-19 Thread Andrea Bolognani
On Wed, 2020-10-14 at 10:29 -0400, John Snow wrote: > Python infrastructure as it exists today is not capable reliably of > single-sourcing a package version from a parent directory. The authors > of pip are working to correct this, but as of today this is not possible > to my knowledge. > > The

[PATCH] hw/block/nvme: fix prp mapping status codes

2020-10-19 Thread Klaus Jensen
From: Gollu Appalanaidu Differentiate between missing PRPs and misaligned PRPs, return the relevant status code and streamline the trace event naming. See NVMe Express v1.3d, Section 4.3 ("Physical Region Page Entry and List"). Signed-off-by: Gollu Appalanaidu Signed-off-by: Klaus Jensen ---

Re: [PATCH] qemu-img: add support for rate limit in qemu-img commit

2020-10-19 Thread Alberto Garcia
On Sun 18 Oct 2020 08:33:59 AM CEST, Zhengui li wrote: Hello, > diff --git a/qemu-img-cmds.hx b/qemu-img-cmds.hx > index b89c019..ed55b76 100644 > --- a/qemu-img-cmds.hx > +++ b/qemu-img-cmds.hx > @@ -34,9 +34,9 @@ SRST > ERST > > DEF("commit", img_commit, > -"commit [--object objectdef]

Re: [PATCH v3 02/13] block: use return status of bdrv_append()

2020-10-19 Thread Kevin Wolf
Am 16.10.2020 um 19:10 hat Vladimir Sementsov-Ogievskiy geschrieben: > Now bdrv_append returns status and we can drop all the local_err things > around it. > > Signed-off-by: Vladimir Sementsov-Ogievskiy > Reviewed-by: Greg Kurz > Reviewed-by: Alberto Garcia > --- > block.c

Re: [PATCH v1 0/2] Add timeout mechanism to qmp actions

2020-10-19 Thread Paolo Bonzini
On 19/10/20 14:40, Zhenyu Ye wrote: > The kernel backtrace for io_submit in GUEST is: > > guest# ./offcputime -K -p `pgrep -nx fio` > b'finish_task_switch' > b'__schedule' > b'schedule' > b'io_schedule' > b'blk_mq_get_tag' >

[PATCH] vhost-user: fix incorrect print type

2020-10-19 Thread Zhengui li
fix incorrect print type. --- hw/virtio/vhost-user.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c index 9c5b4f7..db563bd 100644 --- a/hw/virtio/vhost-user.c +++ b/hw/virtio/vhost-user.c @@ -308,7 +308,7 @@ static

[PATCH] virtio-gpu: fix incorrect print type

2020-10-19 Thread Zhengui li
fix incorrect print type. --- hw/display/virtio-gpu.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c index 90be4e3..d785d88 100644 --- a/hw/display/virtio-gpu.c +++ b/hw/display/virtio-gpu.c

[PATCH] vhost-user-gpu: incorrect print type

2020-10-19 Thread Zhengui li
fix incorrect print type. --- contrib/vhost-user-gpu/vhost-user-gpu.c | 34 - 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/contrib/vhost-user-gpu/vhost-user-gpu.c b/contrib/vhost-user-gpu/vhost-user-gpu.c index a019d0a..ee2bf59 100644 ---

Re: [PATCH] virtio-gpu: fix incorrect print type

2020-10-19 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1603114292-10332-1-git-send-email-lizhen...@huawei.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1603114292-10332-1-git-send-email-lizhen...@huawei.com Subject: [PATCH]

Re: [PATCH] vfio: fix incorrect print type

2020-10-19 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1603114337-28056-1-git-send-email-lizhen...@huawei.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1603114337-28056-1-git-send-email-lizhen...@huawei.com Subject: [PATCH]

[PATCH] virtio-gpu: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/display/virtio-gpu.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/hw/display/virtio-gpu.c

Re: [PATCH v2] hw/block/nand: Decommission the NAND museum

2020-10-19 Thread Peter Maydell
On Tue, 15 Sep 2020 at 18:52, Philippe Mathieu-Daudé wrote: > > This is the QEMU equivalent of this Linux commit (but 7 years later): > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=f7025a43a9da2 > > The MTD subsystem has its own small museum of ancient NANDs >

Re: [PATCH v3 02/13] block: use return status of bdrv_append()

2020-10-19 Thread Kevin Wolf
Am 19.10.2020 um 17:45 hat Markus Armbruster geschrieben: > Kevin Wolf writes: > > > Am 16.10.2020 um 19:10 hat Vladimir Sementsov-Ogievskiy geschrieben: > >> Now bdrv_append returns status and we can drop all the local_err things > >> around it. > >> > >> Signed-off-by: Vladimir

[PATCH 1/4] qdev: Fix two typos

2020-10-19 Thread Maxim Levitsky
Signed-off-by: Maxim Levitsky --- include/hw/qdev-core.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/hw/qdev-core.h b/include/hw/qdev-core.h index 868973319e..3761186804 100644 --- a/include/hw/qdev-core.h +++ b/include/hw/qdev-core.h @@ -163,8 +163,8 @@

Re: [PATCH] vhost-user-gpu: incorrect print type

2020-10-19 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1603114196-22776-1-git-send-email-lizhen...@huawei.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1603114196-22776-1-git-send-email-lizhen...@huawei.com Subject: [PATCH]

[PATCH] virtio-iommu: fix incorrect print type

2020-10-19 Thread Zhengui li
fix incorrect print type. --- hw/virtio/virtio-iommu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/virtio/virtio-iommu.c b/hw/virtio/virtio-iommu.c index 21ec63b..bd6ce44 100644 --- a/hw/virtio/virtio-iommu.c +++ b/hw/virtio/virtio-iommu.c @@ -632,7 +632,7 @@

[PATCH] vhost-user-gpu: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- contrib/vhost-user-gpu/vhost-user-gpu.c | 34 - 1 file changed, 17 insertions(+), 17 deletions(-) diff --git

[PATCH] vhost-user-scsi: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- contrib/vhost-user-scsi/vhost-user-scsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/vhost-user-scsi/vhost-user-scsi.c

Re: [PATCH] hw/block/nvme: fix aer logic

2020-10-19 Thread Keith Busch
On Mon, Oct 19, 2020 at 08:54:16AM +0200, Klaus Jensen wrote: > @@ -844,6 +838,12 @@ static void nvme_enqueue_event(NvmeCtrl *n, uint8_t > event_type, > return; > } > > +/* ignore if masked (cqe posted, but event not cleared) */ > +if (n->aer_mask & (1 << event_type)) { >

[PATCH 4/4] iotests: rewrite iotest 240 in python

2020-10-19 Thread Maxim Levitsky
The recent changes that brought RCU delayed device deletion, broke few tests and this test breakage went unnoticed. Fix this test by rewriting it in python (which allows to wait for DEVICE_DELETED events before continuing). Signed-off-by: Maxim Levitsky --- tests/qemu-iotests/240 | 228

[PATCH] virtio-iommu: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/virtio/virtio-iommu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/virtio/virtio-iommu.c b/hw/virtio/virtio-iommu.c index

Re: [PATCH v2 0/3] hw/ssi: Rename SSI 'slave' as 'peripheral'

2020-10-19 Thread Philippe Mathieu-Daudé
Ping for review? On 10/12/20 2:49 PM, Philippe Mathieu-Daudé wrote: Since v1: - Fixed patch #1 subject (Kevin) In order to use inclusive terminology, rename SSI 'slave' as 'peripheral', following the resolution Paolo pointed in [*]:

[PATCH 3/4] libqtest: fix memory leak in the qtest_qmp_event_ref

2020-10-19 Thread Maxim Levitsky
The g_list_remove_link doesn't free the link element, opposed to what I thought. Switch to g_list_delete_link that does free it. Also refactor the code a bit. Thanks for Max Reitz for helping me with this. Signed-off-by: Maxim Levitsky --- tests/qtest/libqtest.c | 11 --- 1 file

[PATCH] vfio: fix incorrect print type

2020-10-19 Thread Zhengui li
fix incorrect print type. --- hw/vfio/common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/vfio/common.c b/hw/vfio/common.c index 13471ae..acc3356 100644 --- a/hw/vfio/common.c +++ b/hw/vfio/common.c @@ -203,7 +203,7 @@ void vfio_region_write(void *opaque, hwaddr

[PATCH] vhost-user-scsi: fix incorrect print type

2020-10-19 Thread Zhengui li
fix incorrect print type. --- contrib/vhost-user-scsi/vhost-user-scsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/vhost-user-scsi/vhost-user-scsi.c b/contrib/vhost-user-scsi/vhost-user-scsi.c index 3c91238..1527ffd 100644 ---

Re: [PATCH v7 05/11] hw/block/nvme: Support Zoned Namespace Command Set

2020-10-19 Thread Klaus Jensen
On Oct 19 11:50, Klaus Jensen wrote: > On Oct 19 11:17, Dmitry Fomichev wrote: > > +static bool nvme_finalize_zoned_write(NvmeNamespace *ns, NvmeRequest *req, > > + bool failed) > > +{ > > +NvmeRwCmd *rw = (NvmeRwCmd *)>cmd; > > +NvmeZone *zone; > > +

Re: [PATCH] hw/block/nvme: fix prp mapping status codes

2020-10-19 Thread Keith Busch
On Mon, Oct 19, 2020 at 01:30:39PM +0200, Klaus Jensen wrote: > @@ -328,7 +328,7 @@ static uint16_t nvme_map_prp(NvmeCtrl *n, uint64_t prp1, > uint64_t prp2, > trace_pci_nvme_map_prp(trans_len, len, prp1, prp2, num_prps); > > if (unlikely(!prp1)) { > -

Re: [PATCH v2 03/15] python: add VERSION file

2020-10-19 Thread John Snow
On 10/19/20 6:02 AM, Daniel P. Berrangé wrote: On Mon, Oct 19, 2020 at 11:45:09AM +0200, Andrea Bolognani wrote: On Wed, 2020-10-14 at 10:29 -0400, John Snow wrote: Python infrastructure as it exists today is not capable reliably of single-sourcing a package version from a parent directory.

Re: [PATCH] vhost-user-scsi: fix incorrect print type

2020-10-19 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1603114225-22628-1-git-send-email-lizhen...@huawei.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1603114225-22628-1-git-send-email-lizhen...@huawei.com Subject: [PATCH]

Re: [PATCH] virtio-iommu: fix incorrect print type

2020-10-19 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1603114311-7392-1-git-send-email-lizhen...@huawei.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1603114311-7392-1-git-send-email-lizhen...@huawei.com Subject: [PATCH]

Re: [PATCH] vhost-user: fix incorrect print type

2020-10-19 Thread no-reply
Patchew URL: https://patchew.org/QEMU/1603114272-25004-1-git-send-email-lizhen...@huawei.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1603114272-25004-1-git-send-email-lizhen...@huawei.com Subject: [PATCH]

Re: [PATCH] vfio: fix incorrect print type

2020-10-19 Thread Alex Williamson
On Mon, 19 Oct 2020 13:32:17 + Zhengui li wrote: > fix incorrect print type. Why is it incorrect, describe your change. Patches must include a Signed-off-by to adhere to the developer's certificate of origin. Thanks, Alex > --- > hw/vfio/common.c | 4 ++-- > 1 file changed, 2

[PATCH] vfio: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/vfio/common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/vfio/common.c b/hw/vfio/common.c index 13471ae..acc3356 100644 ---

[PATCH] vhost-user: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/virtio/vhost-user.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c index

Re: [PATCH v3 02/13] block: use return status of bdrv_append()

2020-10-19 Thread Markus Armbruster
Kevin Wolf writes: > Am 16.10.2020 um 19:10 hat Vladimir Sementsov-Ogievskiy geschrieben: >> Now bdrv_append returns status and we can drop all the local_err things >> around it. >> >> Signed-off-by: Vladimir Sementsov-Ogievskiy >> Reviewed-by: Greg Kurz >> Reviewed-by: Alberto Garcia >> ---

Re: Plans to bring QMP 'x-blockdev-reopen' out of experimental?

2020-10-19 Thread Alberto Garcia
On Tue 06 Oct 2020 11:10:01 AM CEST, Kashyap Chamarthy wrote: > Hi, folks > > If this was already discussed on the list, please point me to the > thread. I took a quick look at my local archives, I didn't find any, > besides patches to tests. I think this is the last time that I was discussed:

[PATCH 2/4] libqtest: fix the order of buffered events

2020-10-19 Thread Maxim Levitsky
By a mistake I added the pending events in a wrong order. Fix this by using g_list_append. Signed-off-by: Maxim Levitsky --- tests/qtest/libqtest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qtest/libqtest.c b/tests/qtest/libqtest.c index 08929f5ff6..bd96cb6fdd

[PATCH 0/4] Assorted fixes to tests that were broken by recent scsi changes

2020-10-19 Thread Maxim Levitsky
Just few fixes, for some stuff that slipped thorough. Tested with make check, and qcow2/raw/nbd iotests. Best regards, Maxim Levitsky Maxim Levitsky (4): qdev: Fix two typos libqtest: fix the order of buffered events libqtest: fix memory leak in the qtest_qmp_event_ref iotests:

Re: [PATCH v6 01/10] block: push error reporting into bdrv_all_*_snapshot functions

2020-10-19 Thread Eric Blake
On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: The bdrv_all_*_snapshot functions return a BlockDriverState pointer for the invalid backend, which the callers then use to report an error message. In some cases multiple callers are reporting the same error message, but with slightly different

[PATCH v2] hw/block/nvme: fix prp mapping status codes

2020-10-19 Thread Klaus Jensen
From: Gollu Appalanaidu Address 0 is not an invalid address. Remove those invalikd checks. Unaligned PRP2 and PRP list entries should result in Invalid PRP Offset status code and not Invalid Field. Fix that. See NVMe Express v1.3d, Section 4.3 ("Physical Region Page Entry and List").

Re: [PATCH v7 02/11] hw/block/nvme: Generate namespace UUIDs

2020-10-19 Thread Klaus Jensen
On Oct 19 11:17, Dmitry Fomichev wrote: > In NVMe 1.4, a namespace must report an ID descriptor of UUID type > if it doesn't support EUI64 or NGUID. Add a new namespace property, > "uuid", that provides the user the option to either specify the UUID > explicitly or have a UUID generated

Re: Plans to bring QMP 'x-blockdev-reopen' out of experimental?

2020-10-19 Thread Alberto Garcia
On Mon 19 Oct 2020 05:56:56 PM CEST, Alberto Garcia wrote: > And this one in particular: > >https://lists.gnu.org/archive/html/qemu-block/2020-02/msg00601.html I forgot to add, we still don't support changing bs->file with this command, so I guess that would be one blocker? There's no other

Re: qcow2 overlay performance

2020-10-19 Thread Alberto Garcia
On Thu 27 Aug 2020 06:29:15 PM CEST, Yoonho Park wrote: > Below is the data with the cache disabled ("virsh attach-disk ... --cache > none"). I added the previous data for reference. Overall, random read > performance was not affected significantly. This makes sense because a > cache is probably

Re: [PATCH] hw/block/nvme: fix prp mapping status codes

2020-10-19 Thread Klaus Jensen
On Oct 19 09:34, Keith Busch wrote: > On Mon, Oct 19, 2020 at 01:30:39PM +0200, Klaus Jensen wrote: > > @@ -328,7 +328,7 @@ static uint16_t nvme_map_prp(NvmeCtrl *n, uint64_t > > prp1, uint64_t prp2, > > trace_pci_nvme_map_prp(trans_len, len, prp1, prp2, num_prps); > > > > if

Re: [PATCH v2] hw/block/nvme: fix prp mapping status codes

2020-10-19 Thread Keith Busch
On Mon, Oct 19, 2020 at 07:35:38PM +0200, Klaus Jensen wrote: > From: Gollu Appalanaidu > > Address 0 is not an invalid address. Remove those invalikd checks. > > Unaligned PRP2 and PRP list entries should result in Invalid PRP Offset > status code and not Invalid Field. Fix that. > > See NVMe

Re: [PATCH v7 02/11] hw/block/nvme: Generate namespace UUIDs

2020-10-19 Thread Keith Busch
On Mon, Oct 19, 2020 at 11:17:17AM +0900, Dmitry Fomichev wrote: > In NVMe 1.4, a namespace must report an ID descriptor of UUID type > if it doesn't support EUI64 or NGUID. Add a new namespace property, > "uuid", that provides the user the option to either specify the UUID > explicitly or have a

Re: [PATCH] hw/block/nvme: fix aer logic

2020-10-19 Thread Klaus Jensen
On Oct 19 09:43, Keith Busch wrote: > On Mon, Oct 19, 2020 at 08:54:16AM +0200, Klaus Jensen wrote: > > @@ -844,6 +838,12 @@ static void nvme_enqueue_event(NvmeCtrl *n, uint8_t > > event_type, > > return; > > } > > > > +/* ignore if masked (cqe posted, but event not cleared)

Re: [PATCH v7 01/11] hw/block/nvme: Add Commands Supported and Effects log

2020-10-19 Thread Keith Busch
On Mon, Oct 19, 2020 at 11:17:16AM +0900, Dmitry Fomichev wrote: > This log page becomes necessary to implement to allow checking for > Zone Append command support in Zoned Namespace Command Set. > > This commit adds the code to report this log page for NVM Command > Set only. The parts that are

Re: [PATCH v4 4/7] nbd: Update qapi to support exporting multiple bitmaps

2020-10-19 Thread Eric Blake
On 10/14/20 7:15 AM, Vladimir Sementsov-Ogievskiy wrote: 10.10.2020 00:55, Eric Blake wrote: Since 'nbd-server-add' is deprecated, and 'block-export-add' is new to 5.2, we can still tweak the interface.  Allowing 'bitmaps':['str'] is nicer than 'bitmap':'str'.  This wires up the qapi and

[PATCH v2 1/6] vhost-user-gpu: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- contrib/vhost-user-gpu/vhost-user-gpu.c | 34 - 1 file changed, 17 insertions(+), 17 deletions(-) diff --git

[PATCH v2 2/6] vhost-user-scsi: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- contrib/vhost-user-scsi/vhost-user-scsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/vhost-user-scsi/vhost-user-scsi.c

[PATCH v2 4/6] virtio-gpu: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/display/virtio-gpu.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/hw/display/virtio-gpu.c

[PATCH v2 3/6] vhost-user: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/virtio/vhost-user.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c index

[PATCH v2 5/6] virtio-iommu: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/virtio/virtio-iommu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/virtio/virtio-iommu.c b/hw/virtio/virtio-iommu.c index

[PATCH v2 6/6] vfio: fix incorrect print type

2020-10-19 Thread Zhengui li
The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/vfio/common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/vfio/common.c b/hw/vfio/common.c index 13471ae..acc3356 100644 ---

Re: [PATCH] qemu-img: add support for rate limit in qemu-img convert

2020-10-19 Thread Eric Blake
On 10/18/20 1:34 AM, Zhengui li wrote: From: Zhengui Currently, there is no rate limit for qemu-img convert. This may cause the task of qemu-img convert to consume all the bandwidth of the storage. This will affect the IO performance of other processes and virtual machines under shared

Re: [PATCH v6 05/10] block: rename and alter bdrv_all_find_snapshot semantics

2020-10-19 Thread Eric Blake
On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: Currently bdrv_all_find_snapshot() will return 0 if it finds a snapshot, -1 if an error occurs, or if it fails to find a snapshot. New callers to be added want to distinguish between the error scenario and failing to find a snapshot. Rename it to

Re: [PATCH v7 01/11] hw/block/nvme: Add Commands Supported and Effects log

2020-10-19 Thread Klaus Jensen
On Oct 19 11:17, Dmitry Fomichev wrote: > This log page becomes necessary to implement to allow checking for > Zone Append command support in Zoned Namespace Command Set. > > This commit adds the code to report this log page for NVM Command > Set only. The parts that are specific to zoned

Re: [PATCH v7 03/11] hw/block/nvme: Add support for Namespace Types

2020-10-19 Thread Klaus Jensen
On Oct 19 11:17, Dmitry Fomichev wrote: > From: Niklas Cassel > > Define the structures and constants required to implement > Namespace Types support. > > Namespace Types introduce a new command set, "I/O Command Sets", > that allows the host to retrieve the command sets associated with > a

Re: [PATCH v6 02/10] migration: stop returning errno from load_snapshot()

2020-10-19 Thread Eric Blake
On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: None of the callers care about the errno value since there is a full Error object populated. This gives consistency with save_snapshot() which already just returns -1. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrangé ---

Re: [PATCH v6 03/10] block: add ability to specify list of blockdevs during snapshot

2020-10-19 Thread Eric Blake
On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: When running snapshot operations, there are various rules for which blockdevs are included/excluded. While this provides reasonable default behaviour, there are scenarios that are not well handled by the default logic. Some of the conditions do not

Re: [PATCH v6 06/10] migration: control whether snapshots are ovewritten

2020-10-19 Thread Eric Blake
On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: The traditional HMP "savevm" command will overwrite an existing snapshot if it already exists with the requested name. This new flag allows this to be controlled allowing for safer behaviour with a future QMP command. Signed-off-by: Daniel P.

Re: [PATCH 1/4] qdev: Fix two typos

2020-10-19 Thread Philippe Mathieu-Daudé
On 10/19/20 6:36 PM, Maxim Levitsky wrote: Signed-off-by: Maxim Levitsky --- include/hw/qdev-core.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/hw/qdev-core.h b/include/hw/qdev-core.h index 868973319e..3761186804 100644 --- a/include/hw/qdev-core.h +++

Re: [PATCH v7 03/11] hw/block/nvme: Add support for Namespace Types

2020-10-19 Thread Keith Busch
On Mon, Oct 19, 2020 at 11:17:18AM +0900, Dmitry Fomichev wrote: > +QEMU_BUILD_BUG_ON(sizeof(NvmeIdNsDescr) != 4); ... > QEMU_BUILD_BUG_ON(sizeof(NvmeIdNsDescr) != 4); You've got duplicate sizeof checks for the NvmeIdNsDescr. Otherwise, the patch looks fine.

Re: [PATCH v7 04/11] hw/block/nvme: Support allocated CNS command variants

2020-10-19 Thread Keith Busch
On Mon, Oct 19, 2020 at 11:17:19AM +0900, Dmitry Fomichev wrote: > Add a new Boolean namespace property, "attached", to provide the most > basic namespace attachment support. The default value for this new > property is true. Also, implement the logic in the new CNS values to > include/exclude

Re: [PATCH] virtio-iommu: fix incorrect print type

2020-10-19 Thread Eric Blake
On 10/19/20 8:39 AM, no-re...@patchew.org wrote: Patchew URL: https://patchew.org/QEMU/1603114311-7392-1-git-send-email-lizhen...@huawei.com/ c61a848 virtio-iommu: fix incorrect print type === OUTPUT BEGIN === ERROR: Missing Signed-off-by: line(s) total: 1 errors, 0 warnings, 24 lines

Re: [PATCH] virtio-gpu: fix incorrect print type

2020-10-19 Thread Eric Blake
On 10/19/20 9:23 AM, Zhengui li wrote: The type of input variable is unsigned int while the printer type is int. So fix incorrect print type. Signed-off-by: Zhengui li --- hw/display/virtio-gpu.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) This

Re: [PATCH v6 04/10] block: allow specifying name of block device for vmstate storage

2020-10-19 Thread Eric Blake
On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: Currently the vmstate will be stored in the first block device that supports snapshots. Historically this would have usually been the root device, but with UEFI it might be the variable store. There needs to be a way to override the choice of block

Re: [PATCH v1 0/2] Add timeout mechanism to qmp actions

2020-10-19 Thread Zhenyu Ye
On 2020/10/19 21:25, Paolo Bonzini wrote: > On 19/10/20 14:40, Zhenyu Ye wrote: >> The kernel backtrace for io_submit in GUEST is: >> >> guest# ./offcputime -K -p `pgrep -nx fio` >> b'finish_task_switch' >> b'__schedule' >> b'schedule' >> b'io_schedule' >>

Question on Compression for Raw Image

2020-10-19 Thread Wang, Wei W
Hi, Does anyone know the reason why raw-format.c doesn't have compression support (but qcow has the supported added)? For example, raw image backup with compression, "qemu-img convert -c -O raw origin.img dist.img", doesn't work. Thanks, Wei

Re: [PATCH v6 02/10] migration: stop returning errno from load_snapshot()

2020-10-19 Thread Markus Armbruster
Eric Blake writes: > On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: >> None of the callers care about the errno value since there is a full >> Error object populated. This gives consistency with save_snapshot() >> which already just returns -1. >> Reviewed-by: Dr. David Alan Gilbert >>

Re: [PATCH v6 04/10] block: allow specifying name of block device for vmstate storage

2020-10-19 Thread Markus Armbruster
Eric Blake writes: > On 10/8/20 10:49 AM, Daniel P. Berrangé wrote: >> Currently the vmstate will be stored in the first block device that >> supports snapshots. Historically this would have usually been the >> root device, but with UEFI it might be the variable store. There >> needs to be a way