diff options
author | Yifan Hong <elsk@google.com> | 2018-10-18 17:46:27 -0700 |
---|---|---|
committer | Yifan Hong <elsk@google.com> | 2018-10-26 18:23:52 +0000 |
commit | d4db07e9bbf7c606d20e88c1d8d4f36697718ce7 (patch) | |
tree | 3400460f40d42709694c9dfdeea9ae789f4520c3 /scripts/update_payload/format_utils.py | |
parent | 9acd9cb3eda3e274ba137b3fb9e4b598965d5647 (diff) |
Support updateable groups.
Adds updateable group support to OTA.
* DeltaPerformer combines partition sizes with
dynamic_partition_metadata to
BootControlInterface::PartitionMetadata.
* BootControlAndroid::InitPartitionMetadata:
* Copy all groups / partitions from source metadata slot
* Remove all groups / partitions mentioned in the manifest (of the
target slot)
* Re-add all groups / partitions mentioned in the manifest.
* BootControlAndroid::InitPartitionMetadata can check
the incoming PartitionMetadata to see if a partition is dynamic
or not. The guessing logic is completely removed.
* Because a partition is removed then re-added, there is no need
for preserving the entry with size 0 to indicate that a partition
is removed. When update_engine sees a partition in a group "foo" on
the device, but manifest contains group "foo" without the partition,
it removes the partition.
* Hence, Removing a partition does NOT require keeping the entry (i.e.
RemovePartition is used instead of ShrinkPartition(0) ). This makes
retrofitting dynamic partitions on older devices easier.
The following is now allowed:
- Adding / removing / resizing partitions
- Adding / resizing groups
It is not allowed to remove a group, but a group can always be resized
to zero to deprecate it.
Test: update_engine_unittests
Bug: 117182932
Change-Id: I39d77f1d1d1fc52fc245f3de699635e6a429015e
Diffstat (limited to 'scripts/update_payload/format_utils.py')
0 files changed, 0 insertions, 0 deletions