[Android Q&A, Help & Troubleshooting] tetrig:
Umidigi S5 pro partition layout, flashing custom rom

Hi. It would be cool to have some custom rom in it. It's really great hardware (except kind of ****ty fingerprint sensor). Software part at the moment is good too (stock android 10), but it got like 2 updates and probably will stay like that forever. That's how Umidigi's business plan works, so anyone paying that low price should be OK with that.

It's great, but even at this moment it's vulnerable to at least one remote code execution flaw. We should do something about it.

So why not just flash generic GSI treble lineage build by AndyYan? If you query any search engine, article on getdroidtips will appear, it contains few simple steps.

The problem is it has weird partition layout. I'm familiar with linux, but not so much with android yet. And this build looks like highly customized one.

This is a list of all used partitions.

Adb shell, command S5_Pro:/ $ ls -al /dev/block/platform/bootdevice/by-name/ ouputs:

total 0
drwxr-xr-x 2 root root 1020 2020-07-21 15:50 .
drwxr-xr-x 3 root root 980 2020-07-21 15:50 ..
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 boot -> /dev/block/sdc35
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 boot_para -> /dev/block/sdc22
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 cache -> /dev/block/sdc41
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 cam_vpu1 -> /dev/block/sdc28
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 cam_vpu2 -> /dev/block/sdc29
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 cam_vpu3 -> /dev/block/sdc30
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 dtbo -> /dev/block/sdc37
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 expdb -> /dev/block/sdc5
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 flashinfo -> /dev/block/sdc43
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 frp -> /dev/block/sdc6
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 gz1 -> /dev/block/sdc31
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 gz2 -> /dev/block/sdc32
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 lk -> /dev/block/sdc33
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 lk2 -> /dev/block/sdc34
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 logo -> /dev/block/sdc36
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 md1img -> /dev/block/sdc21
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 md_udc -> /dev/block/sdc12
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 metadata -> /dev/block/sdc13
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 misc -> /dev/block/sdc3
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 nvcfg -> /dev/block/sdc10
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 nvdata -> /dev/block/sdc11
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 nvram -> /dev/block/sdc20
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 otp -> /dev/block/sdc18
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 para -> /dev/block/sdc4
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 persist -> /dev/block/sdc14
lrwxrwxrwx 1 root root 23 2020-07-21 15:50 preloader_a -> /dev/block/mmcblk0boot0
lrwxrwxrwx 1 root root 23 2020-07-21 15:50 preloader_b -> /dev/block/mmcblk0boot1
lrwxrwxrwx 1 root root 50 2020-07-21 15:50 preloader_emmc_a -> /dev/block/platform/bootdevice/by-name/preloader_a
lrwxrwxrwx 1 root root 50 2020-07-21 15:50 preloader_emmc_b -> /dev/block/platform/bootdevice/by-name/preloader_b
lrwxrwxrwx 1 root root 50 2020-07-21 15:50 preloader_ufs_a -> /dev/block/platform/bootdevice/by-name/preloader_a
lrwxrwxrwx 1 root root 50 2020-07-21 15:50 preloader_ufs_b -> /dev/block/platform/bootdevice/by-name/preloader_b
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 proinfo -> /dev/block/sdc1
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 protect1 -> /dev/block/sdc15
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 protect2 -> /dev/block/sdc16
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 recovery -> /dev/block/sdc2
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 scp1 -> /dev/block/sdc24
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 scp2 -> /dev/block/sdc25
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 sec1 -> /dev/block/sdc19
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 seccfg -> /dev/block/sdc17
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 spmfw -> /dev/block/sdc23
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 sspm_1 -> /dev/block/sdc26
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 sspm_2 -> /dev/block/sdc27
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 super -> /dev/block/sdc40
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 tee1 -> /dev/block/sdc38
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 tee2 -> /dev/block/sdc39
lrwxrwxrwx 1 root root 16 2020-07-21 15:50 userdata -> /dev/block/sdc42
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 vbmeta -> /dev/block/sdc7
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 vbmeta_system -> /dev/block/sdc8
lrwxrwxrwx 1 root root 15 2020-07-21 15:50 vbmeta_vendor -> /dev/block/sdc9

And fastboot getvar all gives:

(bootloader) max-download-size: 0x8000000
(bootloader) variant:
(bootloader) logical-block-size: 0x1000
(bootloader) erase-block-size: 0x0
(bootloader) hw-revision: ca00
(bootloader) battery-soc-ok: yes
(bootloader) battery-voltage: 4291mV
(bootloader) partition-size:sgpt: 8000
(bootloader) partition-type:sgpt: raw data
(bootloader) partition-size:flashinfo: 1000000
(bootloader) partition-type:flashinfo: raw data
(bootloader) partition-size:userdata: 3a68ef8000
(bootloader) partition-type:userdata: ext4
(bootloader) partition-size:cache: 1b000000
(bootloader) partition-type:cache: ext4
(bootloader) partition-size:super: e0000000
(bootloader) partition-type:super: raw data
(bootloader) partition-size:tee2: 900000
(bootloader) partition-type:tee2: raw data
(bootloader) partition-size:tee1: 500000
(bootloader) partition-type:tee1: raw data
(bootloader) partition-size:dtbo: 800000
(bootloader) partition-type:dtbo: raw data
(bootloader) partition-size:logo: 800000
(bootloader) partition-type:logo: raw data
(bootloader) partition-size:boot: 2000000
(bootloader) partition-type:boot: raw data
(bootloader) partition-size:lk2: 200000
(bootloader) partition-type:lk2: raw data
(bootloader) partition-size:lk: 200000
(bootloader) partition-type:lk: raw data
(bootloader) partition-size:gz2: 2000000
(bootloader) partition-type:gz2: raw data
(bootloader) partition-size:gz1: 2000000
(bootloader) partition-type:gz1: raw data
(bootloader) partition-size:cam_vpu3: f00000
(bootloader) partition-type:cam_vpu3: raw data
(bootloader) partition-size:cam_vpu2: f00000
(bootloader) partition-type:cam_vpu2: raw data
(bootloader) partition-size:cam_vpu1: f00000
(bootloader) partition-type:cam_vpu1: raw data
(bootloader) partition-size:sspm_2: 100000
(bootloader) partition-type:sspm_2: raw data
(bootloader) partition-size:sspm_1: 100000
(bootloader) partition-type:sspm_1: raw data
(bootloader) partition-size:scp2: 600000
(bootloader) partition-type:scp2: raw data
(bootloader) partition-size:scp1: 600000
(bootloader) partition-type:scp1: raw data
(bootloader) partition-size:spmfw: 100000
(bootloader) partition-type:spmfw: raw data
(bootloader) partition-size:boot_para: 1a00000
(bootloader) partition-type:boot_para: raw data
(bootloader) partition-size:md1img: 9600000
(bootloader) partition-type:md1img: raw data
(bootloader) partition-size:nvram: 4000000
(bootloader) partition-type:nvram: raw data
(bootloader) partition-size:sec1: 200000
(bootloader) partition-type:sec1: raw data
(bootloader) partition-size:otp: 3000000
(bootloader) partition-type:otp: raw data
(bootloader) partition-size:seccfg: 800000
(bootloader) partition-type:seccfg: raw data
(bootloader) partition-size:protect2: 800000
(bootloader) partition-type:protect2: ext4
(bootloader) partition-size:protect1: 800000
(bootloader) partition-type:protect1: ext4
(bootloader) partition-size:persist: 305e000
(bootloader) partition-type:persist: ext4
(bootloader) partition-size:metadata: 2000000
(bootloader) partition-type:metadata: raw data
(bootloader) partition-size:md_udc: 169a000
(bootloader) partition-type:md_udc: ext4
(bootloader) partition-size:nvdata: 4000000
(bootloader) partition-type:nvdata: ext4
(bootloader) partition-size:nvcfg: 2000000
(bootloader) partition-type:nvcfg: ext4
(bootloader) partition-size:vbmeta_vendor: 800000
(bootloader) partition-type:vbmeta_vendor: raw data
(bootloader) partition-size:vbmeta_system: 800000
(bootloader) partition-type:vbmeta_system: raw data
(bootloader) partition-size:vbmeta: 800000
(bootloader) partition-type:vbmeta: raw data
(bootloader) partition-size:frp: 100000
(bootloader) partition-type:frp: raw data
(bootloader) partition-size:expdb: 1400000
(bootloader) partition-type:expdb: raw data
(bootloader) partition-size:para: 80000
(bootloader) partition-type:para: raw data
(bootloader) partition-size:misc: 80000
(bootloader) partition-type:misc: raw data
(bootloader) partition-size:recovery: 2000000
(bootloader) partition-type:recovery: raw data
(bootloader) partition-size:proinfo: 300000
(bootloader) partition-type:proinfo: raw data
(bootloader) partition-size:pgpt: 8000
(bootloader) partition-type:pgpt: raw data
(bootloader) partition-size:preloader: 400000
(bootloader) partition-type:preloader: raw data
(bootloader) serialno: S5PRO20200004200
(bootloader) off-mode-charge: 1
(bootloader) warranty: no
(bootloader) unlocked: yes
(bootloader) secure: no
(bootloader) kernel: lk
(bootloader) product: k85v1_64
(bootloader) is-userspace: no
(bootloader) slot-count: 0
(bootloader) version-baseband: MOLY.LR13.R1.MP.V55
(bootloader) version-bootloader: k85v1_64-722dd20--20200702183212
(bootloader) version-preloader:
(bootloader) version: 0.5
all: Done!!
finished. total time: 0.005s

So you can't just flash system partition, it's not even there.

We should look closer at this device because it has great potential, but it does not look like a low hanging fruit to flash custom rom :cyclops: