Closed Bug 1159685 Opened 4 years ago Closed 4 years ago

[Bluetooth2][Daemon] Can't pair with remote device under daemon backend and API v2

Categories

(Firefox OS Graveyard :: Bluetooth, defect)

ARM
Gonk (Firefox OS)
defect
Not set

Tracking

(firefox40 fixed)

RESOLVED FIXED
2.2 S11 (1may)
Tracking Status
firefox40 --- fixed

People

(Reporter: wiwang, Assigned: yrliou)

References

Details

Attachments

(2 files, 1 obsolete file)

ENV:
Enable daemon and API v2


STR:
Pair with remote device
 

Log:

04-29 19:44:23.608  1441  1441 I GeckoBluetooth: BluetoothReplyRunnable: [WEBBT-API2] <Pair>
...
04-29 19:44:56.948   206   206 I GeckoBluetooth: BondStateChangedNotification: Bond state: 0 status: 9                                                                                                       
04-29 19:44:56.948   206   206 I GeckoBluetooth: BondStateChangedNotification: Pair failed! Abort pairing.
04-29 19:44:56.948  1441  1441 I GeckoBluetooth: FireErrorString: [WEBBT-API2] <Pair>


Note:
Using in-gecko bluedroid backend(HAL interface), Pairing works for API v2
Will, some questions:
1) Do you pair while device is discovering?
2) Does pairing succeed after your retry?
3) Is the pairing outgoing or incoming from remote device?
4) What is the reproduction rate of the bug?

Repro steps in detail and a full log file would be helpful.
Flags: needinfo?(wiwang)
Assignee: nobody → wiwang
Flags: needinfo?(wiwang)
Hi Ben,

Thanks for your comment!

(In reply to Ben Tian [:btian] from comment #1)
> Will, some questions:
> 1) Do you pair while device is discovering?
yes, and I found that no matter discovering or not, pairing will fail

> 2) Does pairing succeed after your retry?
No

> 3) Is the pairing outgoing or incoming from remote device?
outgoing to remote device

> 4) What is the reproduction rate of the bug?
100%

> 
> Repro steps in detail and a full log file would be helpful.

Log:
As attachment, which contain a full logcat log and corresponding *.cfa file in the pairing process (flame -> PTS dongle)

STR:
When every time I paired with remote device(e.g., Nexus 4), pairing will fail,

however, for more info, so I use PTS as remote device to get *.cfa, the STR is:
1. Flame: enable bluetooth 
2. PTS: run test (HFP) TC_AG_ATA_BV_01_I
3. PTS will prompt for SLC connection
4. Flame: search for bluetooth device and tap PTS dongle to pair
5. Flame will indicate: Unable to pair

Thanks!
What I saw the fail rate is near 100%. I also tried 5 times yesterday.
Just simply with the remote device (remote device is Android phone/PTS, not incoming pairing request).
And also applied the patch i did for bluedroid.
Steal this bug. ;)
Assignee: wiwang → joliu
Currently we use copy by value when we read from PDU, the value of |NotificationRunnable::mArg4| for SspVariant won't be updated.
Thus, we will receive an invalid SspVariant in |SspRequestNotification|, and no event will be fired to bluetooth app.

bluetooth1 can still pair because we don't use the ssp variant in |SspRequestNotification|.
(In reply to Jocelyn Liu [:jocelyn] [:joliu] from comment #5)
> Created attachment 8599728 [details] [diff] [review]
> Bug 1159685: Fix BluetoothSspVariant argument passing for
> SspRequestNotification.
> 
> Currently we use copy by value when we read from PDU, the value of
typo, pass by value.
> |NotificationRunnable::mArg4| for SspVariant won't be updated.
> Thus, we will receive an invalid SspVariant in |SspRequestNotification|, and
> no event will be fired to bluetooth app.
> 
> bluetooth1 can still pair because we don't use the ssp variant in
> |SspRequestNotification|.
Blocks: 1130946
Comment on attachment 8599728 [details] [diff] [review]
Bug 1159685: Fix BluetoothSspVariant argument passing for SspRequestNotification.

Hi Shawn,

Could you help to review my patch?

Thanks,
Jocelyn
Attachment #8599728 - Flags: review?(shuang)
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/6f5fc21d5ea6
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 2.2 S11 (1may)
You need to log in before you can comment on or make changes to this bug.