snapuserd: Read partition blocks to memory

When the device is rebooted after OTA is done,
daemon will read through all the dynamic partitions
to bring the blocks to memory. When update-verifier
runs, all the blocks would be in page-cache thereby
cutting down the boot time.

Boot time improvements on Pixel:

Full OTA:
===========

VABC (Without this patch): 37.308 seconds
VABC (With this patch): 28.604 seconds

Incremental OTA:
=================

VABC (Without this patch): 39.072 seconds
VABC (With this patch): 27.523 seconds

We read the blocks only during second stage transition. Thus,
it shouldn't impact when snapuserd is spin up during
post-install phase or during first-stage init.

Bug: 193863442
Test: Full and Incremental OTA on pixel
Signed-off-by: Akilesh Kailash <akailash@google.com>
Change-Id: Id654449238e22125f7d6288c7100fde512cc2ced
8 files changed