Patch "nvme-core: check ctrl css before setting up zns" has been added to the 5.11-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    nvme-core: check ctrl css before setting up zns

to the 5.11-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     nvme-core-check-ctrl-css-before-setting-up-zns.patch
and it can be found in the queue-5.11 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 27617fcbda6da43932092727740f6e3a99c77eab
Author: Chaitanya Kulkarni <chaitanya.kulkarni@xxxxxxx>
Date:   Mon Mar 8 20:58:21 2021 -0800

    nvme-core: check ctrl css before setting up zns
    
    [ Upstream commit 0ec84df4953bd42c6583a555773f1d4996a061eb ]
    
    Ensure multiple Command Sets are supported before starting to setup a
    ZNS namespace.
    
    Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni@xxxxxxx>
    [hch: move the check around a bit]
    Signed-off-by: Christoph Hellwig <hch@xxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index 206bf0a50487..c611a17e83f0 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -4069,6 +4069,12 @@ static void nvme_validate_or_alloc_ns(struct nvme_ctrl *ctrl, unsigned nsid)
 				nsid);
 			break;
 		}
+		if (!nvme_multi_css(ctrl)) {
+			dev_warn(ctrl->device,
+				"command set not reported for nsid: %d\n",
+				ns->head->ns_id);
+			break;
+		}
 		nvme_alloc_ns(ctrl, nsid, &ids);
 		break;
 	default:



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux