From a7ac34eaa9b895e16aed816c504d167027898d7b Mon Sep 17 00:00:00 2001 From: jacqueline Date: Wed, 7 Feb 2024 21:34:03 +1100 Subject: [PATCH] hack around deadlock during bt disable --- src/drivers/bluetooth.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/drivers/bluetooth.cpp b/src/drivers/bluetooth.cpp index f266b51c..1a303748 100644 --- a/src/drivers/bluetooth.cpp +++ b/src/drivers/bluetooth.cpp @@ -86,7 +86,9 @@ auto Bluetooth::Enable() -> bool { } auto Bluetooth::Disable() -> void { - auto lock = bluetooth::BluetoothState::lock(); + // FIXME: the BT tasks unfortunately call back into us while holding an + // internal lock, which then deadlocks with our fsm lock. + // auto lock = bluetooth::BluetoothState::lock(); tinyfsm::FsmList::dispatch( bluetooth::events::Disable{}); }