[PATCH 03/14] nvme-core: use right type for ARRAY_SIZE check
Chaitanya Kulkarni
chaitanya.kulkarni at wdc.com
Tue Feb 16 19:10:21 EST 2021
Use unsigend int value when comparing the values of the expression
that involves sizeof() in the macro ARRAY_SIZE() that returns
size_t.
Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni at wdc.com>
---
drivers/nvme/host/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index 2f6b89f6309d..cae526757e03 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -3096,7 +3096,7 @@ int nvme_init_identify(struct nvme_ctrl *ctrl)
ctrl->cntlid = le16_to_cpu(id->cntlid);
if (!ctrl->identified) {
- int i;
+ unsigned int i;
ret = nvme_init_subsystem(ctrl, id);
if (ret)
--
2.22.1
More information about the Linux-nvme
mailing list