yashsingh1/xdaforums huggingface dataset:
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] TheLoonyRebel:
Just curious is there any documentation of what Vache did to get the micro SD card to work on TWRP for this device? We are having a similar issue on the Moto G6 (Ali) with the micro SD not appearing at all. Thanks in advance.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] DomBuback:
Hey!!

Anyone able to make it work after the August patch?

I installed but after rebooting, even appearing in the app list and opening normally, I can not get into recovery if I reboot.

The message "no command".

I can't install magisk either. Stuck in the bootlogo/bootloader unlock message.

Anyone help?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] DomBuback:
Hi!

I finally got it in

OPNS27.76-12-22-9

.

After many tests I was able to run root.

I installed TWRP 3.2.2.0 and the Magisk 17.3-b127e018 (Canary).

https://raw.githubusercontent.com/topjohnwu/magisk_files/master/canary_builds/release.json

Everything working !!!!!!!!
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] tag68:
Thank you for the notification! Did you do anything special except install Magisk? Is f2fs module necessary? Any further difficulties? Is installation of modules working fine also, and settings like hide list get saved properly, surviving a restart?

I'd like to avoid any traps you already fell into and mastered, thank you in advance for the answers ;)
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] DomBuback:
Hi, tag68!

- F2FS is not required.

- All modules work even XPOSED.

- Hide works.

- Reboot works normally.

I did the following:

1 - Relock bootloader

2 - Install the August patch (OPNS27.76-12-22-9) OTA

3 - Unload bootloader

4 - Startup and configure Android normally

4 - Install TWRP 3.2.2.0 (do not restart)

5 - Install Magisk 17.3-b127e018 (Canary)

6 - Reboot

7 - Enjoy!

If it gets stuck in bootlog, flash magisk unninstaller and restart normally (works for any version of Magisk. I tested.)

Hope this helps!

Regards! ;)
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] tag68:
Tried to install Magisk. System Patchlevel Aug 18.

Boot twrp 3.2.3.0.

Flash Magisk 18.0

Did not boot. "Wait 5 seconds" for more than a minute. Turned off by pressing power 20 seconds.

Boot twrp 3.2.3.0.

Flash Magisk uninstaller

Flash Magisk 18.0

No difference. Hangs.

Boot twrp 3.2.3.0.

Flash Magisk uninstaller

My Z Play works fine. No Magisk.

Any idea what to do?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Alberto97:
That happens because system gets early mounted starting from oreo (only on devices that don't have a vendor partition) therefore the mount point is not defined anymore in the fstab but in the dt image contained in the bootimage together with the kernel. With the mount point there are some options as well where verity can be enabled or disabled. Basically Magisk can patch the fstab but seems currently unable to patch the dt image (and I'm not sure if it will ever be).

I patched it for you, just flash this bootimage (only for OPNS27.76-12-22-9 build, it might break modules such as wifi and mods on older builds) and then flash Magisk. Did a quick test and works here :) I'll update OP later.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] tag68:
Thank you very much! If I understood right, Magisk will backup a modified boot image. This means if an OTA is published by Motorola, it does not suffice anymore to uninstall Magisk, as it will restore the modified boot image which it saved. Right?

Although I know this update (build number) is supposed to be the last one for Moto Z Play by Motorola, if a severe security problem occurs, there may be updates, and I'd like to be ready to install them without much hassle. So probably I'm good if I do a Nandroid backup of boot partition using twrp to restore later. (The backup will contain more, but I won't need to restore more).
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Alberto97:
Yes, Magisk will backup my image but you don't have many ways to restore OTA compatibility. It's not only the bootimage the problem, any change to /system (even mount it as writable and it looks like magisk has to do that else all this mess would not be required) will make the OTA fail.

You have two ways to restore compatibility:

Nandroid backup, remember to select System Image instead of System but the first time you booted TWRP you did not have to let it modify the system

Flash just boot and system (assuming you did not modify anything else) from the full firmware package (that at this point looks like the easier way to me)
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] tag68:
I know that. My wish would be a way to prevent any app with root rights to remount system rw. I never want that, but I like to have to access to all folders in TC.

