On several Samsung Android smartphones, included devices supported by Replicant 6.0, the RECOVERY partition is not used by the stock bootloader.

This affects at least the following devices:

What happens with the stock OS and old versions of Android distributions is that both the boot kernel and the recovery are in the KERNEL partition.

In practice in Replicant 6.0:
  • The boot.img is a zImage with an initramfs for both the recovery and the normal boot. That boot.img can be found inside the replicant-6.0 installation zip and it is installed to the KERNEL partition during the Replicant installation.
  • The recovery-i9100.img boots directly into the recovery and probably doesn't have the standard boot initramfs

However as distributions like LineageOS tend to use recoveries like TWRP, it was a problem for such distributions.

So people from XDA came with a scheme called isorec which made it into LineageOS 13.

And Replicant 6.0 is based on LineageOS 13, that is probably in Replicant too, even if it's not used for the Replicant installation and recoveries.

So if the RECOVERY partition contains valid lzop-compressed data, which contains a valid cpio archive, then the image flashed in KERNEL will use that as an initramfs for the recovery.

Updated by Denis 'GNUtoo' Carikli over 4 years ago ยท 2 revisions

Also available in: PDF HTML TXT