mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-12 15:49:17 -04:00
ANDROID: dm-bow: Fix not to skip trim at framented range
If free blocks hole is smaller than discard_granularity, TRIM to this range can be skipped. Fix this by changing the granularity to 4kb at dm-bow layer, not to skip TRIM to every tiny free blocks. Bug: 154411183 Signed-off-by: hyeongseok.kim <hyeongseok@gmail.com> Cc: hyeongseok.kim <hyeongseok.kim@lge.com> Change-Id: Ic7c33d94a016d0ad5a75514eae1056c328c9c1ba (cherry picked from commit ca986e448cf2f92f1bb672fe9bc0b651fa6b76c5) Signed-off-by: Paul Lawrence <paullawrence@google.com>
This commit is contained in:
parent
a50509b2d5
commit
f651e6024c
1 changed files with 1 additions and 0 deletions
|
|
@ -657,6 +657,7 @@ static int dm_bow_ctr(struct dm_target *ti, unsigned int argc, char **argv)
|
|||
bc->dev->bdev->bd_queue->limits.max_discard_sectors = 1 << 15;
|
||||
bc->forward_trims = false;
|
||||
} else {
|
||||
bc->dev->bdev->bd_queue->limits.discard_granularity = 1 << 12;
|
||||
bc->forward_trims = true;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue