X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=kernel%2Fdrivers%2Fmd%2Fdm-mpath.c;fp=kernel%2Fdrivers%2Fmd%2Fdm-mpath.c;h=5b2ef966012b585874ca0bc796d1ff47309c8313;hb=52f993b8e89487ec9ee15a7fb4979e0f09a45b27;hp=cfa29f574c2a9e1454788a5757471835b254d857;hpb=c189ccac5702322ed843fe17057035b7222a59b6;p=kvmfornfv.git diff --git a/kernel/drivers/md/dm-mpath.c b/kernel/drivers/md/dm-mpath.c index cfa29f574..5b2ef9660 100644 --- a/kernel/drivers/md/dm-mpath.c +++ b/kernel/drivers/md/dm-mpath.c @@ -1220,10 +1220,10 @@ static void activate_path(struct work_struct *work) { struct pgpath *pgpath = container_of(work, struct pgpath, activate_path.work); + struct request_queue *q = bdev_get_queue(pgpath->path.dev->bdev); - if (pgpath->is_active) - scsi_dh_activate(bdev_get_queue(pgpath->path.dev->bdev), - pg_init_done, pgpath); + if (pgpath->is_active && !blk_queue_dying(q)) + scsi_dh_activate(q, pg_init_done, pgpath); else pg_init_done(pgpath, SCSI_DH_DEV_OFFLINED); }