summaryrefslogtreecommitdiff
path: root/common/dynamic_partition_control_interface.h
diff options
context:
space:
mode:
authorAndroid Build Role Account android-build-prod <android-build-team-robot@google.com>2020-09-21 23:16:07 +0000
committerAndroid Build Role Account android-build-prod <android-build-team-robot@google.com>2020-09-21 23:16:07 +0000
commitc0d59af7348f9745e12a8581a05bd3a8fdb472fe (patch)
tree798c7a596105ea07027dcb8c2aa748d70ffe673b /common/dynamic_partition_control_interface.h
parent1df8e19776bae4f4bd40d3612ca24d296a61801e (diff)
parent5ef6aa3fa1b0b7d539ed40ba34d9c7a9da330d10 (diff)
Snap for 6852288 from 5ef6aa3fa1b0b7d539ed40ba34d9c7a9da330d10 to s-keystone-qcom-release
Change-Id: I619850ed167e740c8816851854d07ca7a6019273
Diffstat (limited to 'common/dynamic_partition_control_interface.h')
-rw-r--r--common/dynamic_partition_control_interface.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/common/dynamic_partition_control_interface.h b/common/dynamic_partition_control_interface.h
index 58ebfe46..7c2d0b0c 100644
--- a/common/dynamic_partition_control_interface.h
+++ b/common/dynamic_partition_control_interface.h
@@ -21,6 +21,7 @@
#include <memory>
#include <string>
+#include <vector>
#include "update_engine/common/action.h"
#include "update_engine/common/cleanup_previous_update_action_delegate.h"
@@ -118,6 +119,24 @@ class DynamicPartitionControlInterface {
// progress, while ResetUpdate() forcefully free previously
// allocated space for snapshot updates.
virtual bool ResetUpdate(PrefsInterface* prefs) = 0;
+
+ // Reads the dynamic partitions metadata from the current slot, and puts the
+ // name of the dynamic partitions with the current suffix to |partitions|.
+ // Returns true on success.
+ virtual bool ListDynamicPartitionsForSlot(
+ uint32_t current_slot, std::vector<std::string>* partitions) = 0;
+
+ // Finds a possible location that list all block devices by name; and puts
+ // the result in |path|. Returns true on success.
+ // Sample result: /dev/block/by-name/
+ virtual bool GetDeviceDir(std::string* path) = 0;
+
+ // Verifies that the untouched dynamic partitions in the target metadata have
+ // the same extents as the source metadata.
+ virtual bool VerifyExtentsForUntouchedPartitions(
+ uint32_t source_slot,
+ uint32_t target_slot,
+ const std::vector<std::string>& partitions) = 0;
};
} // namespace chromeos_update_engine