Select non-verified configuration when booting in legacy mode [factory branch only]
The verity (rootfs verification) now requires chromeos_acpi, which is not
available on non-H2C legacy devices. It was reported that this caused factory
install shim fail to boot.
Not sure if this is a bug in the recovery shim installer, but a quick fix is to
always boot with non-verified config in legacy mode "for factory branch" (this
CL is not going into ToT), because it will be only used to create factory
install shim.
BUG=chromium-os:14059
TEST=build_image --factory_install;
boot on a H2O firmware device, factory install success.
Change-Id: I1ebcbf10149f403a940560ee941ad02f02044671
TBR=gauravsh@chromium.org,wad@chromium.org
diff --git a/create_legacy_bootloader_templates.sh b/create_legacy_bootloader_templates.sh
index 3143637..c61a684 100755
--- a/create_legacy_bootloader_templates.sh
+++ b/create_legacy_bootloader_templates.sh
@@ -126,17 +126,10 @@
EOF
info "Emitted ${SYSLINUX_DIR}/syslinux.cfg"
- if [[ ${FLAGS_enable_rootfs_verification} -eq ${FLAGS_TRUE} ]]; then
- # To change the active target, only this file needs to change.
- cat <<EOF | sudo dd of="${SYSLINUX_DIR}/default.cfg" 2>/dev/null
-DEFAULT chromeos-vusb.A
-EOF
- else
# To change the active target, only this file needs to change.
cat <<EOF | sudo dd of="${SYSLINUX_DIR}/default.cfg" 2>/dev/null
DEFAULT chromeos-usb.A
EOF
- fi
info "Emitted ${SYSLINUX_DIR}/default.cfg"
cat <<EOF | sudo dd of="${SYSLINUX_DIR}/usb.A.cfg" 2>/dev/null
@@ -222,10 +215,6 @@
linux (hd0,3)/boot/vmlinuz ${common_args} root=/dev/sdb3 i915.modeset=1 cros_efi
}
EOF
- if [[ ${FLAGS_enable_rootfs_verification} -eq ${FLAGS_TRUE} ]]; then
- sudo sed -i -e 's/^set default=.*/set default=2/' \
- "${FLAGS_to}/efi/boot/grub.cfg"
- fi
info "Emitted ${FLAGS_to}/efi/boot/grub.cfg"
exit 0
fi