diff options
author | Mike Snitzer <snitzer@redhat.com> | 2020-09-19 13:36:58 -0400 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2020-09-29 16:33:08 -0400 |
commit | d4a512edcc65704c5df51909caeab0495ba0ced3 (patch) | |
tree | 85abcd54756cdc73fb1c48a74cce54bedbac209a /drivers/md/dm-cache-target.c | |
parent | 33bd6f0693857492ab19869d79801437ac1e42ba (diff) | |
download | linux-d4a512edcc65704c5df51909caeab0495ba0ced3.tar.gz linux-d4a512edcc65704c5df51909caeab0495ba0ced3.tar.bz2 linux-d4a512edcc65704c5df51909caeab0495ba0ced3.zip |
dm: use dm_table_get_device_name() where appropriate in targets
dm_table_get_device_name() avoids calling dm_table_get_md() followed by
dm_device_name() -- saves intermediate dm_table_get_md() call.
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-cache-target.c')
-rw-r--r-- | drivers/md/dm-cache-target.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/dm-cache-target.c b/drivers/md/dm-cache-target.c index 96c93802ee4d..9644424591da 100644 --- a/drivers/md/dm-cache-target.c +++ b/drivers/md/dm-cache-target.c @@ -925,7 +925,7 @@ static enum cache_metadata_mode get_cache_mode(struct cache *cache) static const char *cache_device_name(struct cache *cache) { - return dm_device_name(dm_table_get_md(cache->ti->table)); + return dm_table_device_name(cache->ti->table); } static void notify_mode_switch(struct cache *cache, enum cache_metadata_mode mode) |