Skip to content
Commit 77535ce2 authored by jackqdyulei's avatar jackqdyulei
Browse files

Fix deadlock in LocalBluetoothManager

Following deadlock exist in previous code:
1. Main thread
Device.refresh()->Device.dispatchCallback()->Lock callback->(handle
callback in systemui)->DeviceManager.getDevicesCopy()-> try lock
deviceManager
2. Bg thread
DeviceManager.onUuidChange()->Lock
deviceManager->Device.refresh()->Device.dispatchCallback()-> try lock
callback

This CL remove sychnorized method in DeviceManager to unblock this
deadlock. Since UuidChange can only happen in bg thread, we don't need
this extra lock in DeviceManager.

Fixes: 112483982
Test: Manual
Change-Id: I1a8bb130cfff40358783f5f5da7e50e5f0a42e20
parent 989bb371
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment