Re: [PATCH for-6.0 v2 3/8] hw/block/nvme: fix the nsid 'invalid' value

2021-04-05 Thread Philippe Mathieu-Daudé
Hi Klaus, On 4/5/21 7:54 PM, Klaus Jensen wrote: > From: Klaus Jensen > > The `nvme_nsid()` function returns '-1' (h) when the given > namespace is NULL. Since h is actually a valid namespace > identifier (the "broadcast" value), change this to be '0' since that > actually *is* t

Re: [PATCH for-6.0 v2 7/8] hw/block/nvme: fix handling of private namespaces

2021-04-05 Thread Minwoo Im
On 21-04-05 19:54:51, Klaus Jensen wrote: > From: Klaus Jensen > > Prior to this patch, if a private nvme-ns device (that is, a namespace > that is not linked to a subsystem) is wired up to an nvme-subsys linked > nvme controller device, the device fails to verify that the namespace id > is uniqu

Re: [PATCH 0/6] Add debug interface to kick/call on purpose

2021-04-05 Thread Jason Wang
在 2021/4/6 上午4:00, Dongli Zhang 写道: On 4/1/21 8:47 PM, Jason Wang wrote: 在 2021/3/30 下午3:29, Dongli Zhang 写道: On 3/28/21 8:56 PM, Jason Wang wrote: 在 2021/3/27 上午5:16, Dongli Zhang 写道: Hi Jason, On 3/26/21 12:24 AM, Jason Wang wrote: 在 2021/3/26 下午1:44, Dongli Zhang 写道: The virtio devic

Re: [PATCH 0/6] Add debug interface to kick/call on purpose

2021-04-05 Thread Dongli Zhang
On 4/1/21 8:47 PM, Jason Wang wrote: > > 在 2021/3/30 下午3:29, Dongli Zhang 写道: >> >> On 3/28/21 8:56 PM, Jason Wang wrote: >>> 在 2021/3/27 上午5:16, Dongli Zhang 写道: Hi Jason, On 3/26/21 12:24 AM, Jason Wang wrote: > 在 2021/3/26 下午1:44, Dongli Zhang 写道: >> The virtio device/

Re: [PATCH for-6.0 v2 0/8] hw/block/nvme: misc fixes

2021-04-05 Thread Keith Busch
On Mon, Apr 05, 2021 at 07:54:44PM +0200, Klaus Jensen wrote: > From: Klaus Jensen > > Various fixes for 6.0. > > v2: > - "hw/block/nvme: fix handling of private namespaces" > update documentation (Gollu) > - add a patch for missing copyright headers Series looks fine. Reviewed-by: Kei

[PATCH for-6.0 v2 5/8] hw/block/nvme: fix warning about legacy namespace configuration

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen Remove the unused BlockConf from the controller structure and fix the constraint checking to actually check the right BlockConf and issue the warning. Signed-off-by: Klaus Jensen Reviewed-by: Gollu Appalanaidu --- hw/block/nvme.h | 1 - hw/block/nvme.c | 2 +- 2 files chang

[PATCH for-6.0 v2 2/8] hw/block/nvme: fix missing string representation for ns attachment

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen Add the missing nvme_adm_opc_str entry for the Namespace Attachment command. Signed-off-by: Klaus Jensen Reviewed-by: Gollu Appalanaidu --- hw/block/nvme.h | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/block/nvme.h b/hw/block/nvme.h index 5b0031b11db2..9edc86d79e98

[PATCH for-6.0 v2 7/8] hw/block/nvme: fix handling of private namespaces

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen Prior to this patch, if a private nvme-ns device (that is, a namespace that is not linked to a subsystem) is wired up to an nvme-subsys linked nvme controller device, the device fails to verify that the namespace id is unique within the subsystem. NVM Express v1.4b, Section 6.1

[PATCH for-6.0 v2 6/8] hw/block/nvme: update dmsrl limit on namespace detachment

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen The Non-MDTS DMSRL limit must be recomputed when namespaces are detached. Fixes: 645ce1a70cb6 ("hw/block/nvme: support namespace attachment command") Signed-off-by: Klaus Jensen Reviewed-by: Gollu Appalanaidu --- hw/block/nvme.c | 17 + 1 file changed, 17 in

[PATCH for-6.0 v2 8/8] hw/block/nvme: add missing copyright headers

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen Add missing license/copyright headers to the nvme-dif.{c,h} files. Signed-off-by: Klaus Jensen --- hw/block/nvme-dif.h | 10 ++ hw/block/nvme-dif.c | 10 ++ 2 files changed, 20 insertions(+) diff --git a/hw/block/nvme-dif.h b/hw/block/nvme-dif.h index 5a8e37

