FORUMS
Remove All Ads from XDA

[Discussion & Guide] OnePlus 5/5T now have unofficial Project Treble by MoKee

98 posts
Thanks Meter: 312
 
Post Reply Email Thread
(My English isn't very practice. If you have any question reading this post, please feel free to ask. I'll try my best to express.)

## 0. Update: 2018/04/16

Some information I got today:

1. OnePlus is doing a repartition in OP5 Open Beta 8 / OP5T Open Beta 6 (or earlier, who knows). It'll split the 1.5GB "last_parti" partition into a 1.0GB "vendor" and a ~500MB "reserve3" partition while booting the system.
2. Yes, the repartition process was done in system, not during OTA in recovery.
3. The official vendor partition is still unused (not formatted). OnePlus will fill it in a future OTA, said their engineer.
4. I think it won't be conflicted with our "homemade" unofficial Treble. I just tested that the stock H2OS/OxygenOS can run on our homemade partition table.
5. It's very easy to undo the unofficial treble. I'll make an undo flashable zip later (through it's unnecessary in this time).
6. Of course, MoKee now (since 20180417) can run on the official partition table too.

==========

The MoKee ROM is now shipping unofficial Treble update for OnePlus 5/5T since 20180411. As the maintainer, I would like to share some information here.

## 1. How is this possible for OP5/5T?

Project Treble requires 2 keys: a standalone /vendor partition, and fully binderized HALs.

In fact, OnePlus have a 1.4GB unused, unformatted partition "sdf6" on OnePlus 3, 3T, 5 and 5T. This partition was possibly left by the ODM company, OPPO. OPPO R11/R11s series have a simular partition layout with OnePlus, and OPPO really did release an OTA update to enable Project Treble for their products.

The other key is binerized HALs. More specifically, the Camera HAL. The good news is, OnePlus recently released OP5 Open Beta 6 and OP5T Open Beta 4, with all fully binerized HALs, including the Camera HAL.

So as these 2 majar problems were solved. Project Treble is possible.

## 2. How did this come true?

To make Project Treble come true for OnePlus 5/5T, these should be done:

1. All vender-specific blobs should be moved to /vendor
2. Some blobs load config files from /system/etc. Just hex-edit them to load from /vendor/etc instead
3. Label and format that unused sdf6 partition as /vendor - this should be automatically done with an OTA script
4. The kernel should mount sdf6 as /vendor as well

## For users - How to enable Treble for OP5/5T?

The most easy way now is, flash the latest MoKee MK81.0 nightly build with latest TWRP (OP5: http://rom.mk/?device=cheeseburger, OP5T: http://rom.mk/?device=dumpling). The updater script will do the job automatically for you.

It's possible to make a flashable zip contains only the kernel and vendor image, without the MoKee system. But I'm busying on some other features. I'll do it later.

Tested fully works with Phh-treble system image, including:

- Audio
- Camera
- Phone & data
- Bluetooth & Wi-Fi
- Fingerprint

## For developers - How to ship Treblize update with my ROM?

(I'm organizing the patch list, I'll updte this section later)

## Can I flash non-Treble ROMs? How to "undo" this change?

You don't need to undo it, I think. For those non-Treble ROMs, including H2OS and OxygenOS, the /vendor partition is invisible. So you can flash back to any other ROMs at any time you want.
Attached Thumbnails
Click image for larger version

Name:	4b263fe4gy1fq5jjpxarmj20u01o0wi2.jpg
Views:	6886
Size:	155.8 KB
ID:	4473410   Click image for larger version

Name:	4b263fe4gy1fq5jjqyg63j20u01o0jzz.jpg
Views:	6860
Size:	179.6 KB
ID:	4473411  
The Following 86 Users Say Thank You to chenxingyu For This Useful Post: [ View ] Gift chenxingyu Ad-Free
 
 
11th April 2018, 04:53 PM |#2  
Junior Member
Thanks Meter: 1
 
More
This is good news for us, thank you for your hard working!
11th April 2018, 06:33 PM |#3  
Skeptico's Avatar
Senior Member
Thanks Meter: 267
 
More
So, once we flash the Mokee ROM, will we then be able to flash the other treble ROMs like RR and Lineage?
11th April 2018, 06:59 PM |#4  
chenxingyu's Avatar
OP Member
Flag Canton, China
Thanks Meter: 312
 
More
Quote:
Originally Posted by Skeptico

So, once we flash the Mokee ROM, will we then be able to flash the other treble ROMs like RR and Lineage?

Of course.
The Following 4 Users Say Thank You to chenxingyu For This Useful Post: [ View ] Gift chenxingyu Ad-Free
11th April 2018, 07:14 PM |#5  
Member
Thanks Meter: 13
 
More
Great job!
11th April 2018, 07:58 PM |#6  
Senior Member
Thanks Meter: 35
 
More
Any specific instructions to install this or like a normal install ???
11th April 2018, 09:02 PM |#7  
more_than_hater's Avatar
Senior Member
Flag Odessa
Thanks Meter: 53
 
More
Quote:
Originally Posted by Amanpreetsingh

Any specific instructions to install this or like a normal install ???

Please, read OP message fully
The Following User Says Thank You to more_than_hater For This Useful Post: [ View ] Gift more_than_hater Ad-Free
11th April 2018, 10:45 PM |#8  
Junior Member
Flag Salerno
Thanks Meter: 4
 
More
you are awesome, big thank you from every OP5/5t owner
12th April 2018, 01:32 AM |#9  
Senior Member
Flag danang
Thanks Meter: 58
 
More
Damn, Oppo enabled Treble but 1+ didn't
What a shame...
The Following 5 Users Say Thank You to nguyenlucky For This Useful Post: [ View ] Gift nguyenlucky Ad-Free
12th April 2018, 02:12 AM |#10  
Senior Member
Thanks Meter: 34
 
More
Does this mean that the camera quality will be as good as stock on a custom room?
The Following User Says Thank You to dsjd For This Useful Post: [ View ] Gift dsjd Ad-Free
12th April 2018, 05:39 AM |#11  
Senior Member
Thanks Meter: 153
 
More
@chenxingyu If we flash Oxygen OS again on the treblized 5/5T, won't it again repartion the device again and create the sdf6 partition again? Just a doubt.
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes