RE: Bluetooth / rfcomm issue with traffic send

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

 



Resending to the mail list in plain text

From: Mikhail Pavlukhin 
Sent: Thursday, October 3, 2019 10:45 AM
To: 'linux-bluetooth@xxxxxxxxxxxxxxx' <linux-bluetooth@xxxxxxxxxxxxxxx>
Cc: 'johan.hedberg@xxxxxxxxx' <johan.hedberg@xxxxxxxxx>; 'marcel@xxxxxxxxxxxx' <marcel@xxxxxxxxxxxx>
Subject: Bluetooth / rfcomm issue with traffic send

Hello,

Would you please assist me with a troubleshooting of the issue with Bluetooth stack? Any advice or recommendation is appreciated.

The system is based on the:
- Linux kernel 4.14.68 
- Bluez - 5.48
- Intel Stick computer with attached Bluetooth USB adapter Broadcom
- Application written in JavaScript/NodeJS and JavaScript plugin https://github.com/waeco/node-bluez helping with Bluetooth connection management

The aim is to establish connection with external device using Bluetooth SPP profile and send/receive certain amount of traffic to the external device. External device is ALPS Evolution series based (https://www.alps.com/prod/info/E/HTML/Communication/Bluetooth/Bluetooth_list1.html)

The observation is the following:
Bluetooth SPP Connection can be successfully established (after SDP discovery, Pairing procedures) and socket descriptor is returned to the user space application. So it is possible to use it for sending - receiving traffic. It is supposed to send some packets containing ASCII symbols with different intensity (packets per second) and packet length. Traffic sending might continue up to several hours. At some moment (spontaneously) that traffic stops (do not see any packets outgoing from the HCI interface associated with Broadcom adapter) even though peer device is available and working fine. Bluez reports devices as paired and connected. In that moment each call of send function on socket finished with failure and errno 11 reported. Tried to check dmesg and system logs, but there is no indication of the failures or error reports. Tried to compare list of open sockets in bad and good case (for rfcomm and our application/NodeJS) - they are the same. Now trying to use Dynamic Debug feature in Linux kernel and trace functions in https://github.com/torvalds/linux/blob/63bdf4284c38a48af21745ceb148a087b190cd21/net/bluetooth/rfcomm/sock.c, but there are a lot of printouts so it is hard to follow what is going on.
It seems the issue with traffic stop reproducible more frequently in case if there is high traffic intensity and small packet length (~64 Kbps).

Could you please advise what modules better to trace with Dynamic Debug feature? Are there any idea why errno 11 can be reported? BTW am I right saying that errno 11 is 
#define EAGAIN        11     /* Try again */ (taken from https://github.com/torvalds/linux/blob/6f0d349d922ba44e4348a17a78ea51b7135965b1/include/uapi/asm-generic/errno-base.h) ?
Actually send attempt is retried, but the traffic sending (towards to the external device) is not restarted even after few minutes.

Thank you in advance, Mikhail.




[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