]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
dm thin: set flush_supported
authorJoe Thornber <ejt@redhat.com>
Fri, 27 Jul 2012 14:08:07 +0000 (15:08 +0100)
committerAlasdair G Kergon <agk@redhat.com>
Fri, 27 Jul 2012 14:08:07 +0000 (15:08 +0100)
The thin provisioning target commits internal metadata on flush.  So it
should receive flushes regardless of whether the underlying devices
support them.

Signed-off-by: Joe Thornber <ejt@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
drivers/md/dm-thin.c

index 7510cb3d571c1f8693b8087ee4e9057c811f8dc2..ee5a3fc93b0e4f6550f2051a549f55415c251acb 100644 (file)
@@ -2652,6 +2652,7 @@ static int thin_ctr(struct dm_target *ti, unsigned argc, char **argv)
                goto bad_thin_open;
 
        ti->num_flush_requests = 1;
+       ti->flush_supported = true;
 
        /* In case the pool supports discards, pass them on. */
        if (tc->pool->pf.discard_enabled) {