Add IBootControl 1.1 support to libboot_control.
Bug: 138861550
Test: vts
Change-Id: Id4a2963d6ab657d8ab076b7013492a691462b287
diff --git a/boot_control/include/libboot_control/libboot_control.h b/boot_control/include/libboot_control/libboot_control.h
index 6582d02..34a9aff 100644
--- a/boot_control/include/libboot_control/libboot_control.h
+++ b/boot_control/include/libboot_control/libboot_control.h
@@ -18,11 +18,15 @@
#include <string>
+#include <android/hardware/boot/1.1/IBootControl.h>
+
namespace android {
namespace bootable {
// Helper library to implement the IBootControl HAL using the misc partition.
class BootControl {
+ using MergeStatus = ::android::hardware::boot::V1_1::MergeStatus;
+
public:
bool Init();
unsigned int GetNumberSlots();
@@ -34,6 +38,10 @@
bool IsSlotBootable(unsigned int slot);
const char* GetSuffix(unsigned int slot);
bool IsSlotMarkedSuccessful(unsigned int slot);
+ bool SetSnapshotMergeStatus(MergeStatus status);
+ MergeStatus GetSnapshotMergeStatus();
+
+ bool IsValidSlot(unsigned int slot);
const std::string& misc_device() const {
return misc_device_;