diff mbox series

[03/14] nvme: don't remove namespaces in nvme_passthru_end

Message ID 20221101150050.3510-4-hch@lst.de (mailing list archive)
State New, archived
Headers show
Series [01/14] block: set the disk capacity to 0 in blk_mark_disk_dead | expand

Commit Message

Christoph Hellwig Nov. 1, 2022, 3 p.m. UTC
The call to nvme_remove_invalid_namespaces made sense when
nvme_passthru_end revalidated all namespaces and had to remove those that
didn't exist any more.  Since we don't revalidate from nvme_passthru_end
now, this call is entirely spurious.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
---
 drivers/nvme/host/core.c | 1 -
 1 file changed, 1 deletion(-)

Comments

Chaitanya Kulkarni Nov. 2, 2022, 1:20 a.m. UTC | #1
On 11/1/22 08:00, Christoph Hellwig wrote:
> The call to nvme_remove_invalid_namespaces made sense when
> nvme_passthru_end revalidated all namespaces and had to remove those that
> didn't exist any more.  Since we don't revalidate from nvme_passthru_end
> now, this call is entirely spurious.
> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
> ---

Looks good.

Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>

-ck
diff mbox series

Patch

diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index aea0f89acf409..35386aa24f589 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -1118,7 +1118,6 @@  void nvme_passthru_end(struct nvme_ctrl *ctrl, u32 effects,
 		nvme_unfreeze(ctrl);
 		nvme_mpath_unfreeze(ctrl->subsys);
 		mutex_unlock(&ctrl->subsys->lock);
-		nvme_remove_invalid_namespaces(ctrl, NVME_NSID_ALL);
 		mutex_unlock(&ctrl->scan_lock);
 	}
 	if (effects & NVME_CMD_EFFECTS_CCC)