Allow gsi_tool to set whether GSI installs are single-boot or not.
Previously, init would always write "disabled" back to
/metadata/gsi/install_status, to effectively restore the host image
after the GSI reboots. This is not always desirable, so this patch
introduces a new "one_shot_boot" file. If present, the GSI will only
boot once, otherwise, it can persist until manually disabled.
This also adds a new getGsiBootStatus() method to IGsiService, so the UI
can determine whether the GSI is in single-boot mode or not.
Bug: 126148526
Test: install GSI, reboot twice - back to normal image
gsi_tool enable --single-boot, reboot twice, back to normal image
gsi_tool enable, reboot twice, still in GSI
Change-Id: I49bffea09bc9871502ce7bf3c27518a435357ecd
6 files changed