Skip to contentSkip to conversation

NVMe: Use lower bits of firmware rev for SCSI Inq

PATCH New Keith Busch 1 participant 1 message Apr 17, 2014

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

PATCH 1/1 NVMe: Use lower bits of firmware rev for SCSI Inq

Vendors indicate to me that the lower bits of the NVMe ID Controller firmware revision are more inidicative of the running version, so while this isn't aligned with the SNT, it is more useful.

Signed-off-by Keith Busch <keith.busch at intel.com>
---
 drivers/block/nvme-scsi.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/block/nvme-scsi.c +1 -1
index 2c3f5be..1b9b5f4 100644
@@ -721,7 +721,7 @@ static int nvme_trans_standard_inquiry_page(struct nvme_ns *ns,
 	inq_response[7] = cmdque;	/* wbus16=0 | sync=0 | vs=0 */
 	strncpy(&inq_response[8], "NVMe    ", 8);
 	strncpy(&inq_response[16], dev->model, 16);
-	strncpy(&inq_response[32], dev->firmware_rev, 4);
+	strncpy(&inq_response[32], dev->firmware_rev + 4, 4);
 
 	xfer_len = min(alloc_len, STANDARD_INQUIRY_LENGTH);
 	res = nvme_trans_copy_to_user(hdr, inq_response, xfer_len);
Signature · 1 line
1.7.10.4