Thank you, I guess i can live fine with that.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] khanpatriot:
Hi, can i flash it over lineage 14.1 os?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] KrisM22:
Why am I having tzdata not found probs - TWRP doesn't have correct time - either your 3.2.1-1 or the 3.2.3 or I assume any other.

Time is not correct so auto date on label, and time stamp on nandroids is not correct. setting with date -s doesn't hold because there's no tzdata to put it in.

Many thanks!

__bionic_open_tzdata: couldn't find any tzdata when looking for localtime!
__bionic_open_tzdata: couldn't find any tzdata when looking for GMT!
__bionic_open_tzdata: couldn't find any tzdata when looking for posixrules!

Something from someone "I've added tzdata to my recovery builds". Need to know how.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] jst98:
I don't thinks it's a bug can corrected by this way or per device, i have the same issue and after a extended time searching, the only concrete information is that it has several devices from several different brands that have been experiencing this problem, the issue is open on twrp's github(at least, the last time i checked), which means it's could be a "general problem" and stills has no concrete solution.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] geospb:
Flashed your TWRP

Thanks a lot!
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] sebx_g1:
Anyone knows for what purpose is system image partition? I accidentally found that it don't need to be restored and rom work without it ?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] hamudistan:
Just a guess, I think its Treble A/B related
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] tag68:
Why do you ask here, and the one who answers guesses instead of using Google? ("Android System Image" for instance gives good results)

Hint: There is a fine explanation available. ;)
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] sebx_g1:
More or less it is enough for me now - I asked here because I had error during restore system image (phone just restared) - so I didn't restore it and all works I was suprised .... :D ... also it is chcecked as default part of backup on this twrp .
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] axelrvf:
Hi everyone,

2 years ago i successfully rooted my phone. Now for some reason the root checker app says it is not.

Does anyone know why? Can i root it again without running the risk of loosing contacts,data or other files? or even briking it?

Thanks!
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] djdelarosa25:
Decryption is broken on latest official 3.4.0-0 build.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] albertovazquez:
hello that version of where did you get it
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] djdelarosa25:
From the official TWRP website here: https://dl.twrp.me/addison/twrp-3.4.0-0-addison.img.html

Try flashing it and report back.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] @rafaelreis:
Same problem happens to me, it is not possible to pass the decryption, the previous version twrp-3.3.1-0-addison.img works normally.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] djdelarosa25:
I've opened an issue here. Alas, I don't think it will get fixed soon because our maintainer is inactive, and I don't think he even has the device anymore.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Mobilettchen:
i now also have a moto z play, and would like to switch to an error-free custom rom without google.

My question - can I use the old twrp (3.3.1.0) without problems?

(... i planed to use linageOS 15).
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] allrightlite:
I have taken 3.1.1-1 (yes, working for 8.1, maybe because 15.1 is 32-bit) for flashing LOS 15.1 (32-bit arm, latest). Had Error 7 with the newest version. Maybe it's a little bit to old, but working :D

But which newest version I should use normally for this rom?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] crazy4jack:
abou descryption passwort in twrp, i set pin in settings and this pin not working to decryptf, wtf
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] megadeth87:
MOD EDIT: ENGLISH TRANSLATION ADDED AS USER VIOLATED FORUM RULES #4

ju juu I entered to see how to root it and I find myself with 28 pages and 3 years of discussion, it seems that it is not so easy, my friends. Better not touch anything.

ORIGINAL POST PRESERVED BELOW

ju juu entré a ver como rootearlo y me encuentro con 28 páginas y 3 años de discusión, parece que no es tan fácil amiguitos. Mejor no toco nada.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Darklandscape:
Can I instal TWRP on verizon version?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Nemtor#5645:
i have this problem

