QFIL – How to Flash Qualcomm Firmware via EDL Mode
Learn how to use QFIL (Qualcomm Flash Image Loader) to flash firmware on Qualcomm Snapdragon Android devices via EDL (Emergency Download) mode. This guide covers programmer file selection, XML configuration, EDL entry methods, and troubleshooting Sahara failures, detection issues, and partition errors.
Pre-Flight Checklist
Complete ALL items before proceeding. Skipping any step increases the risk of bricking your device.
-
Qualcomm USB Drivers InstalledInstall Qualcomm HS-USB QDLoader 9008 drivers. Open Device Manager and confirm the device appears as "Qualcomm HS-USB QDLoader 9008" in EDL mode.
-
QFIL Tool DownloadedDownload QFIL v2.0 or later from the Qualcomm Package Manager (QPM) or a trusted mirror. Verify the MD5 hash before extracting.
-
Correct Firmware Package (MBN/ELF)Obtain the correct firmware for your exact device model. QFIL packages typically include <code>rawprogram0.xml</code>, <code>patch0.xml</code>, and <code>.mbn</code> programmer files.
-
Device Battery ≥ 40%Ensure your device has at least 40% battery. Mid-flash power loss on Qualcomm devices can cause permanent bootloader damage.
-
Full Device BackupBack up all personal data. QFIL flashing rewrites partition tables and will erase the device completely.
-
EDL Mode Access ConfirmedVerify you can enter EDL (Emergency Download) mode on your device. This is usually via a key combo or short-circuiting test points on the PCB.
-
Windows 7/10/11 PC (64-bit)QFIL is Windows-only. Disable Secure Boot in BIOS if unsigned drivers are required. Run QFIL as Administrator.
Guide Steps
Run the Qualcomm driver installer as Administrator. After installation, boot your device into EDL (9008) mode and plug it in via USB. Open Device Manager and confirm the device appears as Qualcomm HS-USB QDLoader 9008 (COMx) under Ports or Universal Serial Bus controllers. If it shows as an unknown device, reinstall the drivers and try a different USB port (avoid hubs).
Right-click QFIL.exe → Run as administrator. In the QFIL window: set Select Build Type to Flat Build. Under Select Programmer, click Browse and locate the .mbn or .elf programmer file from your firmware package (e.g. prog_emmc_firehose_8998_ddr.mbn). Leave all other settings at their defaults.
With the device off and USB connected:
• Method 1 (key combo): Hold Volume Up + Volume Down + Power simultaneously for 10 seconds.
• Method 2 (ADB): adb reboot edl
• Method 3 (test point): Short EDL pads on PCB while connecting USB.
QFIL's status bar should change to Connected and show the COM port. If not, press Refresh Port.
Click Load XML. In the file browser, select rawprogram0.xml first — QFIL will automatically prompt for patch0.xml next. Both files define the partition layout and flashing instructions. Confirm both are loaded in the XML panel. Do not mix XML files from different firmware versions.
Click the Download button. QFIL will begin flashing all partitions sequentially. The progress bar will advance partition by partition. Do not disconnect the USB cable or touch the device during this process. Typical flash time: 5–15 minutes depending on firmware size and USB speed.
The process log at the bottom will show each partition name and its result. Errors on modem partitions are non-critical; errors on aboot or boot require a retry.
After completion, the log will display "Download Succeed" or list any failed partitions. If you see failures:
• Re-check that the correct programmer file is selected.
• Re-enter EDL mode and retry.
• Try a different USB cable or port.
If the log shows success, disconnect the device.
Hold the Power button for 10–15 seconds to boot. First boot on a freshly flashed device takes 3–8 minutes — this is normal as Android runs dex optimization. Do not interrupt. If the device boots to the setup wizard, flashing was successful.
Congratulations! Flash Successful!
You've successfully completed all steps. Your device should now be running the new firmware. If it's booting normally — you're done! Check the troubleshooting section below if you encounter any issues.
Troubleshooting & FAQ
Common errors and their solutions. Read this before asking for help.
This means the programmer file is incompatible with your device's chipset. Confirm your exact SoC (e.g. SDM845, SM8250) and obtain the matching .mbn programmer. Also try: re-enter EDL mode, use a USB 2.0 port instead of 3.0, and disable antivirus during flashing.
Reinstall Qualcomm HS-USB QDLoader 9008 drivers. In Device Manager, right-click the unknown device → Update Driver → Browse → select the driver folder manually. Some devices require an older driver version (Qualcomm_USB_Driver_v1.0.exe).
Cross-region firmware flashing can brick modem partitions and disable cellular. Always use firmware that matches your device's original region code. Check the firmware filename for region identifiers (e.g. GLO, EUX, CHC).
Modem partition errors alone usually do not brick the device. Re-enter EDL mode and retry the flash. If the error persists, the modem firmware file may be corrupt — re-download the firmware package and verify its checksum.
QFIL is Windows-only. On Linux, bkerler/edl is a powerful open-source alternative that supports the same Qualcomm EDL protocol. On macOS, you can run QFIL inside a Windows VM with USB passthrough.
Prioritize our guides in your Google search results.
No comments yet. Be the first to share your experience with this guide!