[GUIDE][GRIFFIN] How to make and use GSIs + Examples (DU & AOSP) - Moto Z Guides, News, & Discussion

since I’ve enabled (semi-fake-)treble on lineage 15.1 rom, we can say our phone is treblized and we should be able to flash GSIs (generic system image) on it, can we?
First requirement of project Treble is vendor partition, but we haven’t this vendor partition on griffin.
We have an oem partition, but its too small to be used as vendor for griffin, our vendor files are something like 600mb but oem partition is 200mb, Very small.
So we can say this treble we have already is fake : Motorola didn’t enabled treble by default on this
And semi : without vendor partition
But with new project CLT (Capire le treble) we can install GSI, but need little work
We can’t directly flash GSIs to our system partition cause we will lose our vendor files which exists on “/system/vendor” so somehow we should “copy paste” vendor files into GSI, this is what CLT is doing.
To use CLT all we need is Linux or mac to generate DSSI (device specific system image) from GSI
Here is full thread of CLT with YouTube video: https://forum.xda-developers.com/pr.../tool-capire-le-treble-terble-vendor-t3774629
It’s not very hard to say only devs can make DSSI
All you need to do is download latest lineage and find one GSI rom from here : https://forum.xda-developers.com/project-treble/trebleenabled-device-development
And start CLT on it and flash output of it.
Get griffin “proprietary-files.txt” from here : https://gist.github.com/erfanoabdi/447e90e65a3b037abebcc30da4a71935
Griffin system size: 5704253440
How to flash this images?
Put the system image on internal storage and reboot to recovery (twrp) -> install latest lineage -> select “install image” -> install that image as “system image”
• For now, you need to also flash this permissiver zip to make selinux permissive : https://www.androidfilehost.com/?fid=746010030569967557
Somehow like this: https://www.xda-developers.com/flash-generic-system-image-project-treble-device/
Bugs :
• Selinux must be permissive
Examples:
(images compressed with 7z)
Dirtyunicorn system.img: https://www.androidfilehost.com/?fid=890129502657596534
AOSP system.img: https://www.androidfilehost.com/?fid=890129502657596533

why not use /oem and mount it as /vendor?

DustArma said:
why not use /oem and mount it as /vendor?
Click to expand...
Click to collapse
Stock firmware gets mad if you erase it

parrotgeek1 said:
Stock firmware gets mad if you erase it
Click to expand...
Click to collapse
You can find /oem in the firmware packages and it's not like a treble ROM will be using the /oem partition

DustArma said:
You can find /oem in the firmware packages and it's not like a treble ROM will be using the /oem partition
Click to expand...
Click to collapse
I think it was too small

Just out of curiosity, is repartitioning a possibility?

apocalypse_bg said:
Just out of curiosity, is repartitioning a possibility?
Click to expand...
Click to collapse
Yeah, it is, for the Mi A1 at least, but I think you could possibly do the same thing with the Moto Z, too.

Hello Sr., I have managed to install CLT a DotOS but I lost a baseband can inform how to fix?

matheusgcdj said:
Hello Sr., I have managed to install CLT a DotOS but I lost a baseband can inform how to fix?
Click to expand...
Click to collapse
Give me logs : adb logcat -b radio
Which rom is used as base?

erfanoabdi said:
Give me logs : adb logcat -b radio
Which rom is used as base?
Click to expand...
Click to collapse
Here is the logcat, I used Lineage OS official for the operation, but I downloaded your Lineage and got the same answer, I am sending the logcat by Lineage Official

erfanoabdi said:
• For now, you need to also flash this permissiver zip to make selinux permissive
Click to expand...
Click to collapse
This file change depending on the device?

sorry, i am a noob
to use CLT
only to unlock bootloader and flash twrp
and then flash this image in system
img?

Woo,this is a good news for MOTO Z.I am a new hand.So I think it's difficult for me.and I want to flash that sGSI about MIUI 10,is there any easy way to do it ? thanks!

Could anybody help and create the DSSI for griffin from this GSI, please. Erfanoabdi's examples works pretty good but they are based on Oreo.

Related

[A-ONLY][TREBLE][8.0][A530F/A530W/A730F]Vendor Oreo For Galaxy A8/A8+ 2018