(bootloader) slot-count: not found

(bootloader) slot-suffixes: not found

(bootloader) slot-suffixes: not found

downloading 'boot.img'...

OKAY [ 0.610s]

booting...

(bootloader) permission denied!

FAILED (remote failure)

finished. total time: 0.615s
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Alberto97:
I'm using lj50036's qcom_common repository because CM's one is big for nothing for TWRP purposes. Your environment should be fine now, I guess you forgot to rename back dtbTool to dtbToolCM
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
I build my device tree for TWRP from scratch.

The only thing I ended up using was the ueventd.qcom.rc.

The DTB tool CM issue is weird. It looks like it doesn't get triggered for building even though the string for separate DT is there.

I compiled it manually and placed it in the bin out directory. But in the end for my device I set append DTB in defconfig and used no custom bootimg.mk.

In fact I will try to build an TWRP for Addison based on my device tree. Cause sdcard works for me.

You could help me out and tell me the pre-req's for a working decrypt. I know those are extracted from stock and the qseed daemon is patched to point to /sbin/ instead of system.

But how do you know in what subfolder to place them in root? (Except for the vendor/lib64 part of course) my device uses an arm64 kernel and binarys, which is the only difference I found.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
here you go: *removed*

fastboot boot twrp-3.0.2-2-addison-eng-DEBUG.img

let me know if sdcard works for you.

i had to set "TARGET_HW_DISK_ENCRYPTION := false"

because no matter which qcom-common repo i use. it breaks the build.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] andy55:
it wont load, it is stuck on the loading screen
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Alberto97:
The sdcard issue I think is a kernel side problem since /dev/mmcblk1 block doesn't even exist when inserting the external sd.

We can't read data partition without HW encryption since our device comes with forced encryption (that's why TWRP hangs on the splash screen).

Finally, as I said in the credits, I've picked decryption blobs from LR.Team's TWRP device tree, that's not my work, so I can't help you.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
thanks for testing. i might know why. let me build a new one.

---------- Post added at 18:21 ---------- Previous post was at 18:18 ----------

i know. my device comes with the same forced encryption. i just successfully build the decryption but on the CM-13.0 tree. only bootable_recovery is from omni.

i have no idea how you were able to build encryption on the omni tree.

could you link me to "LR.Team's TWRP device tree" ?

my device uses arm64 blobs. so i can't simply kang yours.

that's why i need more information on how to place them.

i know where i can extract them. just placing and making them work is the real issue.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] Alberto97:
https://github.com/wzsx150/device_twrp_XT1635

You should be able to build TWRP even on CM13 though, just replace the recovery repository and add external/busybox from omni if needed.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
yes i know. i have build an device tree from scratch that works on omni and cm.

the only problem in omni is decrypt breaks the build,

while in CM f2fs is not available. i will have to see where those f2fs sources hide in omni and copy them over to CM.

then everything should be buildable.

here is the new version:

*removed*

it has no F2FS support (see above) but has working disc decryption.

and it should not freeze on the loading screen.

---------- Post added at 18:42 ---------- Previous post was at 18:41 ----------

look above for new version. please test using "fastboot boot recovery.img"
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] mrbracht:
I tested your latest build and it freezes on the install wipe etc screen.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
You mean on the screen where you can actually select the buttons to run a process?

I don't know what might cause the freeze.

It's not happening on my device.

Could you run

"adb shell tail -f /tmp/recovery.log" and see what it outputs while it freezes?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] mrbracht:
Yeah, on the button screen. I will run it when I get home.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] andy55:
I just flashed it, i find i get mixed results just booting it. anyway I dont have any freezing issues, just like the chinese recovery has the pointer icon in the middle, and it doesnt recognize the ext sd.

