BT support on Khadas VIM3

Which system do you use? Android, Ubuntu, OOWOW or others?

Android 14 - r28 - AOSP14

Which version of system do you use? Please provide the version of the system here:

Khadas VIM 3 pro

Please describe your issue below:

We followed below steps to get the code: The AOSP and AAOS Meetup

We are flashing the AOSP14 code on the KHADAS vim 3 board, but after flashing we are getting the BT crash continusly due to BT MAP client.

Post a console log of your issue below:

Bt_crash_logs.txt (4.2 MB)



09-09 10:03:06.412  1445  4757 E ActivityThread: Failed to find provider info for mms-sms
--------- beginning of crash
09-09 10:03:06.413  1445  4757 E AndroidRuntime: FATAL EXCEPTION: MceStateMachine
09-09 10:03:06.413  1445  4757 E AndroidRuntime: Process: com.android.bluetooth, PID: 1445
09-09 10:03:06.413  1445  4757 E AndroidRuntime: java.lang.NullPointerException: Attempt to invoke interface method 'boolean android.database.Cursor.moveToNext()' on a null object reference
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at com.android.bluetooth.mapclient.MapClientContent.clearMessages(MapClientContent.java:437)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at com.android.bluetooth.mapclient.MapClientContent.<init>(MapClientContent.java:131)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at com.android.bluetooth.mapclient.MceStateMachine$Connected.enter(MceStateMachine.java:579)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at com.android.internal.util.StateMachine$SmHandler.invokeEnterMethods(StateMachine.java:1038)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at com.android.internal.util.StateMachine$SmHandler.performTransitions(StateMachine.java:880)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at com.android.internal.util.StateMachine$SmHandler.handleMessage(StateMachine.java:820)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at android.os.Handler.dispatchMessage(Handler.java:106)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at android.os.Looper.loopOnce(Looper.java:205)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at android.os.Looper.loop(Looper.java:294)
09-09 10:03:06.413  1445  4757 E AndroidRuntime: 	at android.os.HandlerThread.run(HandlerThread.java:67)

For work around -
We disable the MAP connection from mobile side, and Bluetooth stopped crashing.. it remained connected.

bt_crashes_after_disabling_map_from_mobile_side.txt (2.7 MB)

