05fd0df0f3ec71ec6ea874439feda960ef882d0b
Some camera HALs spin up a preview thread and need to wait for the thread to exit. This can create a potential deadlock. In stopPreview, we take the main lock. If a preview callback occurs while the lock is held, the preview thread will block. If the camera HAL is waiting for the preview thread to exit, this will cause a deadlock. This patch breaks out the preview buffer heap into a separate mutex. This mutex is never held when the main lock is held, thus preventing the deadlock from occuring.
Description
No description provided
Languages
Java
73.7%
Kotlin
14%
PowerBuilder
5.8%
C++
5.2%
AIDL
1%