summaryrefslogtreecommitdiffstats
path: root/drivers/nvme/host/nvme.h
diff options
context:
space:
mode:
authorMartin K. Petersen2017-08-26 01:14:50 +0200
committerSagi Grimberg2017-08-28 22:00:44 +0200
commit07fbd32a6b215d8b2fc01ccc89622207b9b782fd (patch)
tree2c8a3f2c6cc6a10735a437d991f20cf804bda704 /drivers/nvme/host/nvme.h
parentnvme: fix uninitialized prp2 value on small transfers (diff)
downloadkernel-qcow2-linux-07fbd32a6b215d8b2fc01ccc89622207b9b782fd.tar.gz
kernel-qcow2-linux-07fbd32a6b215d8b2fc01ccc89622207b9b782fd.tar.xz
kernel-qcow2-linux-07fbd32a6b215d8b2fc01ccc89622207b9b782fd.zip
nvme: honor RTD3 Entry Latency for shutdowns
If an NVMe controller reports RTD3 Entry Latency larger than shutdown_timeout, up to a maximum of 60 seconds, use that value to set the shutdown timer. Otherwise fall back to the module parameter which defaults to 5 seconds. Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> [hch: removed do_div, made transition time local scope] Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/nvme/host/nvme.h')
-rw-r--r--drivers/nvme/host/nvme.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
index 2c8a02be46fd..9b959ee18cb6 100644
--- a/drivers/nvme/host/nvme.h
+++ b/drivers/nvme/host/nvme.h
@@ -162,6 +162,7 @@ struct nvme_ctrl {
u16 kas;
u8 npss;
u8 apsta;
+ unsigned int shutdown_timeout;
unsigned int kato;
bool subsystem;
unsigned long quirks;