VENDOR FOR GSI (Generic System Image)
I'm not responsible for whatever damage this could possibly cause to your device.
Before Starting Make Sure You Treble Your Bevice By This Guide here​ If you appreciate the work i have done, Feel free to buy me a cup of coffee @paypal ​
Just to Make it clear, Treble Vendor for A8/A8+ is been ported from A7 2018 Oreo. We have tested many Oreo GSI from phhuson generic list and they are booted with this vendor. We have also tested Pie GSI, most of them didn't booted but few did(Phh-AOSP-9.0).
What is GSI?
A Generic System Image (GSI) is a system image. It is considered a "pure Android" implementation with Android Open Source Project (AOSP) code that any Treble device can run successfully. For more info visit here : https://source.android.com/setup/build/gsi
What is working?
Wi-Fi & Hotspot
Telephony & Ril (Mobile Data, Calls, SMS, MMS)
NFC
Camera
Bluetooth
GPS
Fingerprint
All Sensors
2D/3D Graphics + Vulkan
What is not working?
VoLTE
**Important: Vendor attached to this thread is stable, If you find any bugs on GSI, report it to their respective maintainer's with logs.
Instructions
1- Make Sure u Treble your device
2- Wipe System, Vendor, Data, Cache
3- Flash Vendor-Installer.zip (includes Kernel)
4- Flash GSI as system_image on TWRP
5- Reboot and start using your device
Downloads. Changelogs below
Credits
IF you helped in this project and i forgot you, tell me in a PM or in a reply
@corsicanu for repartition help
@lzzy12 , @TaifAljaloo , @Griffin98 , @somadsul , @ananjaser1211 for lot of contributions and helping to fix bugs
@enesuzun2002 , @neondragon1909 for helping to fix FP and NFC
@587.saboor for testing
XDA:DevDB Information
Project Treble, Vendor for Samsung Galaxy A8 / A8+ 2018
Kernel Source
Contributors
prashantp01
ROM OS Version: 9.x Pie
ROM Kernel: Linux 4.x
Version Information
Status: Stable
Current Stable Version: v1.0
Created 2019-02-12
Last Updated 2019-02-12
Download
Vendor-Installer For Android 8.1 / 9.0 GSIs (includes Kernel)
You can download an A only ARM64 GSI from here
OpenGapps
Fix for bugs
Camera Fix
Fingerprint Fix
Changelog
V1.0
-initial release
reserved 2
Massive thanks to you guys !
Instructions
1- Make Sure u Treble your device
2- Flash Vendor-Installer.zip (includes Kernel)
3- Flash GSI as system_image on TWRP
4- Reboot and start using your device
bro after no. 1 am i wipe chache dalvik system and vendor and go to no. 2?
freemod said:
Instructions
1- Make Sure u Treble your device
2- Flash Vendor-Installer.zip (includes Kernel)
3- Flash GSI as system_image on TWRP
4- Reboot and start using your device
bro after no. 1 am i wipe chache dalvik system and vendor and go to no. 2?
Click to expand...
Click to collapse
Yes, u should wipe first
any screenshots?
Is this the same vendor as in this thread (but it's only the vendor here), or are there any differences? (if this is any better/different, can I "upgrade" to it without wiping my existing phh-treble install?)
Gabriel529 said:
any screenshots?
Click to expand...
Click to collapse
This is not a ROM, just a Vendor which lets you flash GSI ROMS. Therefore, no screenshots could be given.
VDavid003 said:
Is this the same vendor as in this thread (but it's only the vendor here), or are there any differences? (if this is any better/different, can I "upgrade" to it without wiping my existing phh-treble install?)
Click to expand...
Click to collapse
It's not the same, he fixes a lot of things to make it stable now (as NFC or Camera). About your installation question, I don't know.
ROM
Good night my friend. I wonder if using this increases the possibility of being compatible with other Roms, or does it basically equal to TWRP treble and creator treble equal to what you have here on another topic? If the answer is that it increases the possibility of roms compatible, can I do the installation over the other version creator and twrp treble? Sorry the English.
To anyone wondering: I've managed to replace my existing vendor+kernel by flashing the zip and suprisingly I had to remove the pattern lock from my phone and re-add it because system ui just chrashed every time I entered my pattern. Note: I'm on AOSP Phh-treble 9.0 V109 (I know V110 is already out but I'm lazy..)
Also I had to reflash magisk but that's expected after a new boot img.
Hi,
thank you so much for that vendor base. Everything seems to be ok, except one thing though : MTP does not work if i activate usb debugging. Is this vendor or gsi related ? btw i tried the four gsi you recommend in your original post, same behaviour. I'm on sm-a530f
Nice week end to all.
VDavid003 said:
To anyone wondering: I've managed to replace my existing vendor+kernel by flashing the zip and suprisingly I had to remove the pattern lock from my phone and re-add it because system ui just chrashed every time I entered my pattern. Note: I'm on AOSP Phh-treble 9.0 V109 (I know V110 is already out) but I'm lazy..
Also I had to reflash magisk but that's expected after a new boot img.
Click to expand...
Click to collapse
I didn't get u , also why r u using old builds, always go with the latest which includes fixes
cedlefou said:
Hi,
thank you so much for that vendor base. Everything seems to be ok, except one thing though : MTP does not work if i activate usb debugging. Is this vendor or gsi related ? btw i tried the four gsi you recommend in your original post, same behaviour. I'm on sm-a530f
Nice week end to all.
Click to expand...
Click to collapse
Thanks for the complement, issues related to mtp and usb debugging is because of magisk..... just report it to magisk developer with proper logs
prashantp01 said:
I didn't get u , also why r u using old builds, always go with the latest which includes fixes
Click to expand...
Click to collapse
It's just that I only checked the xda thread for phh treble and that still has v109 as the newest. (On github there is a v110 build) and I'm just lazy to upgrade, since this version is good for me.
About the thing, idk what you didn't get.
Anyways, great work!
Someone can post any screenshot?
Asop extended
mchlbenner said:
Asop extended
Click to expand...
Click to collapse
Here in my those rom based on Android 9, the video call of whatsapp hangs. Does this bug also occur?
VDavid003 said:
To anyone wondering: I've managed to replace my existing vendor+kernel by flashing the zip and suprisingly I had to remove the pattern lock from my phone and re-add it because system ui just chrashed every time I entered my pattern. Note: I'm on AOSP Phh-treble 9.0 V109 (I know V110 is already out but I'm lazy..)
Click to expand...
Click to collapse
How reliable is it? Is there any major bugs? How is battery life compared to OEM firmware?
How can I flash a .img.xz file?
edit: its an archive lol
mchlbenner said:
Asop extended
Click to expand...
Click to collapse
hello . are u can use fingerprint in aosp extended?

[UNOFFICIAL][ENCRYPTION][wrappedkey] TWRP 3.3.1-6: proper system_as_root & decryption

[UNOFFICIAL][ENCRYPTION][wrappedkey] TWRP 3.3.1-6: proper system_as_root & decryption
Code:
/*
* 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.
*/
Introduction
This is an unofficial build of TWRP for Redmi Note 7 Pro (violet). Differences with the official one include:
- Supports CAF-based wrappedkey encryption (decryption) properly (tested with MIUI 10.3.5.0)
- Supports decrypting devices that have screen lock set up after Android 9 May update, which introduced a new key derivation function.
- Mounts the system partition at /system_root as per AOSP standards. This makes the auto-backup scripts (e.g. GApps / Magisk survival script) work properly during updates, and you no longer need any 'patch' to flash GApps / Magisk properly. However, this may break some existing ROMs. See below FAQ section for details.
- Appended DTBO to the recovery image so it doesn't depend on the dtbo partition. No standalone DTBO image required.
Flashing instructions
- Download and extract the img file
- Reboot to fastboot mode
- fastboot flash recovery whatever_img_file_you_extracted.img
- Reboot and press Volume + to enter recovery
- DO NOT try to run 'fastboot boot recovery.img', it won't work.
- DO NOT flash the fcrypt disabler if you use my recovery. There is no need to do so, and it is possible to mess stuff up if you don't know what you are doing.
- You have to format the data partition if and ONLY IF:
1) You were not encrypted, now going to an encrypted state, or vice-versa OR
2) You were on a ROM other than MIUI that does not support "wrappedkey" (ROMs would often state it supports wrappedkey if it does), now going to a ROM that supports it
Limitations
DO NOT boot this recovery with empty system and vendor partitions. It will fail to decrypt any data partition with empty /system and /vendor. DO NOT wipe system and vendor partitions without installing a new one before rebooting. I am working to remove this limitation.
Now works even with empty system and vendor partitions after 3.3.1-5. No need to worry about formatting system and vendor breaking TWRP any more.
The restore zip created by the Migrate app is NOT compatible with this recovery. It's a problem of the Migrate app, not this recovery. Please DO NOT try to flash the restore zip created by Migrate.
FAQ
- Q: Do I need any specific DTBO image to make this recovery working?
- A: Nope. It is appended to the recovery image so it will work with any DTBO.
- Q: What is wrappedkey?
- A: It's a different mode of FBE implemented in CAF, the Qualcomm branch of AOSP.
- Q: This cannot install ROM X, why?
- A: Because it mounts the system partition at /system_root, which is AOSP standard behavior for A-only system_as_root devices, but is broken in some custom ROMs currently (MIUI should work though). To make any ROM work again, they will need to include this commit from LineageOS Gerrit https://review.lineageos.org/c/LineageOS/android_build/+/247066
- Q: Decryption doesn't work with ROM X, why?
- A: Decryption should work for most ROMs based on the CAF branch (not AOSP). CAF ROMs (including official MIUI) use a different scheme for key storage, which is why TWRP hasn't supported it till now. I have ported the CAF encryption changes (wrappedkey) to TWRP, but unfortunately this will break ROMs that do not support the CAF wrappedkey mode of encryption. Here is a list of patches non-CAF ROMs need to support CAF-encrypted /data partitions https://mokeedev.review/q/topic:%22fbe-wrapped-key%22+(statuspen%20OR%20status:merged). If you confirm your ROM is CAF-based but the decryption still does not work, please open an issue on my GitHub repository which you could find below. (XDA threads are no good for issue tracking, sorry)
- Q: Why not contribute to the official TWRP?
- A: All the patches to the TWRP code base have been submitted to the official gerrit code review, though not merged yet, which you can see below.
Downloads
3.3.1-6: https://mega.nz/#!3QIRQYhK!Jq5QrGfJw5VCYZ8sq_BO1qNZecrFqlM9IB1IdSwogvI
changes: updated kernel to support pstore instead of /proc/last_kmsg. If you don't know what this is, it's probably not relevant to you.
Here you can find an unofficial LOS build with wrappedkey encryption and also proper system_as_root support for those survival scripts https://forum.xda-developers.com/redmi-note-7-pro/development/unofficial-lineageos-16-caf-encryption-t3933532. In addition, all official MIUI builds should flash just fine.
History versions:
3.3.1-5: https://mega.nz/#!nMowHKiL!zRvoTM0iIZKArmUDnZzaEFtXQv0_q7hIHUCmTHTOmOM
changes: 1) Now works even with empty /system and /vendor partition 2) Fixed brightness problem; 3) Enabled EDL Reboot
3.3.1-3: https://mega.nz/#!yAYXxAzZ!FNMYLzLphnSmJ-DbBx-OZUgxxYiftgn8e4Jn3kxiQik
Patches and sources
Patches for TWRP are available here:
https://gerrit.omnirom.org/#/c/34091/
https://gerrit.omnirom.org/#/c/34093/
https://gerrit.omnirom.org/#/c/34092/
https://gerrit.omnirom.org/#/c/android_bootable_recovery/+/34096/
Patches for ROMs to support wrapped key have been given in the above sections.
Source of the current device tree for TWRP: https://github.com/PeterCxy/android_device_xiaomi_violet-twrp
Kernel source: https://github.com/PeterCxy/android_kernel_xiaomi_sm6150, note that the device tree uses a prebuilt kernel image.
Contributors
PeterCxy, Dyneteve, merothh
Source Code: https://github.com/PeterCxy/android_device_xiaomi_violet-twrp
Now fixed and tested with MIUI.
PeterCxy said:
Now fixed and tested with MIUI.
Click to expand...
Click to collapse
Could you please tell us what is fixed and what is wrong with the previous one? Just out of curiosity.
I’m not new to installing custom recoveries and installing ROM, but I am new to Xiaomi devices.
In the simplest form possible,
With this I should be able to just run the ‘fastboot install recovery twrp.img’ and not have to run “fastboot erase userdata’?
also
Do I still need to flash the zip I have that disables forced encryption?
Could you provide instructions to flash this ?
Or is it just the same as the 'official one'?
Can confirm this successfully decrypts storage, running xiaomi.eu on my phone. Thanks for your work.
Dwughjsd said:
Could you please tell us what is fixed and what is wrong with the previous one? Just out of curiosity.
Click to expand...
Click to collapse
It did not decrypt MIUI 10.3.5.0 successfully due to magic (I missed some commits from qcom). It was fixed by pulling more commits in.
Jpwner said:
I’m not new to installing custom recoveries and installing ROM, but I am new to Xiaomi devices.
In the simplest form possible,
With this I should be able to just run the ‘fastboot install recovery twrp.img’ and not have to run “fastboot erase userdata’?
also
Do I still need to flash the zip I have that disables forced encryption?
Click to expand...
Click to collapse
You won't need to erase userdata or flash fcrypt disabler anymore, if all the ROMs will update to support the wrappedkey encryption
Naveenthemi said:
Could you provide instructions to flash this ?
Or is it just the same as the 'official one'?
Click to expand...
Click to collapse
just fastboot flash recovery whatever_you_downloaded_and_extracted.img
PeterCxy said:
just fastboot flash recovery whatever_you_downloaded_and_extracted.img
Click to expand...
Click to collapse
So it's possible for me to flash OTA Updates without encountering a bootloop and such?
Can someone please provide an alternate download link? The Mega link doesn't seem to work for me.
EDIT: Worked on a different device. Thanks.
Naveenthemi said:
So it's possible for me to flash OTA Updates without encountering a bootloop and such?
Click to expand...
Click to collapse
+1
Please answer
Good job! ?
I want you to know that your patch has been merged with the official one. I was away for a while so I hope you understand the little unfortunate delay.
In latest update can we flash any custom roms without any issue?
Yogendra Kher said:
In latest update can we flash any custom roms without any issue?
Click to expand...
Click to collapse
You have to wait until custom ROMs pull in necessary system_as_root changes. Currently it seems only my LOS build pulled that in
PeterCxy said:
You have to wait until custom ROMs pull in necessary system_as_root changes. Currently it seems only my LOS build pulled that in
Click to expand...
Click to collapse
Is it possible to flash OTA updates without encountering bootloops and such? (MIUI)
Naveenthemi said:
Is it possible to flash OTA updates without encountering bootloops and such? (MIUI)
Click to expand...
Click to collapse
Should work fine with MIUI. At least from what I have tested.
kushal.purkar said:
+1
Please answer
Click to expand...
Click to collapse
PeterCxy said it would as far as his testing had been done.
Gapps aroma not installing in this one as well. error 255
Can I flash Magisk and root my phone with this build.?
Do you have any Magisk zip file that will work.?
Thank you for your work

