mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
dm: linear support flush
Flush support for the linear target. Signed-off-by: Mikulas Patocka <[email protected]> Signed-off-by: Alasdair G Kergon <[email protected]>
This commit is contained in:
parent
52b1fd5a27
commit
433bcac564
1 changed files with 3 additions and 1 deletions
|
|
@ -53,6 +53,7 @@ static int linear_ctr(struct dm_target *ti, unsigned int argc, char **argv)
|
|||
goto bad;
|
||||
}
|
||||
|
||||
ti->num_flush_requests = 1;
|
||||
ti->private = lc;
|
||||
return 0;
|
||||
|
||||
|
|
@ -81,7 +82,8 @@ static void linear_map_bio(struct dm_target *ti, struct bio *bio)
|
|||
struct linear_c *lc = ti->private;
|
||||
|
||||
bio->bi_bdev = lc->dev->bdev;
|
||||
bio->bi_sector = linear_map_sector(ti, bio->bi_sector);
|
||||
if (bio_sectors(bio))
|
||||
bio->bi_sector = linear_map_sector(ti, bio->bi_sector);
|
||||
}
|
||||
|
||||
static int linear_map(struct dm_target *ti, struct bio *bio,
|
||||
|
|
|
|||
Loading…
Reference in a new issue