summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2018-09-20 09:10:38 -0600
committerJens Axboe <axboe@kernel.dk>2018-09-20 09:10:38 -0600
commitd611aaf336b2e8e81f98490eabf7b92889b15319 (patch)
tree085d54f2975c17627363af0d34c3b213fdd173ac /drivers
parent65eea8edc315589d6c993cf12dbb5d0e9ef1fe4e (diff)
parentbe1277f5eb17a2e5788139eabb0b53dd04c695f3 (diff)
downloadlinux-d611aaf336b2e8e81f98490eabf7b92889b15319.tar.bz2
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
Diffstat (limited to 'drivers')
-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)
offset += len;
ngrps++;
}
+ for ( ; grpid <= NVMET_MAX_ANAGRPS; grpid++) {
+ if (nvmet_ana_group_enabled[grpid])
+ ngrps++;
+ }
hdr.chgcnt = cpu_to_le64(nvmet_ana_chgcnt);
hdr.ngrps = cpu_to_le16(ngrps);