[UNOFFICIAL][wrappedkey] LineageOS 16 with CAF encryption support

Introduction
This is an unofficial build of LineageOS 16 for Redmi Note 7 Pro. Differences from the one provided by Dyneteve include:
- Ported the CAF wrappedkey encryption stuff, which is what MIUI uses, over using patches from https://mokeedev.review/q/topic:%22fbe-wrapped-key%22+(statuspen%20OR%20status:merged), This requires an recovery with wrappedkey decryption support, e.g. this one
- Applied unmerged patch https://review.lineageos.org/c/LineageOS/android_build/+/247066 to mount system as /system_root properly on install. This makes addon.d scripts (e.g. Magisk / GApps survival script) work again on our device. This requires an recovery with proper system_as_root support, e.g. this one
- ROM includes its own vendor image instead of relying on one provided by MIUI. I intend to try to build as much of vendor image as possible from CAF source in the future.
Flash instructions
- Make sure you have the latest firmware images. If not, update them before flashing.
- Flash a TWRP recovery that supports mounting system as /system_root and supports wrappedkey encryption (the one provided above)
- Wipe data partition (without wiping /data/media). If you came from another non-CAF ROM (ROM that do not support wrappedkey mode) and had encryption enabled, you will need to format your data partition (including /data/media).
Note: If you decide to format your data partition, always format with 'advanced wipe' in TWRP recovery. DO NOT use fastboot -w or fastboot erase, even if you do, please format again in recovery, otherwise the system might not work.
- Install the zip in TWRP.
- Install whatever you want e.g. Magisk, OpenGapps
- DO NOT install the fcrypt disabler.
- Reboot and enjoy
Known issues
DO NOT remove screen lock passwords if you set one. You can change the password just fine, but DO NOT REMOVE IT. YOU WILL LOSE ACCESS TO ALL DATA IF YOU DO THIS AND REBOOT.
Removing screen lock passwords work after 20190528-1.
Downloads
20190609-1: https://mega.nz/#!PdRnxIia!Boh-a8e5JHt8YEBwbXKt8rWYj3PC56mdpEIXwDEY2ng
changelog: 1) Merged upstream LineageOS (June security patch) 2) Updated kernel to 4.14.123 3) Updated MIUI binary blobs 4) Some clean-up
NOTE: /proc/last_kmsg support is removed due to incompatibility. This feature is replaced by pstore, which you could find more information on through some Google-fu.
History versions:
20190528-1: https://mega.nz/#!nZRTQCbS!qf-RdT-ijayg8UBxyyz3Hoi2O_8ZtpWewgNv-eVDcqA
changelog: 1) merged upstream LineageOS; 2) fixed the bug of removing screen lock passwords, now it won't swallow all your data (this commit: https://github.com/PeterCxy/android...mmit/d2fe3434cddb98eeb414906e71a817559ade1b26; 3) merged LTS kernel 4.14.122, thanks to YaroST and aviraxp; 4) fixed potential charging problem; 5) some other kernel improvements
20190526-1: https://mega.nz/#!rRgwmY5T!2fQyDjukLoGmk7KRtas5n2Y_it9QS_s2noAItzNvFfY
Sources
Device: https://github.com/PeterCxy/android_device_xiaomi_violet
Kernel: https://github.com/PeterCxy/android_kernel_xiaomi_sm6150
Other changes and patches: see what is available on my GitHub https://github.com/PeterCxy/, everything is open-source for this ROM.
Contributors
PeterCxy, GuaiYiHu, aviraxp
Source Code: https://github.com/PeterCxy/android_device_xiaomi_violet
Thanks ?
Thank you for the ROM!
There's a Typo in the ROM os version description.
cant boot. installed as mentioned in instruction. its automatically rebooting to recovery (twrp, the given one). now whenever i try to flash other rrecovery its not booting into. stuck. please help.
jyoti.id said:
cant boot. installed as mentioned in instruction. its automatically rebooting to recovery (twrp, the given one). now whenever i try to flash other rrecovery its not booting into. stuck. please help.
Click to expand...
Click to collapse
If you can't boot to recovery at all you may need to flash a fastboot ROM of MIUI (of course in fastboot mode) and try to install twrp again.
jyoti.id said:
cant boot. installed as mentioned in instruction. its automatically rebooting to recovery (twrp, the given one). now whenever i try to flash other rrecovery its not booting into. stuck. please help.
Click to expand...
Click to collapse
Sorry I have no idea here.. What ROM you were on before flashing this?
Dwughjsd said:
If you can't boot to recovery at all you may need to flash a fastboot ROM of MIUI (of course in fastboot mode) and try to install twrp again.
Click to expand...
Click to collapse
iv flashed the stock rom, but now the internal storage is showing only 16GB of storage.
Edit: fixed everything. Thank you. I was curious about the battery backup of this ROM badly, so I just rushed in things so maybe I made some mistakes.
jyoti.id said:
iv flashed the stock rom, but now the internal storage is showing only 16GB of storage.
Edit: fixed everything. Thank you. I was curious about the battery backup of this ROM badly, so I just rushed in things so maybe I made some mistakes.
Click to expand...
Click to collapse
Just keep in mind that safety first
Download link not working
Edit: UC browser was the culprit
dwughjsd said:
just keep in mind that safety first
Click to expand...
Click to collapse
how u fixed storage issue
gsunil said:
how u fixed storage issue
Click to expand...
Click to collapse
It was @jyoti.id that faced and solved the issue, so let's call him for an answer
rom keeps rebooting into twrp , i did every step
gsunil said:
how u fixed storage issue
Click to expand...
Click to collapse
I just flashed the whole fastboot rom again & it fixed everything.
---------- Post added at 04:34 AM ---------- Previous post was at 04:33 AM ----------
King_Dinoco10 said:
rom keeps rebooting into twrp , i did every step
Click to expand...
Click to collapse
Same thing happened with me too
Device not charging above 86%. Anyone else facing this bug ?
PeterCxy said:
Sorry I have no idea here.. What ROM you were on before flashing this?
Click to expand...
Click to collapse
The phone does not charge more than 91%!
lapo_chel said:
The phone does not charge more than 91%!
Click to expand...
Click to collapse
now should be fixed, try today's new build
PeterCxy said:
now should be fixed, try today's new build
Click to expand...
Click to collapse
Safetynet does not pass.
lapo_chel said:
Safetynet does not pass.
Click to expand...
Click to collapse
It's because I used vendor files from MIUI beta. You can bypass it with a magisk module to reset the build fingerprint
Many thanks for your build! I like it much.
IMHO, SELinux should be enabled.

