EFIDroid: A Second-Stage Bootloader Using UEFI Firmware to Multiboot [XDA Spotlight]
Dual booting and multi-ROM implementations have been a major challenge for Android developers for quite some time. Previous solutions have typically needed substantial device-specific development and further support from ROM developers. Even then, they’re often more complicated than they’re worth for the average ROM user. EFIDroid seeks to remedy all of this.
Formerly known as GRUB4Android, EFIDroid was created by XDA Recognized Developer and Contributor m11kkaa as a means of effectively allowing almost any ROM to be multi-booted without modifying the desired ROM or the current recovery. That means no kernel patches, no kexec, no ROM incompatibility issues, and no headaches for ROM users or developers.
What is EFIDroid?
EFIDroid is a second-stage bootloader designed to allow the device’s original bootloader code to handle the hardware interface itself, thereby simplifying the work that needs to be done to port this application to different devices. This is based on Intel’s EDK II project which has a well-established codebase and provides for substantial extensibility. This implementation utilizes Qualcomm’s open source bootloader, Little Kernel (LK), and as such, support is currently limited to Snapdragon devices.
Installation is as simple as downloading the EFIDroidManager application from the Google Play Store on a rooted device, provided your device has support merged into the project’s github repository. If your device is supported, the application will download the relevant code and let you install, uninstall, reinstall, and repair EFIDroid, as well as allow you to manage your ROMs in a multiboot configuration. Once EFIDroid is installed, ROMs can be installed at the location of your choice (usually somewhere such as /data/media/0/multiboot/NAME).
At the moment, only a handful of devices are supported, including the Moto E (Condor), Moto G 4G (Peregrine), Nokia X2, OnePlus One, Vega Iron 2, and the Fairphone 2. However, m11kkaa is looking for developers to help with porting EFIDroid to other devices – some already gaining “unofficial support.” If you’re able to get EFIDroid working on another device, the process for incorporating it into the application simply requires sending a pull request to the EFIDroid git repository. M11kkaa also informed us that he has future plans to expand the app to potentially support boot plugins and UEFI apps (although keep in mind that these are just plans at this point).
How It Works
EFIDroid leverages LK as an abstraction layer to interact with device hardware. The app enables these components to be taken full advantage of by UEFI’s wide ranging capabilities – among them, the ability to load a Linux Kernel at a
EFIDroid utilizes the Linux Kernel Library as a means to compile the Linux Kernel as a software library. This enables UEFI to use file system drivers for reading and writing to and from multiple boot partitions, as well as giving it the ability to boot to multiple ROMs or recovery environments. EFIDroid can also display error messages from a previously failed boot. The creator has even made mention of potentially using the Linux Kernel Library to add touchscreen support in the future.
All this of course requires root access and an unlocked bootloader on your device but does not require a custom kernel.
More Than Just Multiboot
The implementation of a UEFI bootloader opens up Android devices to many possibilities. Various plug-ins, including diagnostics such as Memtest86, opening a command line, and even games are possible within the UEFI environment. While support is needed to bring more of these possibilities to fruition, EFIDroid still currently offers some key features for compatible devices. Whether used simply as an alternative bootloader for devices which may lack recovery options or as a tool for managing and troubleshooting multiple ROMs or recovery environments, this tool offers all of the above and does so with a user friendly and straight-forward UI to boot.
For further discussions, head on over to the forum thread or follow the project at the links below!EFIDroid on Github EFIDroid’s Official Website EFIDroid’s Slack Community
Have you tried out EFIDroid before? Would you like to see support for your device? Let us know in the comments below!
Want more posts like this delivered to your inbox? Enter your email to be subscribed to our newsletter.