Re: [bug report] Reproducible pairing loss after reboot / Mediatek RZ616 [partly resolved / probably not a Bluez bug]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Luiz,

Luiz Augusto von Dentz:
Hi Jonas,

On Wed, Jul 3, 2024 at 5:01 AM Jonas Özbay <usul@xxxxxx> wrote:

Hello Bluetooth List,

this is a first post here as I found no other place to report bugs. Please forgive if I do not report according to the expected format or missed any additional information and point me to the respective guidelines - thank you!

==Problem summary:==
Bluetooth pairing with a mouse is lost after system reboot. The pairing has to be removed and a new pairing initiated for being able to use the mouse again.

==System specifications:==
Framework Laptop 16 (Batch 7)
CPU: Ryzen 7 7840HS
GPU: AMD RX 7700S
WiFi/BT controller: Mediatek RZ616
Linux Kernel: 6.9.7-200.fc40.x86_64
Distro: Fedora 40
Bluez version: 5.76-1.fc40
Peripheral device: Cherry Gentix BT

==Reproduction steps:==
1) Pair the Bluetooth mouse via GUI or bluetoothctl
2) The mouse will now work as expected
3) Reboot the system
4) The mouse does not work, the GUI might switch between "connected/disconnected"
5) start btmon
6) clicking the left mouse button produced the attached btmon log

Weird, it is doing a pairing request right away:

< ACL Data TX: Handle 512 flags 0x00 dlen 11

#11 [hci0] 2.185573
       SMP: Pairing Request (0x01) len 6
         IO capability: NoInputNoOutput (0x03)
         OOB data: Authentication data not present (0x00)
         Authentication requirement: No bonding, No MITM, SC, No
Keypresses, CT2 (0x28)
         Max encryption key size: 16
         Initiator key distribution: <none> (0x08)
         Responder key distribution: IdKey LinkKey (0x0a)

But it is doing No bonding, so perhaps that is the real problem here
since that indicates to bluetoothd not to store the keys. The No
Bonding is controlled by HCI_BONDABLE flag which is set by
MGMT_OP_SET_BONDABLE which by default is false but is automatically
set to true once a pairing agent is registered, try reproducing this
with bluetoothctl and if you are not able to this must be gnome/fedora
not registering an agent.

Sometimes btmon also displays the following errors after MGMT Event: Device disconnected (sorry, console cut them, could not capture to file):
bluetoothd[2974]: = profiles/input/hog-lib.c:proto_mode_read_cb() Protocol Mode characteristic read failed: Request attribute has encountered an...   14.720255
bluetoothd[2974]: = profiles/input/hog-lib.c:report_reference_cb() Read Report Reference descriptor failed: Request attribute has encountered an...   14.720368
bluetoothd[2974]: = profiles/input/hog-lib.c:report_reference_cb() Read Report Reference descriptor failed: Request attribute has encountered an...   14.720401
bluetoothd[2974]: = profiles/input/hog-lib.c:info_read_cb() HID Information read failed: Request attribute has encountered an unlikely error          14.720616
bluetoothd[2974]: = profiles/deviceinfo/deviceinfo.c:read_pnpid_cb() Error reading PNP_ID value: Request attribute has encountered an unlikely er..   14.720675

==Additional Information:==
The mouse also sometimes stops working suddenly. In this case it might come back after a few seconds, but sometimes I have to use "systemctl restart bluetooth" which re-enables the mouse. This might be a different problem though. I have no way to reproduce this well so I also could not produce a log file yet.

Please tell me if I can provide any additional information. Thank you for your work on this piece of software! :)

Cheers,
   Jonas

Thank you very much for the extremely quick reply!
After pairing the device with bluetoothctl it finally reconnects after reboot.
I have some basic knowledge of C/C++ - where would I start looking for in the GNOME sources? Any specific function calls I could search for to have a starting point? I have no idea about how the UI would call things from the bluetooth system ...





[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux