[OFFICIAL][TWRP]Official TWRP For Xiaomi Redmi 5

TingyiChen

Senior Member
May 28, 2016
179
1,238
0
Huanggang
Team Win Recovery Project 3.x, or TWRP3.x for short, is a custom recovery built with ease of use and customization in mind. Its a fully touch driven user interface no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel.
Code:
/*
 * Your warranty is now void.
 *
 * We are not responsible for bricked devices, dead SD cards,
 * thermonuclear war, or you getting fired because the alarm app failed. Please
 * do some research if you have any concerns about features included in this ROM
 * before flashing it! YOU are choosing to make these modifications, and if
 * you point the finger at us for messing up your device, we will laugh at you.
 *
 */
Download : TWRP For Rosy
Source Device Tree: Device Tree For Building TWRP
 
Last edited:

rishi4082

Senior Member
Sep 7, 2016
483
98
28
Team Win Recovery Project 3.x, or TWRP3.x for short, is a custom recovery built with ease of use and customization in mind. Its a fully touch driven user interface no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel.

Download : TWRP For Rosy
Source Device Tree: Device Tree For Building TWRP
Can we expect any custom ROMs for this device?

PS:Sorry for Quoting the OP:3
 

rishi4082

Senior Member
Sep 7, 2016
483
98
28
Team Win Recovery Project 3.x, or TWRP3.x for short, is a custom recovery built with ease of use and customization in mind. Its a fully touch driven user interface no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel.

Download : TWRP For Rosy
Source Device Tree: Device Tree For Building TWRP
Thread is dead for so long..
Do u plan to support Rosy? In the future?
 

miteshmhapankar

New member
Mar 18, 2015
3
0
0
TWRP flash is successful But cannot reboot into TWRP

I successfully flashed TWRP via fastboot. But every time I reboot into recovery, it reboots into Mi Recovery. I tried flashing multiple times, but get the same result every time. Please help.
 

norryhox

Senior Member
May 31, 2015
150
26
28
Wegberg
I have twrp now installed for about 2 weeks
but every time I use it the settings are gone, so language time
vibration and so on
There seems to be no memory access
 

vetzki

Senior Member
Jan 5, 2011
204
71
0
decryption not working

to fix:

repo init twrp source

add rosy device
add qcom common device

device/xiaomi/rosy:

Code:
diff --git a/BoardConfig.mk b/BoardConfig.mk
index e51c06e..9d4ba21 100644
--- a/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -71,6 +71,10 @@ TARGET_RECOVERY_PIXEL_FORMAT := "RGBX_8888"
 TARGET_USERIMAGES_USE_EXT4 := true
 TARGET_USERIMAGES_USE_F2FS := true
 
+# Crypto
+TARGET_HW_DISK_ENCRYPTION := true
+
 # TWRP Configuration
 TARGET_RECOVERY_FSTAB := $(DEVICE_PATH)/twrp.fstab
 RECOVERY_SDCARD_ON_DATA := true
diff --git a/omni.dependencies b/omni.dependencies
deleted file mode 100644
index 0d4f101..0000000
--- a/omni.dependencies
+++ /dev/null
@@ -1,2 +0,0 @@
-[
-]
dl:
https://drive.google.com/file/d/1rfaaQ0f6JqE7MgYdhEq-o0Olo7d_ZxzP/view?usp=sharing

edit:
TARGET_KEYMASTER_WAIT_FOR_QSEE := true not needed
 
Last edited:
  • Like
Reactions: aIecxs

vetzki

Senior Member
Jan 5, 2011
204
71
0
for treble support only different fstab and BoardConfig parameter needed (at least I think so),

Code:
diff --git a/BoardConfig.mk b/BoardConfig.mk
index ce63750..c631a53 100644
--- a/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -90,3 +90,7 @@ TW_THEME := portrait_hdpi
 
 # Disable Mouse Cursor
 TW_INPUT_BLACKLIST := "hbtp_vm"
+
+# Treble
+BOARD_NEEDS_VENDORIMAGE_SYMLINK := false
+TARGET_COPY_OUT_VENDOR := vendor
diff --git a/twrp.fstab b/twrp.fstab
index a581921..97dad11 100644
--- a/twrp.fstab
+++ b/twrp.fstab
@@ -3,15 +3,45 @@
 # specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
 
 /system         ext4      /dev/block/bootdevice/by-name/system               flags=display="System"
-/data           ext4      /dev/block/bootdevice/by-name/userdata             flags=length=-16384
+#/system_image   emmc      /dev/block/bootdevice/by-name/system               flags=backup=0;flashimg=1
+/system_image   emmc      /dev/block/bootdevice/by-name/system               flags=flashimg=1;display="Image system partition"
+#/data           ext4      /dev/block/bootdevice/by-name/userdata             flags=encryptable=footer;length=-16384
+/data           ext4      /dev/block/bootdevice/by-name/userdata             length=-16384
+/data_image     emmc      /dev/block/bootdevice/by-name/userdata    flags=backup=1;display="Image data partition"
+/boot           emmc      /dev/block/bootdevice/by-name/boot                 flags=display="Boot"
 /cache          ext4      /dev/block/bootdevice/by-name/cache                flags=display="Cache"
-/cust           ext4      /dev/block/bootdevice/by-name/cust                 flags=display="Cust";backup=1
+/storage        ext4      /data/media/0                                     flags=display="Internal Storage";usermrf;backup=1;fsflags="bind";removable
+/vendor         ext4      /dev/block/bootdevice/by-name/cust                 flags=display="Vendor";backup=1;wipeingui
+/vendor_image   emmc      /dev/block/bootdevice/by-name/cust                 flags=backup=0;flashimg=1
+
 /recovery       emmc      /dev/block/bootdevice/by-name/recovery             flags=display="Recovery";backup=1
-/boot           emmc      /dev/block/bootdevice/by-name/boot                 flags=display="Boot"
 /misc           emmc      /dev/block/bootdevice/by-name/misc                 flags=display="Misc"
-/efs1           emmc      /dev/block/bootdevice/by-name/modemst1             flags=display="EFS";backup=1
-/efs2           emmc      /dev/block/bootdevice/by-name/modemst2             flags=backup=1;subpartitionof=/efs1
-/firmware       vfat      /dev/block/bootdevice/by-name/modem                flags=display="Firmware";mounttodecrypt
 /persist        ext4      /dev/block/bootdevice/by-name/persist              flags=display="Persist";backup=1
+/persist_image  emmc      /dev/block/bootdevice/by-name/persist              flags=backup=0;flashimg=1
+/splash         emmc      /dev/block/bootdevice/by-name/splash               flags=display="Boot Logo";backup=1;flashimg=1
+
 /sdcard1        auto      /dev/block/mmcblk1p1                               flags=display="MicroSD";storage;wipeingui;removable
 /usb-otg        auto      /dev/block/sda1                                    flags=display="USB Storage";storage;wipeingui;removable
+
+# Bootloader
+/aboot         emmc      /dev/block/bootdevice/by-name/aboot                flags=backup=1;display="Bootloader"
+/cmnlib                emmc      /dev/block/bootdevice/by-name/cmnlib               flags=backup=1;subpartitionof=/aboot
+/tz            emmc      /dev/block/bootdevice/by-name/tz                   flags=backup=1;subpartitionof=/aboot
+/rpm           emmc      /dev/block/bootdevice/by-name/rpm                  flags=backup=1;subpartitionof=/aboot
+/keymaster     emmc      /dev/block/bootdevice/by-name/keymaster            flags=backup=1;subpartitionof=/aboot
+/devcfg                emmc      /dev/block/bootdevice/by-name/devcfg               flags=backup=1;subpartitionof=/aboot
+
+# Modem backup/restore
+/firmware       vfat      /dev/block/bootdevice/by-name/modem                flags=display="Firmware";backup=0;mounttodecrypt;fsflags=ro
+/modem                 emmc      /dev/block/bootdevice/by-name/modem                flags=display="Modem (Image)";backup=1;flashimg=1
+/dsp           emmc      /dev/block/bootdevice/by-name/dsp                  flags=backup=1;subpartitionof=/firmware
+/sec           emmc      /dev/block/bootdevice/by-name/sec                  flags=backup=1;display="Sec"
+#/config       emmc      /dev/block/bootdevice/by-name/config               flags=display="OEM";backup=1
+#/sec          emmc      /dev/block/bootdevice/by-name/sec                  flags=display="Sec";backup=1;subpartitionof=/config
+
+
+# EFS backup/restore
+/efs1          emmc      /dev/block/bootdevice/by-name/modemst1             flags=backup=1;display="EFS"
+/efs2          emmc      /dev/block/bootdevice/by-name/modemst2             flags=backup=1;subpartitionof=/efs1
+/efsg          emmc      /dev/block/bootdevice/by-name/fsg                  flags=backup=1;subpartitionof=/efs1
+/efsc          emmc      /dev/block/bootdevice/by-name/fsc                  flags=backup=1;subpartitionof=/efs1
(note: not all partitions needed, e.g. efs, bootloader, _image stuff)

built recovery but didn't test anything beside backup and flashing xiaomi.eu rom

but do you need such a recovery to install los-15.1 ?