FORUMS

Guide to Treble/GSI on the Palm Phone

140 posts
Thanks Meter: 10
 
By a.vandelay, Senior Member on 19th May 2020, 05:13 PM
Post Reply Email Thread
From this thread: https://forum.xda-developers.com/pro...reble-t3992559, the TrebleCheck app indicates we need an arm64 "a-only" ROM. The Palm Phone is running vendor version 8.1.

I had a hiccup installing Android 10, could have been a fluke or mistake on my end, so feel free to try. I was able to get the latest version of 8.1 from the above thread to work. Specifically, from here: https://github.com/phhusson/treble_e...leases/tag/v32, I chose the system-arm64-aonly-gapps-su.img.xz link.

Update: sergio_chichi has confirmed a 9.0 image working here: https://forum.xda-developers.com/sho...9&postcount=32

Step 1: Download Sugar. This thread: https://forum.xda-developers.com/and...phone-t4021201, has everything you need to know about Sugar. I ran the upgrade once to download the full stock ROM (make a backup as described). Warning, this erases all of your data.

Step 2: Follow this guide: https://forum.xda-developers.com/and...ource-t3843473, to build a TWRP for the Palm Phone without source. I used the latest TWRP for the Asus Nexus 7 2013 LTE as my base. From your Palm upgrade backup, the recovery image is the one that starts with 'R', about 36MB. Rename your new TWRP image to match the stock recovery and replace it similar to the rooting guide for replacing the boot image.

Update: snoopy20 has shared his TWRP image here: https://forum.xda-developers.com/sho...3&postcount=26

Step 3: Extract the system image you downloaded and rename and replace the stock system image. It's the largest file in your Sugar device folder.

Step 4: Re-run the upgrade in Sugar with your replaced images in place.

Step 5: You're probably stuck in a boot loop. Press and hold the power button until you get into recovery, which is now TWRP. First, I formatted data. Then push (NOT sideload, since the zip relies on its own name to configure the flash) this zip: https://forum.xda-developers.com/and...crypt-t3817389 and install it from TWRP. The stock configuration should be fine, i.e. don't worry about re-naming the zip.

Step 6: Reboot! Wipe data and cache for good measure, and you should be set!

All credit goes to the folks from the links above for creating the Treble system image, TWRP guide, and dm-verity script. Thanks to snoopy20 for his TWRP image.

Things that work so far:
* Almost everything

Doesn't work
* Soft key does nothing, should be mappable via an app?
* Screen auto brightness?
Attached Thumbnails
Click image for larger version

Name:	20200518_190828.jpg
Views:	226
Size:	246.9 KB
ID:	5022397   Click image for larger version

Name:	20200519_073432.jpg
Views:	222
Size:	176.3 KB
ID:	5022399  
The Following 2 Users Say Thank You to a.vandelay For This Useful Post: [ View ] Gift a.vandelay Ad-Free
20th May 2020, 04:04 PM |#2  
Senior Member
Thanks Meter: 36
 
More
Can you post the TWRP you created?
20th May 2020, 05:40 PM |#3  
OP Senior Member
Thanks Meter: 10
 
More
Quote:
Originally Posted by snoopy20

Can you post the TWRP you created?

Is it kosher to publicly post a TWRP created like this (i.e. not from source)?

Additionally, I'm not entirely confident I didn't screw something up, so I'm a little wary to risk everyone's device. Specifically, I do not know what would happen if you get caught in a boot loop and don't have a functioning recovery to boot into in order to restore...
20th May 2020, 07:04 PM |#4  
Senior Member
Thanks Meter: 36
 
More
Yeah you just write "Unofficial" or something in the title. Right now I'm happy to brick the Palm, I'm 99% of the way to dropping it but it would be fantastic if I can get a stock Android on it.

By the way do the restrictions, i.e wifi tethering, get applied by the Vendor package?
21st May 2020, 12:50 AM |#5  
OP Senior Member
Thanks Meter: 10
 
More
Quote:
Originally Posted by snoopy20

