summary refs log tree commit diff
path: root/drivers/md/dm-thin.c
diff options
context:
space:
mode:
authorMike Snitzer <snitzer@redhat.com>2022-03-08 17:18:07 -0500
committerMike Snitzer <snitzer@redhat.com>2022-03-10 13:44:55 -0500
commita92512819b1f2971674675edbf695b717d43629c (patch)
tree66f7f866e6e7bbdbb6a1e11e1b970b0d1ae3c5aa /drivers/md/dm-thin.c
parent0a8e9599b91db84b25e4f13e89ed9b5cc3c2d15f (diff)
downloadlinux-a92512819b1f2971674675edbf695b717d43629c.tar.gz
dm thin: use dm_submit_bio_remap
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-thin.c')
-rw-r--r--drivers/md/dm-thin.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/md/dm-thin.c b/drivers/md/dm-thin.c
index a01aa4ef2042..ba74bc22ba42 100644
--- a/drivers/md/dm-thin.c
+++ b/drivers/md/dm-thin.c
@@ -755,7 +755,7 @@ static void issue(struct thin_c *tc, struct bio *bio)
 	struct pool *pool = tc->pool;
 
 	if (!bio_triggers_commit(tc, bio)) {
-		submit_bio_noacct(bio);
+		dm_submit_bio_remap(bio, NULL, true);
 		return;
 	}
 
@@ -2383,7 +2383,7 @@ static void process_deferred_bios(struct pool *pool)
 		if (bio->bi_opf & REQ_PREFLUSH)
 			bio_endio(bio);
 		else
-			submit_bio_noacct(bio);
+			dm_submit_bio_remap(bio, NULL, true);
 	}
 }
 
@@ -4231,6 +4231,7 @@ static int thin_ctr(struct dm_target *ti, unsigned argc, char **argv)
 
 	ti->num_flush_bios = 1;
 	ti->flush_supported = true;
+	ti->accounts_remapped_io = true;
 	ti->per_io_data_size = sizeof(struct dm_thin_endio_hook);
 
 	/* In case the pool supports discards, pass them on. */