diff options
author | Benjamin Marzinski <bmarzins@redhat.com> | 2014-08-13 14:53:42 -0400 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2014-10-05 20:03:35 -0400 |
commit | 1f271972478d84dd9e4d6dd82f414d70ed9e78ce (patch) | |
tree | e0dba45e8ca30c73ef29526223f9fd01d2218ab2 /drivers/md | |
parent | 3d8aab2d2cca2dc878e396196d07889129440798 (diff) |
dm mpath: stop queueing IO when no valid paths exist
'queue_io' is set so that IO is queued while paths are being
initialized. Clear queue_io in __choose_pgpath if there are no valid
paths, since there are obviously no paths that can be initialized.
Otherwise IOs to the device will back up.
Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md')
-rw-r--r-- | drivers/md/dm-mpath.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/md/dm-mpath.c b/drivers/md/dm-mpath.c index 833d7e752f06..7b6b0f0f831a 100644 --- a/drivers/md/dm-mpath.c +++ b/drivers/md/dm-mpath.c | |||
@@ -317,8 +317,10 @@ static void __choose_pgpath(struct multipath *m, size_t nr_bytes) | |||
317 | struct priority_group *pg; | 317 | struct priority_group *pg; |
318 | unsigned bypassed = 1; | 318 | unsigned bypassed = 1; |
319 | 319 | ||
320 | if (!m->nr_valid_paths) | 320 | if (!m->nr_valid_paths) { |
321 | m->queue_io = 0; | ||
321 | goto failed; | 322 | goto failed; |
323 | } | ||
322 | 324 | ||
323 | /* Were we instructed to switch PG? */ | 325 | /* Were we instructed to switch PG? */ |
324 | if (m->next_pg) { | 326 | if (m->next_pg) { |