aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-thin.c
diff options
context:
space:
mode:
authorAlasdair G Kergon <agk@redhat.com>2012-03-28 18:41:28 +0100
committerAlasdair G Kergon <agk@redhat.com>2012-03-28 18:41:28 +0100
commit6efd6e83092cd4a7532270bc843de90bb93f6683 (patch)
tree129b9de5d03a11f0bf02feb3743a10e4fe8561d5 /drivers/md/dm-thin.c
parentdm thin: support read only external snapshot origins (diff)
downloadlinux-dev-6efd6e83092cd4a7532270bc843de90bb93f6683.tar.xz
linux-dev-6efd6e83092cd4a7532270bc843de90bb93f6683.zip
dm thin: use dm_target_offset
Use dm_target_offset wrapper instead of referencing the awkward ti->begin explicitly. Signed-off-by: Alasdair G Kergon <agk@redhat.com>
Diffstat (limited to '')
-rw-r--r--drivers/md/dm-thin.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/dm-thin.c b/drivers/md/dm-thin.c
index 2d9e75586d60..7ca2bf2aafaa 100644
--- a/drivers/md/dm-thin.c
+++ b/drivers/md/dm-thin.c
@@ -2389,7 +2389,7 @@ out_unlock:
static int thin_map(struct dm_target *ti, struct bio *bio,
union map_info *map_context)
{
- bio->bi_sector -= ti->begin;
+ bio->bi_sector = dm_target_offset(ti, bio->bi_sector);
return thin_bio_map(ti, bio, map_context);
}