[HOW-TO] Flash A/B Treble GSI ROMs without TWRP

Android devices can have different designs, so there is no generic command or set of instructions for flashing a GSI to apply to all devices. Specially for Xperias am i writing this Guides for You. So please read carefully...
1. Ensure that You have the following before You start:
Latest Fastboot Version (Or the used fastboot commands may not work)
A Method for disabling Android Verified Boot (Part of the Guide)
An unlocked Bootloader State (Official Instructions HERE)
To Start:
Download the Basic Package from Google: https://developer.android.com/topic/generic-system-image/releases
Download the AOSP Vendor Package from Sony: https://developer.sony.com/develop/open-devices/downloads/software-binaries
Open up the Zip Files and place the 3 included Images on Your fastboot destination
Boot Your Device into Fastboot:
Code:
Turn off Your Device and hold VolumeUP while connecting via USB to a PC or use ADB to reboot to fastboot
Disable the verified booting (AVB) by flashing vbmeta.img:
Code:
fastboot --disable-verification flash vbmeta vbmeta.img
Flash the Vendor to the Primary A Slot OEM:
Code:
fastboot flash oem_a nameofthesonyoemimage.img
Repeat to flash to the B Slot OEM
Code:
fastboot flash oem_b nameofthesonyoemimage.img
Flash the GSI to the Primary A Slot System:
Code:
fastboot flash system_a system.img
Repeat to flash to the B Slot System
Code:
fastboot flash system_b system.img
Wipe the user data and clear the data from other necessary partitions (for example, user data and system partitions):
Code:
fastboot -w
Reboot:
Code:
fastboot reboot
Additional:
You can use any Android 9+ GSI out of the XDA Forum here: https://forum.xda-developers.com/project-treble/trebleenabled-device-development
To get Magisk/Root; just patch Your actual Kernel with the Magisk Manager App and flash the Boot Image together with the GSI (Example below)
Patched Boot Image for Xperia 5 Users: https://forum.xda-developers.com/xp...isk-v20-3-patched-boot-image-android-t4033547
I'll add that the Basic Package directly from Google in OP's post does not have functional call audio.
I highly recommend anyone try out Lineage 17: https://forum.xda-developers.com/pr...lopment/gsi-lineageos-17-0-gsi-archs-t4004673. Call audio works. FP sensor works. Camera also seems to work but I didn't really test it. I recommend flashing OP's patched boot image, too. Then all you have to do is install the Magisk Manager apk.
None of ExpressLuke's builds boot. Evolution hangs at the Evolution boot screen.
What we're missing now is TWRP. Lineage doesn't have gapps pre-installed, so we need a method for flashing them. I couldn't get MicroG services to work--apps could not see the accounts.
thatguy222 said:
I'll add that the Basic Package directly from Google in OP's post does not have functional call audio.
I highly recommend anyone try out Lineage 17: https://forum.xda-developers.com/pr...lopment/gsi-lineageos-17-0-gsi-archs-t4004673. Call audio works. FP sensor works. Camera also seems to work but I didn't really test it. I recommend flashing OP's patched boot image, too. Then all you have to do is install the Magisk Manager apk.
None of ExpressLuke's builds boot. Evolution hangs at the Evolution boot screen.
What we're missing now is TWRP. Lineage doesn't have gapps pre-installed, so we need a method for flashing them. I couldn't get MicroG services to work--apps could not see the accounts.
Click to expand...
Click to collapse
Call Bug confirmed but i had personally no Issue with the ExpressLukes Build. Just make Sure You don't use A64 Builds but ARM64 Builds (AB). Only GSIs with GApps was Havoc and Pixel Experience i think...
I'm running PE without issues Here (vbmeta from Google)
Can you elaborate on the vbmeta from Google comment?
And yes, only took one attempted flash with an A64 build to realize I needed ARM64 AB
thatguy222 said:
Can you elaborate on the vbmeta from Google comment?
And yes, only took one attempted flash with an A64 build to realize I needed ARM64 AB
Click to expand...
Click to collapse
Code:
fastboot --disable-verification flash vbmeta vbmeta.img
That needs to be done with the vbmeta image from the Google Basic package together with the flash of the System/Kernel and fastboot -w to be able to boot Up some ROMs. That needs to be done after each Stock Firmware flash...
In other words. It's a vbmeta image with disabled verify boot Checks that works on modern Treble Device Like the Xperia 1 & 5
Don't know btw what A64 is ... lol
Miustone said:
Code:
fastboot --disable-verification flash vbmeta vbmeta.img
That needs to be done with the vbmeta image from the Google Basic package together with the flash of the System/Kernel and fastboot -w to be able to boot Up some ROMs. That needs to be done after each Stock Firmware flash...
In other words. It's a vbmeta image with disabled verify boot Checks that works on modern Treble Device Like the Xperia 1 & 5
Don't know btw what A64 is ... lol
Click to expand...
Click to collapse
Still hanging at the boot up screen for both Evolution and Havoc. Following your directions exactly. I must be doing something wrong.
thatguy222 said:
Still hanging at the boot up screen for both Evolution and Havoc. Following your directions exactly. I must be doing something wrong.
Click to expand...
Click to collapse
Have You tried Pixel Expierence? If that doesn't works must be something wrong :fingers-crossed:
PixelExperience does boot successfully. Wonder why Havoc and Evolution didn't...
Is anyone able to get IMS working? I can't get VoLTE to enable (on any non-stock ROM) and checking the short codes menu confirms IMS is unavailable. Re-flashed stock and it provisioning correctly.
Thanks a ton for this guide. I have the Xperia 1 and am about to go unlocked. Too much google in my life. I am assuming all this stuff is basically the same. I've been around more than my share of unlocking / rooting experiences, so I am not sweating it too much.
Updated the Thread. No need for the vbmeta Image with Havoc 3.5 (Official GSI with GApps)! Means a more secure Device somehow...
I did an Overlay for GSIs, based on our latest Android 10 Framework https://github.com/phhusson/vendor_hardware_overlay/pull/214
Possible that You can grab it here: https://forum.xda-developers.com/showpost.php?p=82550641&postcount=889
Rename to FrameworkResCommon.apk and push it to /vendor/overlay (Replace). Should work in Theory... Maybe. It's a first try and i don't know how it will be implented
Updated the Thread with some Changes
Thread updated again with My latest findings. The OEM Vendor from SONY has to be flashed to A/B to. Added that Steps! Enjoy
Talented developer here, nice work. Been a while since Sony devices have had this level of support. My messing around days are behind me but it's nice to see as an old XDA fan.
augie7107 said:
Talented developer here, nice work. Been a while since Sony devices have had this level of support. My messing around days are behind me but it's nice to see as an old XDA fan.
Click to expand...
Click to collapse
Feeling honored to hear this! I was always a Friend of Xperia Devices and was User of NUTs Dual Recoveries, FXP and Doomkernels and started making/publishing own ROMs with the Xperia T back in the Days. It's really sad, seeing all the Telegram Chat Groups around with no Structure and all the missing Development over here on XDA. A lot of stuff around Android has changed the last Years, but it's still fun to try and mess around with all the new stuff. I just wish i had a Team to grow up the Support...
Hope i can bring some Life onto the new Xperias in a new age of Android. Your Words really pushed Me up again :angel: Thank You! :highfive:
System_A && System_B?
Are system and vendor taking up double the amount of space on the drive by being installed for two paths?
&(*) said:
Are system and vendor taking up double the amount of space on the drive by being installed for two paths?
Click to expand...
Click to collapse
No. You have ROM storage and userspace storage on Your Device. Treble Android Devices have the Double amount of ROM Storage compared to non treble Devices. So it doesn't Matters If You only flash one Slot, Your user storage won't show more Space to use...
I understand the partitions are sized for two paths, which is the difference between an A only or A/B device (one system flag or two). Strange that the total space used wound't be displayed regardless of what the partitions are using. I was trying to gather the correct way to install a GSI rom and your instructions provided a new method for doing so. I guess I have to question whether the device I am installing on now is an A only or A/B device. Judging by the install size of 12gb for system which on other devices is roughly half, I am guessing it is an A/B device due to the space used.
Hi everyone, I just bought an Xperia 5, and being a little privacy concerned , I want to get rid of the Google parts of Android. After reading all the threads I found about this phone, and seeing that the Xperia 5 doesn’t have official support for LOS, I understand the most stable way to have a Google-free phones is by installing the GSI and then a Treble rom. I have the following doubts:
- Once I get everything installed following @Miustone 's guide, will I have to update the binaries every month? (I saw Sony posts vendor binaries every month on the Open Devices Website)
- If I install PHH’s treble Rom, will all the hardware work correctly (one message in this thread mentioned call volume problem)? What about the camera button?