Yeah you just write "Unofficial" or something in the title. Right now I'm happy to brick the Palm, I'm 99% of the way to dropping it but it would be fantastic if I can get a stock Android on it.

By the way do the restrictions, i.e wifi tethering, get applied by the Vendor package?

Hard for me to test since I don't have a supported SIM, but the tethering menu is available in Settings. You'll have to try it and let us know.
21st May 2020, 07:24 AM |#6  
Senior Member
Thanks Meter: 36
 
More
If you post the TWRP I'll do so. My biggest concern is if I cock up building it. I sent you a PM.
21st May 2020, 02:05 PM |#7  
OP Senior Member
Thanks Meter: 10
 
More
Quote:
Originally Posted by snoopy20

If you post the TWRP I'll do so. My biggest concern is if I cock up building it. I sent you a PM.

Just waiting for android file host to approve
21st May 2020, 03:35 PM |#8  
Senior Member
Thanks Meter: 36
 
More
I've attempted to repack but found:

1. Two fstab files are fstab.qcom and fstab.grouper, don't know if I should delete them but instructions seem to indicate I should.
2. Stock ramdisk folder doesn't have a fstab.* file to copy over.

I ended up with this twrp.fstab. Note the encryption part from /data is gone? Unsure if this is ok.

# mount point fstype device

#twrp.fstab
/system ext4 /dev/block/bootdevice/by-name/system
/cache ext4 /dev/block/bootdevice/by-name/cache
/data ext4 /dev/block/bootdevice/by-name/userdata
/misc emmc /dev/block/bootdevice/by-name/misc
/boot emmc /dev/block/bootdevice/by-name/boot
/recovery emmc /dev/block/bootdevice/by-name/recovery
/external_sd vfat /dev/block/mmcblk1p1 flags=removable;storage;display="SDCARD"
/usb-otg auto /dev/block/sda1 flags=removable;storage;display="USB-OTG"
21st May 2020, 04:47 PM |#9  
OP Senior Member
Thanks Meter: 10
 
More
Just a big heads up, when trying to connect to the network today (Visible) I noticed that my IMEI was 0000.... I have never successfully connected the Palm phone and while the behavior now is consistent with my issues before, I can't say whether or not flashing the GSI as outlined here erased my IMEI.

Proceed with caution.
21st May 2020, 06:57 PM |#10  
Senior Member
Thanks Meter: 36
 
More
I'm not proceeding at all unless you post your twrp or verify the issues I've had creating it.

I read the IMEI is held on another partition, type 'efs'. I can't see Sugar killing it. More likely your fstab options aren't mounting it.

---------- Post added at 06:57 PM ---------- Previous post was at 06:33 PM ----------

Here is a list of all the mountpoints on a working phone. At a guess the IMEI is held in /firmware. Do you have this mounted?