[PATCH for-6.0 v2 4/8] hw/block/nvme: fix controller namespaces array indexing

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen The controller namespaces array being 0-indexed requires 'nsid - 1' everywhere. Something that is easy to miss. Align the controller namespaces array with the subsystem namespaces array such that both are 1-indexed. Signed-off-by: Klaus Jensen Reviewed-by: Gollu Appalanaidu

[PATCH for-6.0 v2 3/8] hw/block/nvme: fix the nsid 'invalid' value

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen The `nvme_nsid()` function returns '-1' (h) when the given namespace is NULL. Since h is actually a valid namespace identifier (the "broadcast" value), change this to be '0' since that actually *is* the invalid value. Signed-off-by: Klaus Jensen Reviewed-by: G

[PATCH for-6.0 v2 1/8] hw/block/nvme: fix pi constraint check

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen Protection Information can only be enabled if there is at least 8 bytes of metadata. Signed-off-by: Klaus Jensen Reviewed-by: Gollu Appalanaidu --- hw/block/nvme-ns.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/block/nvme-ns.c b/hw/block/nvme-ns.c

[PATCH for-6.0 v2 0/8] hw/block/nvme: misc fixes

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen Various fixes for 6.0. v2: - "hw/block/nvme: fix handling of private namespaces" update documentation (Gollu) - add a patch for missing copyright headers Klaus Jensen (8): hw/block/nvme: fix pi constraint check hw/block/nvme: fix missing string representation for

[PULL for-6.0 1/2] hw/block/nvme: remove description for zoned.append_size_limit

2021-04-05 Thread Klaus Jensen
From: Niklas Cassel The description was originally removed in commit 578d914b263c ("hw/block/nvme: align zoned.zasl with mdts") together with the removal of the zoned.append_size_limit parameter itself. However, it was (most likely accidentally), re-added in commit f7dcd31885cb ("hw/block/nvme:

[PULL for-6.0 0/2] emulated nvme fixes

2021-04-05 Thread Klaus Jensen
From: Klaus Jensen Hi Peter, The following changes since commit 25d75c99b2e5941c67049ee776efdb226414f4c6: Merge remote-tracking branch 'remotes/xtensa/tags/20210403-xtensa' into staging (2021-04-04 21:48:45 +0100) are available in the Git repository at: git://git.infradead.org/qemu-nvme.

[PULL for-6.0 2/2] hw/block/nvme: expose 'bootindex' property

2021-04-05 Thread Klaus Jensen
From: Joelle van Dyne The check for `n->namespace.blkconf.blk` always fails because this is in the initialization function. Signed-off-by: Joelle van Dyne Reviewed-by: Klaus Jensen Signed-off-by: Klaus Jensen --- hw/block/nvme.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-)

Re: [PATCH for-6.0 7/7] hw/block/nvme: fix handling of private namespaces

2021-04-05 Thread Klaus Jensen
On Apr 5 18:02, Gollu Appalanaidu wrote: > On Wed, Mar 24, 2021 at 09:09:07PM +0100, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Prior to this patch, if a private nvme-ns device (that is, a namespace > > that is not linked to a subsystem) is wired up to an nvme-subsys linked > > nvme cont

Re: [PATCH for-6.0 0/7] hw/block/nvme: misc fixes

2021-04-05 Thread Gollu Appalanaidu
On Wed, Mar 24, 2021 at 09:09:00PM +0100, Klaus Jensen wrote: From: Klaus Jensen Various fixes for 6.0. Klaus Jensen (7): hw/block/nvme: fix pi constraint check hw/block/nvme: fix missing string representation for ns attachment hw/block/nvme: fix the nsid 'invalid' value hw/block/nvme: fix

Re: [PATCH for-6.0 7/7] hw/block/nvme: fix handling of private namespaces

2021-04-05 Thread Gollu Appalanaidu
On Wed, Mar 24, 2021 at 09:09:07PM +0100, Klaus Jensen wrote: From: Klaus Jensen Prior to this patch, if a private nvme-ns device (that is, a namespace that is not linked to a subsystem) is wired up to an nvme-subsys linked nvme controller device, the device fails to verify that the namespace i

Re: [PATCH for-6.0 0/7] hw/block/nvme: misc fixes

2021-04-05 Thread Klaus Jensen
On Mar 24 21:09, Klaus Jensen wrote: > From: Klaus Jensen > > Various fixes for 6.0. > > Klaus Jensen (7): > hw/block/nvme: fix pi constraint check > hw/block/nvme: fix missing string representation for ns attachment > hw/block/nvme: fix the nsid 'invalid' value > hw/block/nvme: fix cont