Closed Bug 978809 Opened 10 years ago Closed 10 years ago

[Bluetooth] Send ToggleBtAck at end of BT setup

Categories

(Firefox OS Graveyard :: Bluetooth, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
1.4 S3 (14mar)

People

(Reporter: tzimmermann, Assigned: tzimmermann)

References

Details

Attachments

(2 files, 1 obsolete file)

We need to send ToggleBtAck after BT connections have been fully set up.
The Bluedroid library does all its multi-threading internally and the use of sToggleBtMonitor was the only reason why Bluedroid used the BT thread AFAICS. After some more cleanups, we can push the BT thread completely into the BlueZ backend.
Attachment #8384660 - Flags: review?(echou)
Moving ToggleBtAck to the end of the BlueZ setup is really only the first step. We should also refactor StopInternal such that it doesn't touch sDBusConnection on the BT thread.
Attachment #8384663 - Flags: review?(echou)
I tested both patches on the Nexus 4 and the Unagi.
Blocks: 979370
Comment on attachment 8384660 [details] [diff] [review]
[01] Bug 978809: Remove sToggleBtMonitor from Bluedroid backend

Review of attachment 8384660 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good :)
Attachment #8384660 - Flags: review?(echou) → review+
Comment on attachment 8384663 [details] [diff] [review]
[02] Bug 978809: Send ToggleBtAck after finishing BlueZ connection setup

Review of attachment 8384663 [details] [diff] [review]:
-----------------------------------------------------------------

r=me with nit addressed. Waiting for the next patch. :)

::: dom/bluetooth/bluez/BluetoothDBusService.cpp
@@ +1854,5 @@
>  
>    void Run()
>    {
> +    MOZ_ASSERT(!sDBusConnection);
> +  

nit: whitespaces
Attachment #8384663 - Flags: review?(echou) → review+
Changes to v1:

  - cleaned up whitespace error
Attachment #8384663 - Attachment is obsolete: true
Attachment #8386689 - Flags: review+
https://hg.mozilla.org/mozilla-central/rev/8eb485a8503e
https://hg.mozilla.org/mozilla-central/rev/f7444f0ee3b9
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.4 S3 (14mar)
You need to log in before you can comment on or make changes to this bug.