From 97df3956834f00dd084773f1b544f8541584ff32 Mon Sep 17 00:00:00 2001 From: Tao Bao Date: Fri, 4 Dec 2015 17:45:43 -0800 Subject: [PATCH] rootdir: Execute update_verifier for A/B update. update_verifier verifies the updated partitions and marks the current slot as having booted successfully. It needs to be triggered prior to the start of the framework, otherwise it won't be able to fall back to the old system without a data wipe. Bug: 26039641 Change-Id: I6fd183cdd3dfcc72feff2a896368158875b28591 --- rootdir/init.rc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/rootdir/init.rc b/rootdir/init.rc index a0b1acf01..99c552645 100644 --- a/rootdir/init.rc +++ b/rootdir/init.rc @@ -486,6 +486,8 @@ on boot class_start core on nonencrypted + # A/B update verifier that marks a successful boot. + exec - root -- /system/bin/update_verifier nonencrypted class_start main class_start late_start @@ -514,9 +516,13 @@ on property:vold.decrypt=trigger_post_fs_data trigger post-fs-data on property:vold.decrypt=trigger_restart_min_framework + # A/B update verifier that marks a successful boot. + exec - root -- /system/bin/update_verifier trigger_restart_min_framework class_start main on property:vold.decrypt=trigger_restart_framework + # A/B update verifier that marks a successful boot. + exec - root -- /system/bin/update_verifier trigger_restart_framework class_start main class_start late_start