Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1101)

Unified Diff: chromeos_startup

Issue 6770022: run --mode=devstartup unconditionally if we booted developer firmware (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/init.git@0.11.257.B
Patch Set: Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos_startup
diff --git a/chromeos_startup b/chromeos_startup
index 9c04f445471dff0ec31605aafd867c22a5ca0e04..bdfb4c45ed29943db51cf5370cf116a2901b0d86 100755
--- a/chromeos_startup
+++ b/chromeos_startup
@@ -103,20 +103,26 @@ DEVMODE=$((! $?))
FIRMWARE_UPDATE_SCRIPT='/usr/sbin/chromeos-firmwareupdate'
FIRMWARE_UPDATE_LOGS='/mnt/stateful_partition/var/log/update_firmware.log'
if [ -x "$FIRMWARE_UPDATE_SCRIPT" ]; then
- tries="$(get_startup_update_tries)"
- if [ $tries -gt 0 ]; then
- if [ "$DEVMODE" = "1" -o -f /root/.dev_mode ]; then
- # More message on console for developer mode and dev builds
- FIRMWARE_UPDATE_LOGS="/dev/tty1 $FIRMWARE_UPDATE_LOGS"
- fi
- mkdir -p /mnt/stateful_partition/var/log
- [ -z "$BOOT_SPLASH_PID" ] || wait $BOOT_SPLASH_PID
- chromeos-boot-alert update_firmware /dev/tty1
-
- set_startup_update_tries $(( $tries - 1 ))
-
- "$FIRMWARE_UPDATE_SCRIPT" --mode=startup 2>&1 |
+ if [ "$(crossystem mainfw_type)" = developer ]; then
+ FIRMWARE_UPDATE_LOGS="/dev/tty1 $FIRMWARE_UPDATE_LOGS"
+ "$FIRMWARE_UPDATE_SCRIPT" --mode=devstartup 2>&1 |
tee $FIRMWARE_UPDATE_LOGS
+ else
+ tries="$(get_startup_update_tries)"
+ if [ $tries -gt 0 ]; then
+ set_startup_update_tries $(( $tries - 1 ))
+
+ if [ "$DEVMODE" = "1" -o -f /root/.dev_mode ]; then
+ # More message on console for developer mode and dev builds
+ FIRMWARE_UPDATE_LOGS="/dev/tty1 $FIRMWARE_UPDATE_LOGS"
+ fi
+ mkdir -p /mnt/stateful_partition/var/log
+ [ -z "$BOOT_SPLASH_PID" ] || wait $BOOT_SPLASH_PID
+ chromeos-boot-alert update_firmware /dev/tty1
+
+ "$FIRMWARE_UPDATE_SCRIPT" --mode=startup 2>&1 |
+ tee $FIRMWARE_UPDATE_LOGS
+ fi
fi
fi
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698