How To Guide Install any custom ROM on ROG Phone 5 / 5s (GSI)

Install any GSI on your ROG Phone 5​​First of all I want to say that I am NOT responsible of anything you do to your device.​
What is a GSI?
A generic system image (GSI) is a system image with adjusted configurations for Android devices. It's considered a pure Android implementation with unmodified Android Open Source Project (AOSP) code that any Android device running Android 8.1 or higher can run successfully.
GSIs are used for running VTS and CTS-on-GSI tests. The system image of an Android device is replaced with a GSI then tested with the Vendor Test Suite (VTS) and the Compatibility Test Suite (CTS) to ensure that the device implements vendor interfaces correctly with the latest version of Android.
What GSI do I install?
There are multiple GSI you can choose (AOSP, LineageOS, Pixel Experience, ProtonAOSP, etc).
Here is a list of every GSI you can install: Generic System Image (GSI) list
For ROG Phone 5, you need to choose a A/B partition style and arm64 architecture GSI.
How do I install a GSI?
First of all, make a backup of your device (optional):
In the Settings app: "Settings > System > Backup > Backup now" or "Settings > System > Local backup"
In TWRP (TWRP for ROG Phone 5/5s): "Backup > select Data and Super > Swipe to backup"
And unlock the phone using the app in the official site: AsusUnlock_1.0.0.7_210127_fulldpi.apk
Factory reset your phone in recovery or Android
Now, reboot your phone into fastboot mode (shutdown then press Volume up + Power)
Connect the phone to the PC with the side port of the phone
Make sure you have ADB and Fastboot installed, if not install this: Minimal ADB and Fastboot or this: Android SDK Platform Tools latest
Download the vbmeta and extract it: vbmeta.img
Now flash everything:
In a command prompt, type the following commands:
fastboot reboot fastboot
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot erase system
fastboot -w flash system yourgsi.img
Replace yourgsi.img with the GSI you want to install
Now reboot your phone:
fastboot reboot
And that's it! You successfully installed a GSI on your ROG Phone 5!​
Common problems:​
Not enough space to resize system partition?​
If when you try to flash the GSI you get this error:
Resizing 'system' FAILED (remote: 'Not enough space to resize partition')
Then that means that your GSI is too big.
But don't worry, there is a solution!
Just type this before flashing the GSI:
fastboot delete-logical-partition product
This will delete the product partition and let enough space for the GSI.
Including Android 12 gsi? Has anybody tried this on this phone?
chairman011 said:
Including Android 12 gsi? Has anybody tried this on this phone?
Click to expand...
Click to collapse
Hi,
I installed a Android 12 GSI on my device and it worked. I recommend you Pixel Experience (choose arm64-ab-vndklite I recommend)
Alex2008Ex said:
Hi,
I installed a Android 12 GSI on my device and it worked. I recommend you Pixel Experience (choose arm64-ab-vndklite I recommend)
Click to expand...
Click to collapse
Any known bugs / issues you've noticed so far ?
JazonX said:
Any known bugs / issues you've noticed so far ?
Click to expand...
Click to collapse
Yes, on every GSI, the integrated phone speaker (for calls) doesn’t work. I didn’t noticed any other issues for the moment (not anymore with A12)
For the moment, only the fingerprint scanner, ROG specific features and secondary cameras are not working
Alex2008Ex said:
Yes, on every GSI, the integrated phone speaker (for calls) doesn’t work. I didn’t noticed any other issues for the moment
Click to expand...
Click to collapse
Ouch, So permanently on headsets ?
Sorry noob question
If I flash pixel experience android 11, armoury crate or dirac service still exist?
JazonX said:
Ouch, So permanently on headsets ?
Click to expand...
Click to collapse
I don’t know if we can use jack or Bluetooth headsets for calls but it doesn’t work directly on the phone.
Maybe it is possible to modify the /vendor partition to repair the problem(s)
Devaanp said:
Sorry noob question
If I flash pixel experience android 11, armoury crate or dirac service still exist?
Click to expand...
Click to collapse
No. This is a clean Android with Google pixel interface so Asus or ROG services are not installed by default like for example RGB on the back doesn’t work (I don’t know if it is possible to install them)
Alex2008Ex said:
No. This is a clean Android with Google pixel interface so Asus or ROG services are not installed by default like for example RGB on the back doesn’t work (I don’t know if it is possible to install them)
Click to expand...
Click to collapse
I'll think twice before flashing then, since RGB and dirac service doesn't work
Armoury crate can replace with kernel manager, but idk about RGB control apps
Alex2008Ex said:
Hi,
I installed a Android 12 GSI on my device and it worked. I recommend you Pixel Experience (choose arm64-ab-vndklite I recommend)
Click to expand...
Click to collapse
Awesome thank you I'm going to give it a shot do you have root working or are you just testing it out I think I'll test it out for a few days thank you for the response and the recommendation.
Forgot to ask, how to get back to ROG rom again? after flashing GSI?
Devaanp said:
Forgot to ask, how to get back to ROG rom again? after flashing GSI?
Click to expand...
Click to collapse
You can flash a RAW Rom in Fastboot to revert to stock anytime.
JazonX said:
You can flash a RAW Rom in Fastboot to revert to stock anytime.
Click to expand...
Click to collapse
Okay thanks, I'll try
chairman011 said:
Awesome thank you I'm going to give it a shot do you have root working or are you just testing it out I think I'll test it out for a few days thank you for the response and the recommendation.
Click to expand...
Click to collapse
Hi, you can use Magisk it works. Flash the apk in twrp it is the easiest (flash the apk after flashing system and before rebooting to system because encryption doesn't work) or use boot.img method.
Hey, good job on the tutorial but I was wondering whether you found a way to activate haptics and/or the audio jack
vinotux said:
Hey, good job on the tutorial but I was wondering whether you found a way to activate haptics and/or the audio jack
Click to expand...
Click to collapse
Hey, you can maybe copy the files from the vendor of the official firmware on the GSI but I don’t know what files and if it works.
Can I install android 10 or 9 on my Asus ROG phone 5?
HunterTik said:
Can I install android 10 or 9 on my Asus ROG phone 5?
Click to expand...
Click to collapse
Yes I think.
Alex2008Ex said:
Install any GSI on your ROG Phone 5​​First of all I want to say that I am NOT responsible of anything you do to your device.​
What is a GSI?
A generic system image (GSI) is a system image with adjusted configurations for Android devices. It's considered a pure Android implementation with unmodified Android Open Source Project (AOSP) code that any Android device running Android 8.1 or higher can run successfully.
GSIs are used for running VTS and CTS-on-GSI tests. The system image of an Android device is replaced with a GSI then tested with the Vendor Test Suite (VTS) and the Compatibility Test Suite (CTS) to ensure that the device implements vendor interfaces correctly with the latest version of Android.
What GSI do I install?
There are multiple GSI you can choose (AOSP, LineageOS, Pixel Experience, ProtonAOSP, etc).
Here is a list of every GSI you can install: Generic System Image (GSI) list
For ROG Phone 5, you need to choose a A/B partition style and arm64 architecture GSI.
How do I install a GSI?
First of all, make a backup of your device (optional):
In the Settings app: "Settings > System > Backup > Backup now" or "Settings > System > Local backup"
In TWRP (TWRP for ROG Phone 5/5s): "Backup > select Data and Super > Swipe to backup"
And unlock the phone using the app in the official site: AsusUnlock_1.0.0.7_210127_fulldpi.apk
Factory reset your phone in recovery or Android
Now, reboot your phone into fastboot mode (shutdown then press Volume up + Power)
Connect the phone to the PC with the side port of the phone
Make sure you have ADB and Fastboot installed, if not install this: Minimal ADB and Fastboot or this: Android SDK Platform Tools latest
Download the vbmeta and extract it: vbmeta.img
Now flash everything:
In a command prompt, type the following commands:
fastboot reboot fastboot
fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
fastboot erase system
fastboot -w flash system yourgsi.img
Replace yourgsi.img with the GSI you want to install
Now reboot your phone:
fastboot reboot
And that's it! You successfully installed a GSI on your ROG Phone 5!​
Click to expand...
Click to collapse
im sorry noob question, what about the peformance increases (longer batery life, less throttling when playing high end games, etc) when i installed the custom rom compare to stock rom on rog phone 5 8/128, is it noticable ?

Categories

Resources