我在做小米平板2到 Lineage14.1(Android7.1.2) 的适配,手头只有 MIUI9(Android5.1) 的库文件。好不容易弄好了显卡驱动出现了开机动画,但卡在 sensorhubd 环节,出现 crash。
从日志看,貌似是 libaware_client.so 中的 SharedBuffer::acquire() 调用 libcutils.so 中的 android_atomic_inc() 时出现了问题。由于没有 libaware_client.so 的源码,不知道该怎么分析和解决,还望能有人指点,不胜感激!
crash 日志如下:
01-30 02:39:44.909 3101 3101 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
01-30 02:39:44.909 3101 3101 F DEBUG : LineageOS Version: '14.1-20220120-UNOFFICIAL-latte'
01-30 02:39:44.909 3101 3101 F DEBUG : Build fingerprint: 'Xiaomi/latte/latte:5.1/LMY47I/V8.2.2.0.LACCNDL:user/release-keys'
01-30 02:39:44.909 3101 3101 F DEBUG : Revision: '0'
01-30 02:39:44.909 3101 3101 F DEBUG : ABI: 'x86'
01-30 02:39:44.910 3101 3101 F DEBUG : pid: 3033, tid: 3033, name: sensorhubd >>> /system/bin/sensorhubd <<<
01-30 02:39:44.910 3101 3101 F DEBUG : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
01-30 02:39:44.910 3101 3101 F DEBUG : eax 00000001 ebx f68f5dcc ecx 00000000 edx f777a371
01-30 02:39:44.910 3101 3101 F DEBUG : esi f68b200c edi f7492010
01-30 02:39:44.910 3101 3101 F DEBUG : xcs 00000023 xds 0000002b xes 0000002b xfs 00000003 xss 0000002b
01-30 02:39:44.910 3101 3101 F DEBUG : eip f67db2ce ebp ffe7d878 esp ffe7d878 flags 00010286
01-30 02:39:44.916 3101 3101 F DEBUG :
01-30 02:39:44.916 3101 3101 F DEBUG : backtrace:
01-30 02:39:44.917 3101 3101 F DEBUG : #00 pc 000062ce /system/lib/libcutils.so (android_atomic_inc+14)
01-30 02:39:44.917 3101 3101 F DEBUG : #01 pc 00008f6d /system/lib/libaware_client.so (_ZNK7android12SharedBuffer7acquireEv+29)
01-30 02:39:44.917 3101 3101 F DEBUG : #02 pc 00005470 /system/lib/libaware_client.so (_ZN7android7String8C1Ev+32)
01-30 02:39:44.917 3101 3101 F DEBUG : #03 pc 000074b1 /system/lib/libEGL.so
01-30 02:39:44.917 3101 3101 F DEBUG : #04 pc 0000b91b /system/bin/linker (__dl__ZN6soinfo13call_functionEPKcPFvvE+139)
01-30 02:39:44.917 3101 3101 F DEBUG : #05 pc 0000b803 /system/bin/linker (__dl__ZN6soinfo10call_arrayEPKcPPFvvEjb+323)
01-30 02:39:44.917 3101 3101 F DEBUG : #06 pc 00009423 /system/bin/linker (__dl__ZN6soinfo17call_constructorsEv+371)
01-30 02:39:44.917 3101 3101 F DEBUG : #07 pc 0000937a /system/bin/linker (__dl__ZN6soinfo17call_constructorsEv+202)
01-30 02:39:44.917 3101 3101 F DEBUG : #08 pc 0000937a /system/bin/linker (__dl__ZN6soinfo17call_constructorsEv+202)
01-30 02:39:44.918 3101 3101 F DEBUG : #09 pc 0000937a /system/bin/linker (__dl__ZN6soinfo17call_constructorsEv+202)
01-30 02:39:44.918 3101 3101 F DEBUG : #10 pc 0000937a /system/bin/linker (__dl__ZN6soinfo17call_constructorsEv+202)
01-30 02:39:44.918 3101 3101 F DEBUG : #11 pc 0000937a /system/bin/linker (__dl__ZN6soinfo17call_constructorsEv+202)
01-30 02:39:44.918 3101 3101 F DEBUG : #12 pc 00010ec2 /system/bin/linker (__dl__ZL29__linker_init_post_relocationR19KernelArgumentBlockj+7746)
01-30 02:39:44.918 3101 3101 F DEBUG : #13 pc 0000efb6 /system/bin/linker (__dl___linker_init+630)
01-30 02:39:44.918 3101 3101 F DEBUG : #14 pc 0001c4f3 /system/bin/linker (__dl__start+35)