just curious it shows that its placing backups in data/media/0/twrp and not in storage/emulated/0/ which is what ive been used to. Not a big deal but any way to change it?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
It's the same directory. The only difference is storage/emulated/0/ is a symlink (for legacy) to data/media/0.

What mixed results?

It's weird that the external sd-card is not showing up. I used the exact same settings and RC files as for my device. I used the vendor kernel which came with the latest Moto Z Play stock rom. (The reason for the pointer.) So the external sd-card is indeed an kernel issue.

Here is a thought, it's perhaps because there are like two versions of the Moto Z Play. One with single sim and one with dual sim. If anyone knows can somebody point me to the stock rom for the dual sim version? I could take a look at the kernel config and maybe figure out the difference.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] andy55:
I had some issues when I was messing with the Chinese recovery, so when I flashed it it worked fine, that's all. And as for the storage when I look in storage/emulated/0 there is no backup, but it is in data/media/0. Strange...
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] jatinkhatri:
May be here it is

https://mirrors.lolinet.com/firmware/moto/addison/official/RETASIA/

I've flashed all 3 turn by turn to see the difference.... Every time Both Sim was detected
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
Could you go here? (See attachment) And take a screenshot of this location. You can also use adb shell, of course.

I'm just on the go and not home at my workstation.

It's easier to show it this way.

Also go into this sdhci folder and take a screenshot of the symlinks there. I might have an idea. Not sure yet it it will work but it's worth a try.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] andy55:
Here you go
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
Thanks. So mmcblk1 is there. Unfortunately your app doesn't show symlinks. But I'm guessing it points to the correct location anyway.

