repacker: override slot for flashing images instead of using bootctrl
Bootctrl is being unreliable during repacking. This overrides the slot
while repacking recovery in boot.
Change-Id: I0a04357af4e5f24591792bcfb27ccbd10b0a813b
diff --git a/partitionmanager.cpp b/partitionmanager.cpp
index fe0e3b8..a41fb0c 100755
--- a/partitionmanager.cpp
+++ b/partitionmanager.cpp
@@ -3047,6 +3047,12 @@
}
}
+void TWPartitionManager::Override_Active_Slot(const string& Slot) {
+ LOGINFO("Overriding slot to '%s'\n", Slot.c_str());
+ Active_Slot_Display = Slot;
+ DataManager::SetValue("tw_active_slot", Slot);
+}
+
void TWPartitionManager::Set_Active_Slot(const string& Slot) {
if (Slot != "A" && Slot != "B") {
LOGERR("Set_Active_Slot invalid slot '%s'\n", Slot.c_str());