| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On a device with Virtual A/B, when sideloading and there's
not enough space in super partition to hold CoW, update_engine
falls back to overwriting all source partitions. In that case,
the allocatable space should be the whole super partition, not
a half of it.
Also update doc comments.
Test: unit test. RecoveryErrorShouldDeleteSource fails without the patch
but succeeds with the patch.
Bug: 163613538
Change-Id: I6bd6895a7eabeb4e8436e57b0ac6830c11d1e98f
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Erase AVB footer of system other partition prior to any updates so that if
an update overwrites it partially, and the device rolled back (or even
before we finish writing the partition), and the device factory resets,
mapping system_other as /postinstall won't trigger verity errors and
reboots the device.
Fixes: 152444348
Test: apply update, rollback, then FDR
Test: apply update, then set sys.cppreopt=requested; observe that
/postinstall cannot be mounted.
Change-Id: I62e5bb8f4c31d9a1beff485c47fc4b07a3a5686b
(cherry picked from commit 2969290920696611a67aed184baf71cac062b416)
Merged-In: I62e5bb8f4c31d9a1beff485c47fc4b07a3a5686b
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
DynamicPartitionControl need the list of operations to calculate
COW sizes.
- Remove BootControlInterface::PartitionMetadata. Replace all references
with DeltaArchiveManifest. DeltaArchiveManifest has all information
that PartitionMetadata has.
- Rename all InitPartitionMetadata to PreparePartitionsForUpdate
- Change all PreparePartitionsForUpdate to use new signature
Bug: 138816109
Test: update_enigne_unittests --gtest_filter=*BootControl*:*Dynamic*
Change-Id: I4389ba2b1801addf8c3bc8395e2ea6a9a3ed27a0
|
| |
|
|
|
|
|
| |
We have a better library now.
Test: boot_control_android_unittest
Change-Id: Id4a4ecd9e0883511c4edbe4d548ede5d57d372f0
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
fs_mgr_get_super_partition_name() should be mocked because
it is an external dependency to libfs_mgr.
In tests, deliberately make GetSuperDevice() to return "fake_super"
instead of "super" to make sure it is mocked properly.
Test: run unittests
Test: manually apply OTA
Change-Id: I0f05d99bf168b6e658052b4bd67dc1e82ab36471
|
|
|
Some tests from boot_control_android_unittest only
test logic of UpdatePartitionMetadata. Move them to
dynamic_partition_control_android_unittest.
After moving the test, boot_control_android_unittest
can depend on the MockDynamicPartitionControl (which
is a mocked DynamicPartitionControlInterface) directly
again. It no longer depends on internal implementation
of DynamicPartitionControlAndroid.
Test: unittest
Fixes: 138333673
Change-Id: Idc5f11be98754b8f6d38fcb8604af497e5d86376
|