It's really strange it doesn't show up in the Moto Z Play TWRP. I will get in touch with an TWRP dev to figure this out.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] jatinkhatri:
I do not have supesu installed.... So i cant.... It Does not show any thing under /dev/ ( I'm using Mixplorer)
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
Could you check if you (Moto Z Play) have this path? Using adb shell.

ls -la /sys/devices/soc/*.ssusb/
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
I think i have fixed the freeze up when using "fastboot boot recoveryimage".

Please check if it freezes up on "fastboot boot" now.

*removed*

No sdcard fix implemented yet.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] andy55:
Sve dobro :good:

Works for me
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
Dobro. Haha.

Did you flash it to the recovery partition or just boot?

I used Alberto's kernel sources this time but appended the DTB (device drivers) to the kernel, to get rid of the custom mkbootimg. Separate DTB leads often to freeze while using "fastboot boot".

Any mouse cursor visible this time?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
i think i found the cause for the missing external-sd in twrp and probably a way to fix it.

could anyone of you guys who uses an sdcard check if this path exists using adb shell?

ls -la /sys/devices/soc/7864900.sdhci/mmc_host*
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
Looks there to me!

shell@addison:/ $ ls -la /sys/devices/soc/7864900.sdhci/mmc_host*
ls -la /sys/devices/soc/7864900.sdhci/mmc_host*
drwxr-xr-x root root 2016-12-21 08:02 mmc1
shell@addison:/ $

---------- Post added at 08:17 AM ---------- Previous post was at 08:04 AM ----------

Tried it on mine and it just freezes still at the white moto screen:

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot boot twrp-3.0.2-2-addis
on-eng-DEBUGv3.img
downloading 'boot.img'...
OKAY [ 0.562s]
booting...
OKAY [ 0.187s]
finished. total time: 0.749s

I already have the CN recovery installed and used it to root (since it automatically disabled verity) then installed the SU 2.79 (system version).
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
Hmm dunno then what's causing it to freeze up.

Does the Chinese TWRP have working sdcard?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
No the CN TWRP does not have working SD that I can tell. (lists it but shows it as 0MB when I have my 200GB card installed)
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
I made a new build based on my findings about the sdcard.

Which hopefully fixes sdcard. Please try and let me know.

Should work while flashing to the partition. Booting? No idea.

https://drive.google.com/file/d/0B0bAICq7NVq1ZTUtOWd0WktuVE0/view?usp=sharing
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
I tried to fastboot boot it and it failed to the same white screen freeze.

So then I flashed it and tried to boot it and it gave me the attached screen screen.

(I did try to boot it twice - that's why you see to failed loads)
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
This is weird all I did from the previous version was to add the sdcard mount point.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
The v4 version was the first one I tried to flash - I only got my phone yesterday and am kinda late to the party. I can try to flash the v3 version later this afternoon if you like as I have a few meetings to deal with now. I wonder if it's due to me having to enter a PIN to boot? I can try turning that off to see if it helps. (I may need a tip where to find that setting however)

recovery-TWRP-3.0.2-20161010-MOTO_Z_PLAY-CN-wzsx150 < flashed - roots but no SD and starts in Chinese and installs Chinese SU by default.

twrp-3.0.2-0-addison < flashed - rooting failed and no SD (looks like it does not disabled verity like the CN one does.)

twrp-3.0.2-2-addison-eng-DEBUGv3 < flashed - no boot unable to test SD

twrp-3.0.2-2-addison-eng-DEBUGv4 < flashed - no boot unable to test SD
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
do run an unlocked bootloader?

verity check is only disabled in the bootloader (boot.img) which has nothing to do with the recovery.img

im building with the chinese uevent now. i saw he disabled some things in there. no idea why he would but worth a try.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
Yes I am unlocked - otherwise I would have not been able to flash anything really.

The only reason I commented about verity is that you have to disable it before rooting with a system based (non-systemless) SU or it wont work.

Since no one has gotten systemless SU working yet on the Z play that I know of - verity needs to be disabled when SU is installed.

The CN one does this when it installs SU so it can be used for rooting then we can replace it with your build, but your build cant be used for rooting at the start.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
Made an v5 *removed*

If it still fails i will go back to a seperated kernel again.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
Downloaded v5 and flashed - same message as v3 and v4.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
Thanks. I will go back to a separated kernel.

Maybe I mixed up that the merged kernel with my attempt to fix the "freeze on boot" actually worked while it didn't.

---------- Post added at 20:05 ---------- Previous post was at 19:27 ----------

I noticed the chinese TWRP is shifted in the base kernel address but apparently it works.

Which is weird... anyway i used chinese kernel/dt.img and build v6.

I just want to see if sdcard is actually detected.

V6 https://drive.google.com/file/d/0B0bAICq7NVq1SWlnMVEyMzFBZzA/view?usp=sharing
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
v6 is getting the same "failed to load kernel!" msg as v3 v4 and v5.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
This is really weird. I used the Chinese TWRP kernel/DT.img and settings and basically all configurations from the Chinese TWRP except what to backup and how to backup and the included the sd-card mount point.

It has probably something to do with the usb configfs conflicting with the mount point.

Must be the reason why external-sd isn't working.

At this point I give up on getting external SD to work in TWRP. Maybe someone else will give it a shot, someone who has the device, maybe.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
Ok. Well if you do want to do any more testing or if there was some way to get more detailed logs that could be helpful - I am willing to do what I can. Thanks for your effort!
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] mrbracht:
I flashed v6 and I got kernel error as well. I'm just glad there is someone out there actually working on this, and for that, I thank you.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] celoxocis:
I will do a last build using exactly the Chinese TWRP device tree but add my sdcard mounting point. It should work as that's my devices mounting point. (Same chipset just arm64 build. Z Play is arm build only).

If that doesn't work. I'm sure it got something to do with Marshmallows introduction of configfs and possibly using a deamon/service to mount the sdcard. Lollipop was different here.

I'm leaving for Xmas/New Year family time but if I get a chance I will access my build server and build it.
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] mrbracht:
Any updates?
[Moto Z Play ROMs, Kernels, Recoveries, & Other Dev] OrBy:
I would not expect anything over the holiday break - people are off to see families etc...