diff --git a/mod_image_for_recovery.sh b/mod_image_for_recovery.sh index 07856cd039..137b46c13b 100755 --- a/mod_image_for_recovery.sh +++ b/mod_image_for_recovery.sh @@ -81,6 +81,10 @@ DEFINE_boolean verbose $FLAGS_FALSE \ DEFINE_string keys_dir "/usr/share/vboot/devkeys" \ "Directory containing the signing keys." +# TODO(clchiou): Remove this flag after arm verified boot is stable +DEFINE_boolean crosbug12352_arm_kernel_signing ${FLAGS_FALSE} \ + "Sign kernel partition for ARM images (temporary hack)." + # Parse command line FLAGS "$@" || exit 1 eval set -- "${FLAGS_ARGV}" @@ -139,6 +143,12 @@ case "${TC_ARCH}" in exit 1 esac +if [[ ${FLAGS_crosbug12352_arm_kernel_signing} -eq ${FLAGS_TRUE} ]]; then + crosbug12352_flag="--crosbug12352_arm_kernel_signing" +else + crosbug12352_flag="--nocrosbug12352_arm_kernel_signing" +fi + get_install_vblock() { # If it exists, we need to copy the vblock over to stateful # This is the real vblock and not the recovery vblock. @@ -239,6 +249,7 @@ create_recovery_kernel_image() { --root=${cros_root} \ --keys_dir="${FLAGS_keys_dir}" \ --nouse_dev_keys \ + ${crosbug12352_flag} \ ${verity_args} 1>&2 sudo rm "$FLAGS_rootfs_hash" sudo losetup -d "$root_dev"