Commit 3e53ba38 authored by Sagi Grimberg's avatar Sagi Grimberg Committed by Jens Axboe

nvme: cache controller attributes

We get the controller attributes in identify, cache them as we'll need
them for traffic based keep alive support.
Reviewed-by: default avatarChaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Signed-off-by: default avatarSagi Grimberg <sagi@grimberg.me>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 12b21171
...@@ -2409,6 +2409,7 @@ int nvme_init_identify(struct nvme_ctrl *ctrl) ...@@ -2409,6 +2409,7 @@ int nvme_init_identify(struct nvme_ctrl *ctrl)
ctrl->sgls = le32_to_cpu(id->sgls); ctrl->sgls = le32_to_cpu(id->sgls);
ctrl->kas = le16_to_cpu(id->kas); ctrl->kas = le16_to_cpu(id->kas);
ctrl->max_namespaces = le32_to_cpu(id->mnan); ctrl->max_namespaces = le32_to_cpu(id->mnan);
ctrl->ctratt = le32_to_cpu(id->ctratt);
if (id->rtd3e) { if (id->rtd3e) {
/* us -> s */ /* us -> s */
......
...@@ -194,6 +194,7 @@ struct nvme_ctrl { ...@@ -194,6 +194,7 @@ struct nvme_ctrl {
u8 apsta; u8 apsta;
u32 oaes; u32 oaes;
u32 aen_result; u32 aen_result;
u32 ctratt;
unsigned int shutdown_timeout; unsigned int shutdown_timeout;
unsigned int kato; unsigned int kato;
bool subsystem; bool subsystem;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment