Open presslab-us opened 3 years ago
I installed the libdexfile.so dependency and now I see this:
06-06 07:48:43.528 881 881 F linker : CANNOT LINK EXECUTABLE "/vendor/preavs/bin/hw/android.hardware.drm@1.1-service.widevine": cannot locate symbol "_ZNK7android4h idl4base4V1_08BnHwBase13checkSubclassEPKv" referenced by "/system/lib/android.hardware.drm@1.0.so"...
I tried a bunch of stuff. I looked for a widevine library from a newer Huawei rom, but all the ones I found still have the ABI issues. I tried numerous ways to disable hwservicemanager
from trying to load android.hardware.drm@1.0::IDrmFactory/widevine
but no luck.
I have attached the ANR log from Chrome: anr_2021-06-09-05-00-47-737.txt
Chrome freeze also in lineage 18.1 on P20 and mediapad T5
To fix the problem
setprop persist.sys.restart.mediadrm false
service drm-widevine-hal-1-0 /vendor/bin/hw/android.hardware.drm@1.0-service.widevine class hal user media group mediadrm drmrpc ioprio rt 4 writepid /dev/cpuset/foreground/tasks /dev/stune/foreground/tasks setenv LD_LIBRARY_PATH /vendor/lib
on property:persist.sys.restart.mediadrm=true restart drm-widevine-hal-1-0 setprop persist.sys.restart.mediadrm false
set correct permission and selinux label to android.hardware.drm@1.0-service.widevine, libunwind.so and libwvhidl.so
Thanks for the help @Iceows! I am just now trying this again :smile:
With the preavs partition I can extract all the files needed (mine shows 1.1 and 1.2 widevine).
But with vendor_a I cannot extract all the files. I have copied the image and can mount it fine. But I get these errors on many files. I get the same errors if I create the image from the mmcblk0p56 or if I use the vendor_image.emmc.win
image from UPDATE.APP
.
[1288147.966190] erofs: (device loop1): z_erofs_readahead: readahead error at folio 1 @ nid 2672484
[1288147.966385] erofs: (device loop1): z_erofs_read_folio: read error -117 @ 1 of nid 2672484
[1288147.966390] erofs: (device loop1): z_erofs_read_folio: read error -117 @ 1 of nid 2672484
[1288147.966428] erofs: (device loop1): z_erofs_read_folio: read error -117 @ 1 of nid 2672484
# uname -a
Linux socrates 6.6.9-200.fc39.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Jan 1 20:05:54 UTC 2024 x86_64 GNU/Linux
#
When I look at the copied files they are 0 size. Maybe I need an older kernel to extract?
Do you have install erofs utilities ? Kirin710 use erofs filesystem on vendor partition
Yes, I have tried using fsck.erofs --extract=vendor_a
and also mounting the share (errors as shown above). I have downloaded many different programs to extract the erofs image but they all have errors when I try to extract.
I was able to copy the vendor files from the phone using root. I noticed I already have the same widevine files in /vendor/preavs
My init script is as below. It looks like it it copying something from the system partition on startup. And since I don't have the original system partition this isn't working. I will look next at the original system partition to see what files it is copying.
on property:init.svc.mediadrm=running
mkdir /data/vendor/mediadrm 0770 media mediadrm
start vendor.move_data_sh
service vendor.move_data_sh /system/bin/move_widevine_data.sh
class late_start
user media
group media mediadrm system
disabled
oneshot
service vendor.drm-widevine-hal-1-1 /vendor/preavs/bin/hw/android.hardware.drm@1.1-service.widevine
interface android.hardware.drm@1.1::ICryptoFactory widevine
interface android.hardware.drm@1.1::IDrmFactory widevine
class hal
user media
group media mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks /dev/stune/foreground/tasks
setenv LD_LIBRARY_PATH /vendor/preavs/lib:/vendor/wv_lib
on property:persist.odm.restart.mediadrm=true
restart vendor.drm-widevine-hal-1-1
setprop persist.odm.restart.mediadrm false
on property:odm.drm.stop=true
stop vendor.drm-widevine-hal-1-1
setprop odm.drm.stop false
But why you don't use twrp and mount preavs partition with erofs type ?
Le lun. 12 févr. 2024, 18:04, presslab-us @.***> a écrit :
I was able to copy the vendor files from the phone using root. I noticed I already have the same widevine files in `/vendor/preavs'
My init script is as below. It looks like it it copying something from the system partition on startup. And since I don't have the original system partition this isn't working. I will look next at the original system partition to see what files it is copying.
on property:init.svc.mediadrm=running mkdir /data/vendor/mediadrm 0770 media mediadrm start vendor.move_data_sh
service vendor.move_data_sh /system/bin/move_widevine_data.sh class late_start user media group media mediadrm system disabled oneshot
service vendor.drm-widevine-hal-1-1 @. interface @.::ICryptoFactory widevine interface @.***::IDrmFactory widevine class hal user media group media mediadrm drmrpc ioprio rt 4 writepid /dev/cpuset/foreground/tasks /dev/stune/foreground/tasks setenv LD_LIBRARY_PATH /preavs/lib
on property:persist.odm.restart.mediadrm=true restart vendor.drm-widevine-hal-1-1 setprop persist.odm.restart.mediadrm false
on property:odm.drm.stop=true stop vendor.drm-widevine-hal-1-1 setprop odm.drm.stop false
— Reply to this email directly, view it on GitHub https://github.com/phhusson/treble_experimentations/issues/1885#issuecomment-1939161054, or unsubscribe https://github.com/notifications/unsubscribe-auth/AVDNGLRDP767IUBNR6I6S4TYTJDSRAVCNFSM46EPEY6KU5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TCOJTHEYTMMJQGU2A . You are receiving this because you were mentioned.Message ID: @.***>
I have only been able to make this old TWRP work. It can't mount those erofs partitions (and not system from LineageOS 21 anymore either). Maybe you can think of a newer one that's working for Mediapad M5? https://xdaforums.com/t/recovery-8-0-unofficial-twrp-3-2-1-0-for-emui-8-0-06-05-2018.3773449/
I've looked at the EMUI 9 SYSTEM.img and I can't see any /system/bin/move_widevine_data.sh
. So I don't know where to go from there :smile:
I was able to (mostly) make a new vendor image with mkfs.erofs
. It boots fine but for some reason the fingerprint reader has an error with my generated image. At first it would not boot at all but once I figured out how to build with selinux properties the new image worked.
Maybe I can try to find a boot log to see what the errors are with this widevine service?
Anything that uses Chrome browsing engine (Brave, etc) freezes up the UI after a minute. I can still see any web page updates but I can't scroll or do anything. I can force close Chrome and tablet is otherwise fine after that.
Right when the freeze occurs, logs show problems with Widevine DRM:
and dmesg shows:
On startup there is this error:
When I run "DRM Info" app, it does not open and freezes with the same error messages in the logs.
I'd be ok to just disable Widevine altogether but I'm not sure how to do that. I am able to build this repo so if there is something to try I can test it.