dm-mpath.c (fb61264297ca42a2a132f0433f75ccf7fd304ac6) | dm-mpath.c (8215d6ec5fee1e76545decea2cd73717efb5cb42) |
---|---|
1/* 2 * Copyright (C) 2003 Sistina Software Limited. 3 * Copyright (C) 2004-2005 Red Hat, Inc. All rights reserved. 4 * 5 * This file is released under the GPL. 6 */ 7 8#include <linux/device-mapper.h> --- 593 unchanged lines hidden (view full) --- 602 ti->error = "no device given"; 603 return ERR_PTR(-EINVAL); 604 } 605 606 p = alloc_pgpath(); 607 if (!p) 608 return ERR_PTR(-ENOMEM); 609 | 1/* 2 * Copyright (C) 2003 Sistina Software Limited. 3 * Copyright (C) 2004-2005 Red Hat, Inc. All rights reserved. 4 * 5 * This file is released under the GPL. 6 */ 7 8#include <linux/device-mapper.h> --- 593 unchanged lines hidden (view full) --- 602 ti->error = "no device given"; 603 return ERR_PTR(-EINVAL); 604 } 605 606 p = alloc_pgpath(); 607 if (!p) 608 return ERR_PTR(-ENOMEM); 609 |
610 r = dm_get_device(ti, shift(as), ti->begin, ti->len, 611 dm_table_get_mode(ti->table), &p->path.dev); | 610 r = dm_get_device(ti, shift(as), dm_table_get_mode(ti->table), 611 &p->path.dev); |
612 if (r) { 613 ti->error = "error getting device"; 614 goto bad; 615 } 616 617 if (m->hw_handler_name) { 618 struct request_queue *q = bdev_get_queue(p->path.dev->bdev); 619 --- 880 unchanged lines hidden (view full) --- 1500 action = reinstate_path; 1501 else if (!strnicmp(argv[0], MESG_STR("fail_path"))) 1502 action = fail_path; 1503 else { 1504 DMWARN("Unrecognised multipath message received."); 1505 goto out; 1506 } 1507 | 612 if (r) { 613 ti->error = "error getting device"; 614 goto bad; 615 } 616 617 if (m->hw_handler_name) { 618 struct request_queue *q = bdev_get_queue(p->path.dev->bdev); 619 --- 880 unchanged lines hidden (view full) --- 1500 action = reinstate_path; 1501 else if (!strnicmp(argv[0], MESG_STR("fail_path"))) 1502 action = fail_path; 1503 else { 1504 DMWARN("Unrecognised multipath message received."); 1505 goto out; 1506 } 1507 |
1508 r = dm_get_device(ti, argv[1], ti->begin, ti->len, 1509 dm_table_get_mode(ti->table), &dev); | 1508 r = dm_get_device(ti, argv[1], dm_table_get_mode(ti->table), &dev); |
1510 if (r) { 1511 DMWARN("message: error getting device %s", 1512 argv[1]); 1513 goto out; 1514 } 1515 1516 r = action_dev(m, dev, action); 1517 --- 207 unchanged lines hidden --- | 1509 if (r) { 1510 DMWARN("message: error getting device %s", 1511 argv[1]); 1512 goto out; 1513 } 1514 1515 r = action_dev(m, dev, action); 1516 --- 207 unchanged lines hidden --- |