Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 154234
b: refs/heads/master
c: a0cf7ea
h: refs/heads/master
v: v3
  • Loading branch information
Hannes Reinecke authored and Alasdair G Kergon committed Jun 22, 2009
1 parent 0d05dd8 commit c6261ce
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4d89b7b4e4726893453d0fb4ddbb5b3e16353994
refs/heads/master: a0cf7ea9549ec60988369f90e5c0f855f08abac9
15 changes: 13 additions & 2 deletions trunk/drivers/md/dm-mpath.c
Original file line number Diff line number Diff line change
Expand Up @@ -597,9 +597,20 @@ static struct pgpath *parse_path(struct arg_set *as, struct path_selector *ps,
}

if (m->hw_handler_name) {
r = scsi_dh_attach(bdev_get_queue(p->path.dev->bdev),
m->hw_handler_name);
struct request_queue *q = bdev_get_queue(p->path.dev->bdev);

r = scsi_dh_attach(q, m->hw_handler_name);
if (r == -EBUSY) {
/*
* Already attached to different hw_handler,
* try to reattach with correct one.
*/
scsi_dh_detach(q);
r = scsi_dh_attach(q, m->hw_handler_name);
}

if (r < 0) {
ti->error = "error attaching hardware handler";
dm_put_device(ti, p->path.dev);
goto bad;
}
Expand Down

0 comments on commit c6261ce

Please sign in to comment.