You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With the advent of the Generic Kernel Image (GKI) architecture, device partitioning has evolved, resulting in varied recovery partition structures across devices. Some devices use a single dedicated recovery partition, others use an A/B recovery setup (e.g., recovery_a and recovery_b), while some lack a dedicated recovery partition altogether. More information on these partition configurations can be found here.
On devices with non-A/B recovery, a distinct kernel is used specifically for recovery. However, in devices with A/B partition schemes or without a dedicated recovery, the same kernel is used for both recovery and normal boot, effectively making recovery useless for kernel development
By implementing a proxy bootloader, we can address this limitation by loading the recovery kernel from the boot_b slot, ensuring recovery functionality even if kernel is broken during development
How Can We Adapt lk2nd for MTK
Thanks
The text was updated successfully, but these errors were encountered:
Unfortunately lk2nd project is /very/ qcom-centric and uses/relies on a significant amount of CAF code from old qcom's lk. This means that it's most likely unreasonable to add another platform support into lk2nd since the effort needed to implement and maintain that would be way too big.
You're better off creating a different, mtk-specific secondary bootloader based on whatever their BSP bootloader is available for your platform of interest. In this case you may feel free to reuse some of the things implemented in lk2nd, (though I don't think there is that many things that can be reused as-is.)
If you're looking into making such bootloader from scratch, I'd also recommend you to look into using u-boot as a secondary bootloader, which may give you many useful features such as UEFI and will likely be a better choice long term.
We have MTK lk source code here
https://github.com/Gigaset-dev/lk2
However, for devices with secure boot enabled, modifying the primary bootloader is not an option. The only feasible approach is to deploy a proxy secondary bootloader.
https://source.android.com/docs/core/architecture/partitions/generic-boot
Motivation
With the advent of the Generic Kernel Image (GKI) architecture, device partitioning has evolved, resulting in varied recovery partition structures across devices. Some devices use a single dedicated recovery partition, others use an A/B recovery setup (e.g., recovery_a and recovery_b), while some lack a dedicated recovery partition altogether. More information on these partition configurations can be found here.
On devices with non-A/B recovery, a distinct kernel is used specifically for recovery. However, in devices with A/B partition schemes or without a dedicated recovery, the same kernel is used for both recovery and normal boot, effectively making recovery useless for kernel development
By implementing a proxy bootloader, we can address this limitation by loading the recovery kernel from the boot_b slot, ensuring recovery functionality even if kernel is broken during development
How Can We Adapt lk2nd for MTK
Thanks
The text was updated successfully, but these errors were encountered: