• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[TWRP][P9][3.1.1-1][EMUI 5.x/AOSP N][DECRYPTION SUPPORT]

Search This thread

OldDroid

Recognized Developer
Nov 18, 2012
1,768
6,954
Berlin
teamwin-recovery-project-twrp-logo.jpg



This is only for Huawei P9 (EVA)
Code:
OpenKirin presents unofficial TWRP for stock EMUI 5.x with decryption support.
Intended for usage on stock emui 5.x in combination with unlocked bootloader and
modded boot image with disabled dm-verity (depending on what you want to do).

Code:
[COLOR="red"][B]WARNING:[/B] since 3.1.0-2 update we've enabled image flashing to special partitions -
not just /recovery or /boot partition.
That means your device could be bricked in a few seconds if you do not pay attention
or don't know what you're doing. (Noobs please stay away out of this section!)[/COLOR]


Installation Instructions
Code:
1. Enter fastboot mode on unlocked device
2. flash recovery using the following command: fastboot flash recovery twrp-3.1.1-1-eva.img
3. reboot to recovery!

Rooting Methods
Code:
[B][U]1. Official SuperSU (not just 2.82+)[/U][/B]
1. Ensure you are running stock kernel from b380+
2. Tick the option "Keep vendor partition mounted" inside OpenKirin Settings
3. download and install [URL="www.supersu.com/download"]official SuperSU[/URL]
4. Enjoy!

[B][U]2. Custom SuperSU[/U][/B]
1. Make sure the device running stock EMUI 5.x boot.img
2. flash this modded SuperSU 2.79: [URL="https://drive.google.com/open?id=0BxWP2gF_0Bd_UmQ2Zm9ZRGxBTUE"]download here[/URL]
3. enjoy root :)
[COLOR="red"][B]NOTE:[/B][/COLOR] this is for every device (except kirin 960 based) running emui 5.x without loop support.

[B][U]3. Magisk[/U][/B]
1. ensure you are running a kernel from b380 or later
2. flash magisk
3. enjoy root & safetynet (read note)
[B][COLOR="red"]NOTE:[/COLOR][/B] Magisk Hide is a known problem on Huawei/Honor devices.
Make sure you are not rebooting/turning off your device with Magisk Hide enabled!
You may face a broken fingerprint scanner, do not worry,
simply disable magisk hide and reboot - fps works again!


Downloads
Code:
[LIST]
[URL="https://github.com/OpenKirin/android_device_huawei_eva/releases/download/3.1.1-1/twrp-3.1.1-1-eva.img"][U]download twrp-3.1.1-1-eva.img[/U][/URL]
[/LIST]


FAQ
Code:
Q: What's the code status?
A: 10. June 2017

Q: which P9 models are supported?
A: every model should be supported.

Q: Can i use this TWRP with decrypted /data?
yes, you can! (have a look at the instructions in FAQ)

Q: Can i install LOS or AOSP based roms with this TWRP?
yes, you can! (please follow the installing procedure in the corresponding rom thread)

Q: Can i install Magisk?
A: Every ROM based upon b380+ kernel should now include proper loop support.
Since 3.1.0-3 you are able to flash Magisk through TWRP (recovery kernel  has been updated)

Q: Does official SuperSU work?
A: Yes, even though chainfire included a fix in his upcomming version,
you can use every version of it, just check the "Rooting Instructions" section.

Q: ETAs?
A: No.

Going back from decrypted -> encrypted?
Code:
1. Format /data inside of TWRP
2. Flash eRecovery & Kernel from your currently installed Stock ROM Build
3. Do a factory reset inside of eRecovery
5. Let device boot up
6. Install your current firmware hw_data package & SuperSU using TWRP again
Want to decrypt? No problem.
Code:
1. Format /data inside of TWRP
2. Flash a kernel with forceencrypt disabled
3. bootup your device


Special Thanks
Code:
* [URL="https://forum.xda-developers.com/member.php?u=2335078"]surdu_petru[/URL]
* [URL="https://forum.xda-developers.com/member.php?u=7354786"]XePeleato[/URL]
* [URL="https://forum.xda-developers.com/member.php?u=220328"]paulobrien[/URL]

XDA:DevDB Information
TWRP, Tool/Utility for the Huawei P9

Contributors
OldDroid, surdu_petru, XePeleato
Source Code: https://github.com/OpenKirin


Version Information
Status: Stable

Created 2017-03-01
Last Updated 2017-06-11
 
Last edited:

OldDroid

Recognized Developer
Nov 18, 2012
1,768
6,954
Berlin
Changelog
Code:
[B]TWRP 3.1.1-0[/B]
* bump up TWRP version to 3.1.1
* fix backup of /version
* use device specific and updated prebuilts (+kernel)
* remove the ability to flash images to ext4 mounted partitions

[B]TWRP 3.1.0-3[/B]
* kernel updated for proper loop support
* magisk can now be installed and is supported by every rom running b380+ kernel (tested on b383)
* native_package.xml has been changed to device specific version

[B]TWRP 3.1.0-2[/B]
* Add support for NTFS formatted MicroSD cards or OTG drives
* Enabled direct image flashing to special partitions
(be careful when using it - one wrong klick means brick in a second!)
* TWRP is now compatible with AOSP based ROMS (LineageOS)
and decrypted Stock ROMS, transition from Stock to LOS is possible.
* Correct versioning - Device version is now comming from the common base.
* 3650-common: introduce init.recovery.hi3650.power.rc for better power handling

[B]TWRP 3.1.0-1[/B]
* proper handling of decryption (improves booting time by ~10 seconds)
* do not wipe /data/hw_init during /data wipe or factory reset to prevent system errors
* cleanup ramdisk, reduced image size by 10mb

[B]TWRP 3.1.0-0[/B]
* add the ability to format oem specific partitions
* add back f2fs support so we can format /data as f2fs
* bump up twrp version to 3.1.0
 
Last edited:

frenzissi

Member
Jan 11, 2017
17
5
I have a p9 with b378 rooted and a working version of twrp (no data encryption), is it possible to install this thru my twrp?
 

mihairimia

Senior Member
Apr 27, 2010
178
26
Thank you for your effort. It installed flawless on my L19C432 with B378.
I tried to root it but it failed. Chainfire's latest zip rebooted my phone and phh's ended with error 1.

LE: I flashed @Atarii B378 img and now I am rooted. AdAway is working as expected. Thank you!
 
Last edited:

Atarii

Senior Member
May 10, 2011
734
654
Thank you for your effort. It installed flawless on my L19C432 with B378.
I tried to root it but it failed. Chainfire's latest zip rebooted my phone and phh's ended with error 1.
You will still need to use my pre-rooted boot images, that's separate from TWRP. L19 is work in progress
 

OldDroid

Recognized Developer
Nov 18, 2012
1,768
6,954
Berlin
Thank you for your effort. It installed flawless on my L19C432 with B378.
I tried to root it but it failed. Chainfire's latest zip rebooted my phone and phh's ended with error 1.
i will look into it today, could you link me the zip files you used for rooting? especially phhs version (supersu is not supported, thats why we removed it from the entire recovery ecosystem)

Regards
 

mihairimia

Senior Member
Apr 27, 2010
178
26
i will look into it today, could you link me the zip files you used for rooting? especially phhs version (supersu is not supported, thats why we removed it from the entire recovery ecosystem)

Regards

The one from here https://forum.xda-developers.com/p9/how-to/twrp-3-0-2-0-n-t3506947. Dont waste your time. Its working if B378 img from Atarii is flashed.

You will still need to use my pre-rooted boot images, that's separate from TWRP. L19 is work in progress

L09 B378 img is ok for now. Still need to test if system apps uninstall. But I am happy Adaway is working!
 

cbgti

Senior Member
May 30, 2009
164
34
Is somebody here to explain me (quick explain) what is encryption/decryption support?
And I never know... When I launch TWRP for the 1st time, we have to choose if we want to let the system untouched.
Must I let the system in "Read Only mode" or not? I don't understand what it can change (I didn't have to choose that on my previous (HTC) devices)...
Thanks.
 

Atarii

Senior Member
May 10, 2011
734
654
Is somebody here to explain me (quick explain) what is encryption/decryption support?
And I never know... When I launch TWRP for the 1st time, we have to choose if we want to let the system untouched.
Must I let the system in "Read Only mode" or not? I don't understand what it can change (I didn't have to choose that on my previous (HTC) devices)...
Thanks.

Encryption/decryption support is related to the /data partition (where your user files are stored). The encryption scheme changed for Nougat, so this is the first TWRP that supports being able to read/write to that encrypted /data partition.

Read-only system mode (aka systemless mode) - some people do not touch the system partition, so they can later apply OTAs easier (as they perform a diff on system files)
 
  • Like
Reactions: swedenboy and cbgti

maliniaka

Member
Aug 19, 2016
42
2
After flashing ARISE Sound System dolby atmos (doesn't run) and viper (can't install driver) don't work :( Any solutions?
 

Top Liked Posts

  • There are no posts matching your filters.
  • 46
    teamwin-recovery-project-twrp-logo.jpg



    This is only for Huawei P9 (EVA)
    Code:
    OpenKirin presents unofficial TWRP for stock EMUI 5.x with decryption support.
    Intended for usage on stock emui 5.x in combination with unlocked bootloader and
    modded boot image with disabled dm-verity (depending on what you want to do).

    Code:
    [COLOR="red"][B]WARNING:[/B] since 3.1.0-2 update we've enabled image flashing to special partitions -
    not just /recovery or /boot partition.
    That means your device could be bricked in a few seconds if you do not pay attention
    or don't know what you're doing. (Noobs please stay away out of this section!)[/COLOR]


    Installation Instructions
    Code:
    1. Enter fastboot mode on unlocked device
    2. flash recovery using the following command: fastboot flash recovery twrp-3.1.1-1-eva.img
    3. reboot to recovery!

    Rooting Methods
    Code:
    [B][U]1. Official SuperSU (not just 2.82+)[/U][/B]
    1. Ensure you are running stock kernel from b380+
    2. Tick the option "Keep vendor partition mounted" inside OpenKirin Settings
    3. download and install [URL="www.supersu.com/download"]official SuperSU[/URL]
    4. Enjoy!
    
    [B][U]2. Custom SuperSU[/U][/B]
    1. Make sure the device running stock EMUI 5.x boot.img
    2. flash this modded SuperSU 2.79: [URL="https://drive.google.com/open?id=0BxWP2gF_0Bd_UmQ2Zm9ZRGxBTUE"]download here[/URL]
    3. enjoy root :)
    [COLOR="red"][B]NOTE:[/B][/COLOR] this is for every device (except kirin 960 based) running emui 5.x without loop support.
    
    [B][U]3. Magisk[/U][/B]
    1. ensure you are running a kernel from b380 or later
    2. flash magisk
    3. enjoy root & safetynet (read note)
    [B][COLOR="red"]NOTE:[/COLOR][/B] Magisk Hide is a known problem on Huawei/Honor devices.
    Make sure you are not rebooting/turning off your device with Magisk Hide enabled!
    You may face a broken fingerprint scanner, do not worry,
    simply disable magisk hide and reboot - fps works again!


    Downloads
    Code:
    [LIST]
    [URL="https://github.com/OpenKirin/android_device_huawei_eva/releases/download/3.1.1-1/twrp-3.1.1-1-eva.img"][U]download twrp-3.1.1-1-eva.img[/U][/URL]
    [/LIST]


    FAQ
    Code:
    Q: What's the code status?
    A: 10. June 2017
    
    Q: which P9 models are supported?
    A: every model should be supported.
    
    Q: Can i use this TWRP with decrypted /data?
    yes, you can! (have a look at the instructions in FAQ)
    
    Q: Can i install LOS or AOSP based roms with this TWRP?
    yes, you can! (please follow the installing procedure in the corresponding rom thread)
    
    Q: Can i install Magisk?
    A: Every ROM based upon b380+ kernel should now include proper loop support.
    Since 3.1.0-3 you are able to flash Magisk through TWRP (recovery kernel  has been updated)
    
    Q: Does official SuperSU work?
    A: Yes, even though chainfire included a fix in his upcomming version,
    you can use every version of it, just check the "Rooting Instructions" section.
    
    Q: ETAs?
    A: No.

    Going back from decrypted -> encrypted?
    Code:
    1. Format /data inside of TWRP
    2. Flash eRecovery & Kernel from your currently installed Stock ROM Build
    3. Do a factory reset inside of eRecovery
    5. Let device boot up
    6. Install your current firmware hw_data package & SuperSU using TWRP again
    Want to decrypt? No problem.
    Code:
    1. Format /data inside of TWRP
    2. Flash a kernel with forceencrypt disabled
    3. bootup your device


    Special Thanks
    Code:
    * [URL="https://forum.xda-developers.com/member.php?u=2335078"]surdu_petru[/URL]
    * [URL="https://forum.xda-developers.com/member.php?u=7354786"]XePeleato[/URL]
    * [URL="https://forum.xda-developers.com/member.php?u=220328"]paulobrien[/URL]

    XDA:DevDB Information
    TWRP, Tool/Utility for the Huawei P9

    Contributors
    OldDroid, surdu_petru, XePeleato
    Source Code: https://github.com/OpenKirin


    Version Information
    Status: Stable

    Created 2017-03-01
    Last Updated 2017-06-11
    15
    little status update:
    an update is comming today, this fixes the issue of not beeing able to format device specific partitions.
    And i will overtake the mentainer part on twrp side for eva to get this thing official!

    Regards
    14
    Changelog
    Code:
    [B]TWRP 3.1.1-0[/B]
    * bump up TWRP version to 3.1.1
    * fix backup of /version
    * use device specific and updated prebuilts (+kernel)
    * remove the ability to flash images to ext4 mounted partitions
    
    [B]TWRP 3.1.0-3[/B]
    * kernel updated for proper loop support
    * magisk can now be installed and is supported by every rom running b380+ kernel (tested on b383)
    * native_package.xml has been changed to device specific version
    
    [B]TWRP 3.1.0-2[/B]
    * Add support for NTFS formatted MicroSD cards or OTG drives
    * Enabled direct image flashing to special partitions
    (be careful when using it - one wrong klick means brick in a second!)
    * TWRP is now compatible with AOSP based ROMS (LineageOS)
    and decrypted Stock ROMS, transition from Stock to LOS is possible.
    * Correct versioning - Device version is now comming from the common base.
    * 3650-common: introduce init.recovery.hi3650.power.rc for better power handling
    
    [B]TWRP 3.1.0-1[/B]
    * proper handling of decryption (improves booting time by ~10 seconds)
    * do not wipe /data/hw_init during /data wipe or factory reset to prevent system errors
    * cleanup ramdisk, reduced image size by 10mb
    
    [B]TWRP 3.1.0-0[/B]
    * add the ability to format oem specific partitions
    * add back f2fs support so we can format /data as f2fs
    * bump up twrp version to 3.1.0
    11
    Hey, I got a problem installing the reovery...
    Im gonna copy the log of my fastboot:
    C:\WINDOWS\system32>fastboot flash recovery C:\twrp-3.1.0-0-eva.img
    target reported max download size of 471859200 bytes
    sending 'recovery' (36216 KB)...
    OKAY [ 1.149s]
    writing 'recovery'...
    OKAY [ 0.493s]
    finished. total time: 1.642s

    C:\WINDOWS\system32>fastboot reboot
    rebooting...

    finished. total time: 0.021s
    After the device reboot and I pressed the volume up key to get to the trwp recovery, the huawei eRecovery starts...

    Can anyone help me please? I unlocked my phone after updating it to EMUI 5.0...


    After TWRP was installed, you should reboot your device into TWRP in this way :

    - with your device in bootloader mode ( and after TWRP was installed by : fastboot flash recovery C:\twrp-3.1.0-0-eva.img, in your case ) you should make three operations at the same time :

    * press & keep pressed Volume Up
    * fastboot reboot
    * disconnect the USB cable as soon as possible !

    Right now your device will boot into TWRP ( you can release Volume Up, at the same time with : "your device is booting now ... ") ;)

    This is the right way to install any custom recovery !
    10
    New Release is up! TWRP 3.1.1-1 for Huawei P9 (eva)

    Changelog:
    * OpenKirin Edition with inbuilt Huawei device specific settings
    * /vendor is now mounted by default and cannot be unmounted (unless you disable it in the settings) to prevent installation issues on multiple projects
    * limited the backup partitions to /boot, /cache, /data, /system and /vendor to ensure a normal restorable os setup
    * system and vendor images can now be flashed directly through TWRP ("System Image", "Vendor Image")

    check OP or Github for more information.

    Regards