rootfs on / type rootfs (ro,seclabel,size=1358776k,nr_inodes=339694)
tmpfs on /dev type tmpfs (rw,seclabel,nosuid,relatime,size=1439668k,nr_inod es=359917,mode=755)
devpts on /dev/pts type devpts (rw,seclabel,relatime,mode=600)
proc on /proc type proc (rw,relatime,gid=3009,hidepid=2)
sysfs on /sys type sysfs (rw,seclabel,relatime)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
/dev/block/mmcblk0p27 on /system type ext4 (ro,seclabel,relatime,discard,data=ordered)
/dev/block/mmcblk0p28 on /vendor type ext4 (ro,seclabel,relatime,discard,data=ordered)
none on /acct type cgroup (rw,relatime,cpuacct)
debugfs on /sys/kernel/debug type debugfs (rw,seclabel,relatime)
tmpfs on /mnt type tmpfs (rw,seclabel,relatime,size=1439668k,nr_inodes=3599 17,mode=755,gid=1000)
none on /config type configfs (rw,relatime)
none on /dev/cpuctl type cgroup (rw,relatime,cpu)
pstore on /sys/fs/pstore type pstore (rw,seclabel,relatime)
/dev/block/mmcblk0p52 on /fotadata type ext4 (rw,seclabel,nosuid,nodev,noatime,discard,noauto_d a_alloc,data=ordered)
/dev/block/mmcblk0p29 on /cache type ext4 (rw,seclabel,nosuid,nodev,noatime,data=ordered)
/dev/block/mmcblk0p12 on /dsp type ext4 (ro,seclabel,nosuid,nodev,relatime,data=ordered)
/dev/block/mmcblk0p1 on /firmware type vfat (ro,context=ubject_r:firmware_file:s0,relatime,u id=1000,gid=1000,fmask=0337,dmask=0227,codepage=43 7,iocharset=iso8859-1,shortname=lower,errors=remount-ro)
/dev/block/mmcblk0p30 on /persist type ext4 (rw,seclabel,nosuid,nodev,noatime,data=ordered)
tmpfs on /storage type tmpfs (rw,seclabel,relatime,size=1439668k,nr_inodes=3599 17,mode=755,gid=1000)
tracefs on /sys/kernel/debug/tracing type tracefs (rw,seclabel,relatime)
tmpfs on /sbin type tmpfs (rw,seclabel,relatime,size=1439668k,nr_inodes=3599 17,mode=755)
/sbin/.magisk/block/persist on /sbin/.magisk/mirror/persist type ext4 (rw,seclabel,relatime,data=ordered)
adb on /dev/usb-ffs/adb type functionfs (rw,relatime)
/dev/block/dm-0 on /data type ext4 (rw,seclabel,nosuid,nodev,noatime,discard,noauto_d a_alloc,resuid=10010,data=ordered)
/sbin/.magisk/block/system on /sbin/.magisk/mirror/system type ext4 (ro,seclabel,relatime,discard,data=ordered)
/sbin/.magisk/block/vendor on /sbin/.magisk/mirror/vendor type ext4 (ro,seclabel,relatime,discard,data=ordered)
/sbin/.magisk/block/data on /sbin/.magisk/mirror/data type ext4 (rw,seclabel,relatime,discard,noauto_da_alloc,resu id=10010,data=ordered)
/data/media on /mnt/runtime/default/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1 023,gid=1015,multiuser,mask=6,derive_gid)
/data/media on /storage/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1 023,gid=1015,multiuser,mask=6,derive_gid)
/data/media on /mnt/runtime/read/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1 023,gid=9997,multiuser,mask=23,derive_gid)
/data/media on /mnt/runtime/write/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1 023,gid=9997,multiuser,mask=7,derive_gid)

The original firmware recovery has the /firmware mounted as the sdcard so depending on how you mounted for twrp could you have wiped it?

/dev/block/bootdevice/by-name/system /system ext4 ro,barrier=1 wait,verify
/dev/block/bootdevice/by-name/cache /cache ext4 noatime,nosuid,nodev,barrier=1,data=ordered wait,check
/dev/block/bootdevice/by-name/fotadata /fotadata ext4 noatime,nosuid,nodev,barrier=1,data=ordered wait,check
/dev/block/bootdevice/by-name/vendor /vendor ext4 ro,barrier=1 wait,verify
/dev/block/bootdevice/by-name/userdata /data ext4 noatime,nosuid,nodev,barrier=1,data=ordered,noauto _da_alloc wait,check
/dev/block/mmcblk0p1 /sdcard vfat nosuid,nodev wait
/dev/block/bootdevice/by-name/boot /boot emmc defaults defaults
/dev/block/bootdevice/by-name/recovery /recovery emmc defaults defaults
/dev/block/bootdevice/by-name/misc /misc emmc defaults defaults
/dev/block/bootdevice/by-name/fsg /fsg emmc defaults defaults
22nd May 2020, 04:06 PM |#11  
OP Senior Member
Thanks Meter: 10
 
More
Added my TWRP to the OP
Post Reply Subscribe to Thread

Tags
palm-palm

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

Advanced Search
Display Modes