aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2018-09-20 11:10:38 -0400
committerJens Axboe <axboe@kernel.dk>2018-09-20 11:10:38 -0400
commitd611aaf336b2e8e81f98490eabf7b92889b15319 (patch)
tree085d54f2975c17627363af0d34c3b213fdd173ac
parent65eea8edc315589d6c993cf12dbb5d0e9ef1fe4e (diff)
parentbe1277f5eb17a2e5788139eabb0b53dd04c695f3 (diff)
Merge branch 'nvme-4.19' of git://git.infradead.org/nvme into for-linus
Pull NVMe fix from Christoph. * 'nvme-4.19' of git://git.infradead.org/nvme: nvme: count all ANA groups for ANA Log page
-rw-r--r--drivers/nvme/target/admin-cmd.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/nvme/target/admin-cmd.c b/drivers/nvme/target/admin-cmd.c
index a21caea1e080..2008fa62a373 100644
--- a/drivers/nvme/target/admin-cmd.c
+++ b/drivers/nvme/target/admin-cmd.c
@@ -245,6 +245,10 @@ static void nvmet_execute_get_log_page_ana(struct nvmet_req *req)
245 offset += len; 245 offset += len;
246 ngrps++; 246 ngrps++;
247 } 247 }
248 for ( ; grpid <= NVMET_MAX_ANAGRPS; grpid++) {
249 if (nvmet_ana_group_enabled[grpid])
250 ngrps++;
251 }
248 252
249 hdr.chgcnt = cpu_to_le64(nvmet_ana_chgcnt); 253 hdr.chgcnt = cpu_to_le64(nvmet_ana_chgcnt);
250 hdr.ngrps = cpu_to_le16(ngrps); 254 hdr.ngrps = cpu_to_le16(ngrps);