[LeEco Le 2 Guides, News, & Discussion] PojntFX:
Simple Step-by-Step-Guide: How to Unbrick the LeEco Le 2 (X52x/Snapdragon), Unlock and Clean Install a Rooted Free/Libre and Open Source Android 8.1 Distribution (LineageOS 15.1) with OTA updates

You can also read this document in the Markdown format over on this GitLab Snippet!

Yes, this probably has been documented somewhere before, but I still want to share it. It took me more than two complete days to figure this out and probably this could help someone, so why not?

Prerequisites

LeEco Le 2 (X52x/Snapdragon)

3A USB charger

GNU/Linux (tested on Fedora 28 GNU/Linux) with root access or Windows workstation with administrative priviledges

Disclaimer

This will wipe all data on your phone, so do a backup before if still possible.

/*
* I'm not responsible for bricked devices, dead SD cards, thermonuclear war, or you getting fired because the alarm app failed (like it did for me...).
* Please do some research if you have any concerns about features included in the products you find here before flashing it!
* YOU are choosing to make these modifications, and if you point the finger at me for messing up your device, I will laugh at you.
* Your warranty will be void if you tamper with any part of your device / software.
* Same statement for XDA.
*/

Fixable Phone States

This method should work on pretty much every state the phone is in, even a fully working one. I've tested it on the following ones:

LED is blinking/flashing red, no visible charging process

A flashing process failed halfway through (TWRP, Modem, QFIL, whatever)

Bootloop

... (everything that didn't destroy the internal debug bridge that Qualcomm provides)

Personally, I tried to install LineageOS 15.1 on a Le 2 using an outdated version of TWRP without OEM unlocking in the stock ROM. Stuff only went downwards from here on, with the backups failing, TWRP getting corrupted, flashing processes failing midway (because I forgot to charge the phone before and I kept in plugged into my computer which did not provide enough amperage ... yes I know that this is a stupid thing to do), to the phone having a deeply discharged battery and not wanting to turn on, with only the red light blinking/flashing.

My System

This guide will work using pretty much any GNU/Linux, but you will need to have access to a Windows machine to use the proprietary Qualcomm flash tool. This is only necessary if you have the red blinking/flashing light brick or you have locked the OEM unlock function and can't flash the stock rom to unlock it (both happened to me).

[pojntfx@pojntfx-mainmachine-fedora ~]$ screenfetch
/:-------------:\ pojntfx@pojntfx-mainmachine-fedora
:-------------------:: OS: Fedora 28 TwentyEight
:-----------/shhOHbmp---:\ Kernel: x86_64 Linux 4.17.2-200.fc28.x86_64
/-----------omMMMNNNMMD ---: Uptime: 3d 6h 39m
:-----------sMMMMNMNMP. ---: Packages: 2305
:-----------:MMMdP------- ---\ Shell: bash 4.4.23
,------------:MMMd-------- ---: Resolution: 5120x2160
:------------:MMMd------- .---: DE: GNOME
:---- oNMMMMMMMMMNho .----: WM: GNOME Shell
:-- .+shhhMMMmhhy++ .------/ WM Theme:
:- -------:MMMd--------------: GTK Theme: Adwaita [GTK2/3]
:- --------/MMMd-------------; Icon Theme: Adwaita
:- ------/hMMMy------------: Font: Cantarell 11
:-- :dMNdhhdNMMNo------------; CPU: Intel Core i5-4690K @ 4x 3.9GHz [27.8°C]
:---:sdNMMMMNds:------------: GPU: AMD TAHITI (DRM 2.50.0 / 4.17.2-200.fc28.x86_64, LLVM 6.0.0)
:------:://:-------------:: RAM: 5947MiB / 12018MiB
:---------------------://

I used an old HP EliteBook 2740p as my Windows machine (running Windows 10).