Disable dm-verity hash prefetching.

Prefetching appears to have a slightly negative effect on boot time, and
actually makes boot time much worse when the available dm-bufio cache
shrinks. Since we anticipate the dm-bufio cache will shrink (because of
an increasing number of APEX dm-verity targets), disable prefetching
completely.

Boot time w/o this change:  12.085
Boot time with this change: 11.958

Boot time w/o this change with 128kB dm-bufio cache: 22.82
Boot time with this change with 128kB dm-bufio cache: 12.007

Test: atest google/perf/boottime/boottime-test
Bug: 136247322
Change-Id: I12e342c5692fa89855d9c217f2e94287ff5642a6
This commit is contained in:
Martijn Coenen
2019-08-28 10:17:28 +02:00
parent 5525e044c3
commit c877c20908

View File

@@ -44,6 +44,7 @@ on early-init
# Loading kernel modules in background
start vendor.insmod_sh
write /sys/module/dm_verity/parameters/prefetch_cluster 0
on init
# Disable UFS powersaving
write /sys/devices/soc/${ro.boot.bootdevice}/clkscale_enable 0