Skip to contentSkip to conversation

nvme-fc: don't bother to validate ioccsz and iorcsz

PATCH New James Smart 2 participants 2 messages Feb 17, 2017 – Feb 19, 2017

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nvme-fc: don't bother to validate ioccsz and iorcsz

Discovery controllers don't set the values. They are in reserved areas of the Identify Controller data structure.

Given the cmd completed, the minimal capsule sizes are supported, so no need to check nqn to detect discovery controllers and special case validations.

-- james

Signed-off-by James Smart <james.smart at broadcom.com>
---
 drivers/nvme/host/fc.c | 12 ------------
 1 file changed, 12 deletions(-)
drivers/nvme/host/fc.c +0 -12
index fb51a8d..996e96c 100644
@@ -2353,18 +2353,6 @@ __nvme_fc_create_ctrl(struct device *dev, struct nvmf_ctrl_options *opts,
 
 	/* sanity checks */
 
-	/* FC-NVME supports 64-byte SQE only */
-	if (ctrl->ctrl.ioccsz != 4) {
-		dev_err(ctrl->ctrl.device, "ioccsz %d is not supported!\n",
-				ctrl->ctrl.ioccsz);
-		goto out_remove_admin_queue;
-	}
-	/* FC-NVME supports 16-byte CQE only */
-	if (ctrl->ctrl.iorcsz != 1) {
-		dev_err(ctrl->ctrl.device, "iorcsz %d is not supported!\n",
-				ctrl->ctrl.iorcsz);
-		goto out_remove_admin_queue;
-	}
 	/* FC-NVME does not have other data in the capsule */
 	if (ctrl->ctrl.icdoff) {
 		dev_err(ctrl->ctrl.device, "icdoff %d is not supported!\n",
Signature · 1 line
2.5.0
#1 lore raw

PATCH 1/1 nvme-fc: don't bother to validate ioccsz and iorcsz

Looks fine,

Reviewed-by Christoph Hellwig <hch at lst.de>