But when we get the incoming call09-11 15:16:07.102  4723  4723 F DEBUG   : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
09-11 15:16:07.102  4723  4723 F DEBUG   : Build fingerprint: 'generic/yukawa/vim3:14/UP1A.231105.001.B2/eng.chandr.20250910.195555:userdebug/test-keys'
09-11 15:16:07.102  4723  4723 F DEBUG   : Revision: '0'
09-11 15:16:07.102  4723  4723 F DEBUG   : ABI: 'arm64'
09-11 15:16:07.102  4723  4723 F DEBUG   : Timestamp: 2025-09-11 15:16:06.738831419+0000
09-11 15:16:07.102  4723  4723 F DEBUG   : Process uptime: 0s
09-11 15:16:07.102  4723  4723 F DEBUG   : Cmdline: com.android.bluetooth
09-11 15:16:07.102  4723  4723 F DEBUG   : pid: 994, tid: 1212, name: bt_stack_manage  >>> com.android.bluetooth <<<
09-11 15:16:07.102  4723  4723 F DEBUG   : uid: 1001002
09-11 15:16:07.102  4723  4723 F DEBUG   : tagged_addr_ctrl: 0000000000000001 (PR_TAGGED_ADDR_ENABLE)
09-11 15:16:07.102  4723  4723 F DEBUG   : signal 6 (SIGABRT), code -1 (SI_QUEUE), fault addr --------
09-11 15:16:07.102  4723  4723 F DEBUG   : Abort message: 'assertion 'false' failed - Done waiting for debug information after HCI timeout (SNIFF_MODE)'
09-11 15:16:07.102  4723  4723 F DEBUG   :     x0  0000000000000000  x1  00000000000004bc  x2  0000000000000006  x3  0000e4d9c4174020
09-11 15:16:07.102  4723  4723 F DEBUG   :     x4  1f646d6e431f2c1f  x5  1f646d6e431f2c1f  x6  1f646d6e431f2c1f  x7  7f7f7f7f7f7f7f7f
09-11 15:16:07.102  4723  4723 F DEBUG   :     x8  00000000000000f0  x9  0000e4dcd80b4090  x10 0000000000000001  x11 0000e4dcd80fdf00
09-11 15:16:07.102  4723  4723 F DEBUG   :     x12 0000e4d9c4172ee0  x13 000000000000005d  x14 0000e4d9c4174280  x15 0000000000000000
09-11 15:16:07.102  4723  4723 F DEBUG   :     x16 0000e4dcd816ad08  x17 0000e4dcd8146810  x18 0000e4d9c2f84028  x19 00000000000000ac
09-11 15:16:07.102  4723  4723 F DEBUG   :     x20 00000000000000b2  x21 00000000000003e2  x22 00000000000004bc  x23 00000000ffffffff
09-11 15:16:07.102  4723  4723 F DEBUG   :     x24 0000e4d9c4174780  x25 0000000000000001  x26 00000000ffffffff  x27 0000e4da43616000
09-11 15:16:07.102  4723  4723 F DEBUG   :     x28 b400e4db75e6b96c  x29 0000e4d9c41740a0
09-11 15:16:07.102  4723  4723 F DEBUG   :     lr  0000e4dcd80ee414  sp  0000e4d9c4174000  pc  0000e4dcd80ee444  pst 0000000000000000
09-11 15:16:07.102  4723  4723 F DEBUG   : 11 total frames
09-11 15:16:07.102  4723  4723 F DEBUG   : backtrace:
09-11 15:16:07.102  4723  4723 F DEBUG   :       #00 pc 000000000005c444  /apex/com.android.runtime/lib64/bionic/libc.so (abort+180) (BuildId: e28e590ca0e65ae6ef686c6e737bc371)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #01 pc 000000000064ba44  /apex/com.android.art/lib64/libart.so (art::Runtime::Abort(char const*)+116) (BuildId: 00404bfd7d12f9b389b42cb48f708929)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #02 pc 0000000000038660  /apex/com.android.art/lib64/libbase.so (android::base::SetAborter(std::__1::function<void (char const*)>&&)::$_0::__invoke(char const*)+80) (BuildId: e57c5f0ead96db4dc4273a4296f223e3)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #03 pc 0000000000006fd4  /system/lib64/liblog.so (__android_log_assert+308) (BuildId: 2927280f3641c0f262c1e4a504c850ab)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #04 pc 0000000000b3ed8c  /apex/com.android.btservices/lib64/libbluetooth_jni.so (bluetooth::hci::abort_after_time_out(bluetooth::hci::OpCode)+92) (BuildId: fb5d0f798e0a558b8dbbd3b90e1f8ac3)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #05 pc 0000000000c9f90c  /apex/com.android.btservices/lib64/libbluetooth_jni.so (bluetooth::os::Alarm::on_fire()+108) (BuildId: fb5d0f798e0a558b8dbbd3b90e1f8ac3)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #06 pc 0000000000ca1344  /apex/com.android.btservices/lib64/libbluetooth_jni.so (bluetooth::os::Reactor::Run()+628) (BuildId: fb5d0f798e0a558b8dbbd3b90e1f8ac3)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #07 pc 0000000000ca1f30  /apex/com.android.btservices/lib64/libbluetooth_jni.so (bluetooth::os::Thread::run(bluetooth::os::Thread::Priority)+176) (BuildId: fb5d0f798e0a558b8dbbd3b90e1f8ac3)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #08 pc 0000000000ca20d4  /apex/com.android.btservices/lib64/libbluetooth_jni.so (void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (bluetooth::os::Thread::*)(bluetooth::os::Thread::Priority), bluetooth::os::Thread*, bluetooth::os::Thread::Priority> >(void*)+68) (BuildId: fb5d0f798e0a558b8dbbd3b90e1f8ac3)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #09 pc 00000000000c9fb0  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*)+208) (BuildId: e28e590ca0e65ae6ef686c6e737bc371)
09-11 15:16:07.103  4723  4723 F DEBUG   :       #10 pc 000000000005dd90  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+64) (BuildId: e28e590ca0e65ae6ef686c6e737bc371), BT starts crashing again:

“Abort message: ‘assertion ‘init_status == std::future_status::ready’ failed - Can’t start stack, last instance: starting Controller’” .

We need your urgent support to fix all of these issue for BT.