@@ -58,6 +58,7 @@ verity_setup() {
local INPUT=${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.$TYPE
local SIZE=$(stat --printf="%s" $INPUT)
local OUTPUT=$INPUT.verity
+ local SETUP_ARGS=""
if [ ${DM_VERITY_IMAGE_DATA_BLOCK_SIZE} -ge ${DM_VERITY_IMAGE_HASH_BLOCK_SIZE} ]; then
align=${DM_VERITY_IMAGE_DATA_BLOCK_SIZE}
@@ -68,9 +69,15 @@ verity_setup() {
cp -a $INPUT $OUTPUT
+ SETUP_ARGS=" \
+ --data-block-size=${DM_VERITY_IMAGE_DATA_BLOCK_SIZE} \
+ --hash-block-size=${DM_VERITY_IMAGE_HASH_BLOCK_SIZE} \
+ --hash-offset=$SIZE format $OUTPUT $OUTPUT \
+ "
+
# Let's drop the first line of output (doesn't contain any useful info)
# and feed the rest to another function.
- veritysetup --data-block-size=${DM_VERITY_IMAGE_DATA_BLOCK_SIZE} --hash-block-size=${DM_VERITY_IMAGE_HASH_BLOCK_SIZE} --hash-offset=$SIZE format $OUTPUT $OUTPUT | tail -n +2 | process_verity
+ veritysetup $SETUP_ARGS | tail -n +2 | process_verity
}
VERITY_TYPES = " \
In making changes to the existing veritysetup arg list, it is harder to see what the proposed change is since they are are glued together on one long line. Break them up so reviewing future unified diffs will be more easy to visually parse. This also makes it easier to temp. dump the args to a file for debugging. In theory this should have no functional change. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> --- classes/dm-verity-img.bbclass | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)