You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/11/05 07:07:18 UTC

[GitHub] [incubator-nuttx] btashton commented on issue #2084: sim:bluetooth build broken

btashton commented on issue #2084:
URL: https://github.com/apache/incubator-nuttx/issues/2084#issuecomment-722187516


   > Enabling SIM_WALLTIME indeed makes the wait function as expected (although HCI initialization still fails). I would say that either SIM_WALLTIME=n is broken or it makes no sense to have it disabled if timeouts will not work.
   > 
   > Regarding bluetooth stack itself, I get the following:
   > 
   > ```
   > bt_initialize: btdev 0x5648f0b60080
   > bt_hci_cmd_create: opcode 0c03 param_len 0
   > bt_buf_alloc: buf 0x5648f0b63590 type 0 reserve 0
   > bt_hci_cmd_create: buf 0x5648f0b63590
   > bt_buf_extend: buf 0x5648f0b63590 len 3
   > bt_hci_cmd_send_sync: opcode 0c03 len 3
   > hci_tx_kthread: started
   > hci_tx_kthread: Sending command 0c03 buf 0x5648f0b63590 to driver
   > btnull_send: Bit bucket: length 3
   > btnull_send: CMD: 0c03
   > bt_buf_alloc: buf 0x5648f0b63560 type 1 reserve 0
   > btnull_send: Send CMD complete event
   > bt_hci_receive: buf 0x5648f0b63560 len 5
   > priority_rx_work: list 0x5648f0b63650
   > priority_rx_work: buf 0x5648f0b63560 type 1 len 5
   > bt_buf_consume: buf 0x5648f0b63560 len 2
   > hci_cmd_complete: opcode 0c03
   > bt_buf_consume: buf 0x5648f0b63560 len 3
   > hci_reset_complete: status 0
   > bt_buf_release: buf 0x5648f0b63560 ref 1 type 1
   > bt_buf_release: Buffer freed: 0x5648f0b63560
   > bt_buf_release: buf 0x5648f0b63590 ref 1 type 0
   > bt_buf_release: Buffer freed: 0x5648f0b63590
   > hci_initialize: ERROR: BT_HCI_OP_RESET failed: -116
   > bt_initialize: ERROR:  hci_initialize failed: -116
   > ERROR: btnull_register() failed: -116
   > ```
   
   @v01d I think something is broken in the stack because I get this running via the HCISOCKET:
   ```
   = Close Index: 60:57:18:EE:03:FD                             [hci0] 3591.587962
   @ MGMT Event: Index Removed (0x0005) plen 0         {0x0002} [hci0] 3591.588456
   @ MGMT Event: Index Removed (0x0005) plen 0         {0x0001} [hci0] 3591.588456
   = Open Index: 60:57:18:EE:03:FD                              [hci0] 3591.588505
   = Index Info: 60:57:18:EE:03:FD (Intel Corp.)                [hci0] 3591.588507
   @ RAW Close: nuttx                                         {0x0003} 3591.588510
   @ USER Open: nuttx (privileged) version 2.22        {0x0003} [hci0] 3591.588512
   < HCI Command: Reset (0x03|0x0003) plen 0              #2759 [hci0] 3591.589814
   = bluetoothd: Endpoint unregistered: sender=:1.67 path=/MediaEn..   3591.590811
   = bluetoothd: Endpoint unregistered: sender=:1.67 path=/MediaEn..   3591.590819
   > HCI Event: Command Complete (0x0e) plen 4            #2760 [hci0] 3591.603696
         Reset (0x03|0x0003) ncmd 2
           Status: Success (0x00)
   ```
   ```
   bt_initialize: btdev 0x44b960
   bt_hci_cmd_create: opcode 0c03 param_len 0
   bt_buf_alloc: buf 0x466250 type 0 reserve 0
   bt_hci_cmd_create: buf 0x466250
   bt_buf_extend: buf 0x466250 len 3
   bt_hci_cmd_send_sync: opcode 0c03 len 3
   hci_tx_kthread: started
   hci_tx_kthread: Sending command 0c03 buf 0x466250 to driver
   bt_buf_release: buf 0x466250 ref 1 type 0
   bt_buf_release: Buffer freed: 0x466250
   bt_buf_alloc: buf 0x466250 type 0 reserve 1
   bthcisock_loop: Recv BT_EVT
   bt_hci_receive: buf 0x466250 len 6
   priority_rx_work: list 0x466310
   priority_rx_work: buf 0x466250 type 1 len 6
   bt_buf_consume: buf 0x466250 len 2
   hci_cmd_complete: opcode 0c03
   bt_buf_consume: buf 0x466250 len 3
   hci_reset_complete: status 0
   hci_cmd_done: ERROR:  Unexpected completion of opcode 0x0c03
   bt_buf_alloc: buf 0x466220 type 0 reserve 1
   bt_buf_release: buf 0x466250 ref 1 type 1
   bt_buf_release: Buffer freed: 0x466250
   hci_initialize: ERROR: BT_HCI_OP_RESET failed: -116
   bt_initialize: ERROR:  hci_initialize failed: -116
   ERROR: bthcisock_register() failed: -116
   ```
   
   It seems like it is aware that reset completed, but then still errors out on cmd_done.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org