emmc-image: add verification script for security service

This provides a script to verify all the emmc images
Time comsuming should be trivial, 800k image takes 0.04s to verify.

Tested:

time veritysetup --data-block-size=$DATA_BLOCK_SIZE --hash=$HASH_ALGORITHM --hash-block-size=$HASH_BLOCK_SIZE --hash-offset=$DATA_SIZE verify "${emmcdir}/${img}" ${emmcdir}/${img} $ROOT_HASH

real	0m0.043s
user	0m0.024s
sys	0m0.016s

root@thl6-nfd01:~# time /usr/bin/emmc-image-verify.sh

real	0m0.076s
user	0m0.044s
sys	0m0.030s

Fusion-Link: fusion2 N/A won't tested by presubmit
Google-Bug-Id: 359666294
Change-Id: I595f03205469f9e9714274e8baa4bae61603fb13
Signed-off-by: Yuxiao Zhang <yuxiaozhang@google.com>
1 file changed
tree: 74708faf397ba5111c560661384633896da43ef0
  1. linux/
  2. .gitmodules