Skip to content

Commit

Permalink
NVMe: Make iod bio timeout a parameter
Browse files Browse the repository at this point in the history
This was originally set to 4 times the IO timeout, but that was when
the IO timeout was 5 seconds instead of 30. 20 seconds for total time
to failure seemed more reasonable than 2 minutes for most, but other
users have requested to make this a module parameter instead.

Signed-off-by: Keith Busch <keith.busch@intel.com>
[renamed the module parameter to retry_time]
[made retry_time static]
Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
  • Loading branch information
Keith Busch authored and Matthew Wilcox committed Jun 4, 2014
1 parent 6808c5f commit 61e4ce0
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion drivers/block/nvme-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,16 @@
#define SQ_SIZE(depth) (depth * sizeof(struct nvme_command))
#define CQ_SIZE(depth) (depth * sizeof(struct nvme_completion))
#define ADMIN_TIMEOUT (60 * HZ)
#define IOD_TIMEOUT (4 * NVME_IO_TIMEOUT)
#define IOD_TIMEOUT (retry_time * HZ)

unsigned char io_timeout = 30;
module_param(io_timeout, byte, 0644);
MODULE_PARM_DESC(io_timeout, "timeout in seconds for I/O");

static unsigned char retry_time = 30;
module_param(retry_time, byte, 0644);
MODULE_PARM_DESC(retry_time, "time in seconds to retry failed I/O");

static int nvme_major;
module_param(nvme_major, int, 0);

Expand Down

0 comments on commit 61e4ce0

Please sign in to comment.