aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-table.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/md/dm-table.c')
-rw-r--r--drivers/md/dm-table.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/drivers/md/dm-table.c b/drivers/md/dm-table.c
index 4b22feb01a0c..9924ea23032d 100644
--- a/drivers/md/dm-table.c
+++ b/drivers/md/dm-table.c
@@ -429,8 +429,7 @@ static int upgrade_mode(struct dm_dev_internal *dd, fmode_t new_mode,
429 * it's already present. 429 * it's already present.
430 */ 430 */
431static int __table_get_device(struct dm_table *t, struct dm_target *ti, 431static int __table_get_device(struct dm_table *t, struct dm_target *ti,
432 const char *path, sector_t start, sector_t len, 432 const char *path, fmode_t mode, struct dm_dev **result)
433 fmode_t mode, struct dm_dev **result)
434{ 433{
435 int r; 434 int r;
436 dev_t uninitialized_var(dev); 435 dev_t uninitialized_var(dev);
@@ -527,11 +526,10 @@ int dm_set_device_limits(struct dm_target *ti, struct dm_dev *dev,
527} 526}
528EXPORT_SYMBOL_GPL(dm_set_device_limits); 527EXPORT_SYMBOL_GPL(dm_set_device_limits);
529 528
530int dm_get_device(struct dm_target *ti, const char *path, sector_t start, 529int dm_get_device(struct dm_target *ti, const char *path, fmode_t mode,
531 sector_t len, fmode_t mode, struct dm_dev **result) 530 struct dm_dev **result)
532{ 531{
533 return __table_get_device(ti->table, ti, path, 532 return __table_get_device(ti->table, ti, path, mode, result);
534 start, len, mode, result);
535} 533}
536 534
537 535
@@ -1231,8 +1229,6 @@ void dm_table_unplug_all(struct dm_table *t)
1231 1229
1232struct mapped_device *dm_table_get_md(struct dm_table *t) 1230struct mapped_device *dm_table_get_md(struct dm_table *t)
1233{ 1231{
1234 dm_get(t->md);
1235
1236 return t->md; 1232 return t->md;
1237} 1233}
1238 1234