chenxiaolong / avbroot

Sign (and root) Android A/B OTAs with custom keys while preserving Android Verified Boot
GNU General Public License v3.0
436 stars 41 forks source link

Update CoW size estimate when replacing entire dynamic partitions #307

Closed chenxiaolong closed 1 week ago

chenxiaolong commented 1 week ago

Otherwise, if the partition size increases or the data becomes more incompressible, update_engine might fail to flash the partition due to the CoW block device running out of space.

Since all known VABC-enabled OTAs in the wild currently use CoW v2 with lz4 compression, this is the only configuration we support. CoW v3 also exists in AOSP's libsnapshot_cow, but is much more complicated to implement and is not yet used, even in the Android 15 beta OTAs.

Fixes: #306