bootloader_message: Carve out space reserved for system.
This reduces the wipe space from 32K to 16K. The wipe space is now at the 16K-32K region. The 32K-64K region is now "system space", to complement the vendor space, for generic AOSP usage. Bug: 139156011 Test: manual test Change-Id: I1474bfa65a5f21049ab64ec0aee2f4585b55f60f
This commit is contained in:
@@ -250,6 +250,13 @@ bool write_wipe_package(const std::string& package_data, std::string* err) {
|
||||
if (misc_blk_device.empty()) {
|
||||
return false;
|
||||
}
|
||||
static constexpr size_t kMaximumWipePackageSize =
|
||||
SYSTEM_SPACE_OFFSET_IN_MISC - WIPE_PACKAGE_OFFSET_IN_MISC;
|
||||
if (package_data.size() > kMaximumWipePackageSize) {
|
||||
*err = "Wipe package size " + std::to_string(package_data.size()) + " exceeds " +
|
||||
std::to_string(kMaximumWipePackageSize) + " bytes";
|
||||
return false;
|
||||
}
|
||||
return write_misc_partition(package_data.data(), package_data.size(), misc_blk_device,
|
||||
WIPE_PACKAGE_OFFSET_IN_MISC, err);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user