LineageOS + Magisk adventures

I use LineageOS and Magisk root (A magic tool that help Android Pay and root access coexist). With Lineage you can receive updates every week on monday (for my Oneplus 5T) and so far they’ve been really stable. All was good until the last update of may bricked my cellphone. As it turned out Lineage build was perfectly fine, the bug was with Magisk (Once I removed it and flashed the update – everything worked, except for Magisk). In this blog post I’ll tell about Magisk’s epic fail, and will provide a link to fixed Magisk version that doesn’t turn your phone into a pumpkin brick.

The problem was dumb: Magisk patches boot.img, it detects the end of linux kernel and the start of dtb blob by a 32-bit magic number – 0xd00dfeed. And that sequence happened to be inside the compressed linux kernel (Ooops!). This turned out to be known bug, and Magisk repository even has a Pull Request with a fix.
But now (9th of June 2018) it’s not yet merged and we have no working Magisk build for Oneplus 5/5t. After less than an hour after the post went live, the fixes are merged. We should expect 16.5 soon.

So I had to roll up my sleeves, install Android SDK and compile Magisk with the so much needed fix applied. For those who want the binaries – I posted them at xda-developers. Magisk is marked as 16.4.1, versioncode set really low, so that you will be prompted by Magisk Manager to update to any available official version. Just don’t update until a fix is out, or your phone will instantly turn into a pumpkin brick.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.