Bluetooth: Improve debug logs for HCI core data paths
Add debug logs to the HCI core data handling to catch potential issues. Change-Id: I39bd3aeec9ed7b64156a9e2e899a153c0d484f38 Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This commit is contained in:
parent
d6600e075f
commit
24a0e0eeb5
1 changed files with 8 additions and 2 deletions
|
@ -173,6 +173,8 @@ static void hci_acl(struct bt_buf *buf)
|
|||
struct bt_conn *conn;
|
||||
uint8_t flags;
|
||||
|
||||
BT_DBG("buf %p\n", buf);
|
||||
|
||||
handle = sys_le16_to_cpu(hdr->handle);
|
||||
flags = (handle >> 12);
|
||||
buf->acl.handle = bt_acl_handle(handle);
|
||||
|
@ -446,15 +448,17 @@ static void hci_cmd_fiber(void)
|
|||
{
|
||||
struct bt_driver *drv = dev.drv;
|
||||
|
||||
BT_DBG("\n");
|
||||
BT_DBG("started\n");
|
||||
|
||||
while (1) {
|
||||
struct bt_buf *buf;
|
||||
|
||||
/* Wait until ncmd > 0 */
|
||||
BT_DBG("calling sem_take_wait\n");
|
||||
nano_fiber_sem_take_wait(&dev.ncmd_sem);
|
||||
|
||||
/* Get next command - wait if necessary */
|
||||
BT_DBG("calling fifo_get_wait\n");
|
||||
buf = nano_fifo_get_wait(&dev.cmd_queue);
|
||||
dev.ncmd = 0;
|
||||
|
||||
|
@ -478,9 +482,10 @@ static void hci_rx_fiber(void)
|
|||
{
|
||||
struct bt_buf *buf;
|
||||
|
||||
BT_DBG("\n");
|
||||
BT_DBG("started\n");
|
||||
|
||||
while (1) {
|
||||
BT_DBG("calling fifo_get_wait\n");
|
||||
buf = nano_fifo_get_wait(&dev.rx_queue);
|
||||
|
||||
BT_DBG("buf %p type %u len %u\n", buf, buf->type, buf->len);
|
||||
|
@ -725,6 +730,7 @@ int bt_hci_reset(void)
|
|||
|
||||
void bt_recv(struct bt_buf *buf)
|
||||
{
|
||||
BT_DBG("buf %p len %u\n", buf, buf->len);
|
||||
nano_fifo_put(&dev.rx_queue, buf);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue