update_kernel: Only check buildID if rebooting
If we're not rebooting, the buildID check is pointless.
BUG=none
TEST=./update_kernel ... --noreboot
Change-Id: I178ea907060102b108b4ca1bc280cd88281147df
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosutils/+/3489914
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Tested-by: Brian Norris <briannorris@chromium.org>
Commit-Queue: Brian Norris <briannorris@chromium.org>
diff --git a/update_kernel.sh b/update_kernel.sh
index c72e548..2c6b05a 100755
--- a/update_kernel.sh
+++ b/update_kernel.sh
@@ -399,14 +399,14 @@
remote_sh uname -r -v
info "old kernel: ${old_kernel}"
info "new kernel: ${REMOTE_OUT}"
+
+ if [ ${FLAGS_vboot} -eq ${FLAGS_TRUE} ]; then
+ check_buildid
+ fi
else
info "Not rebooting (per request)"
fi
- if [ ${FLAGS_vboot} -eq ${FLAGS_TRUE} ]; then
- check_buildid
- fi
-
if [ -n "${FLAGS_boot_command}" ]; then
info "Running boot command on remote"
remote_sh "${FLAGS_boot_command}"