This is an automated email from the ASF dual-hosted git repository. aguettouche pushed a commit to branch releases/10.0 in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit dbbc5515ef6e1b1e7b6f94c7dd9c3f33e4a9f51f Author: Matias N <[email protected]> AuthorDate: Sun Oct 25 12:02:55 2020 -0300 bt_hcicore.c: Fix wrong order of bt_send() and setting last command sent --- wireless/bluetooth/bt_hcicore.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/wireless/bluetooth/bt_hcicore.c b/wireless/bluetooth/bt_hcicore.c index a828e46..7e2a42d 100644 --- a/wireless/bluetooth/bt_hcicore.c +++ b/wireless/bluetooth/bt_hcicore.c @@ -1002,11 +1002,6 @@ static int hci_tx_kthread(int argc, FAR char *argv[]) g_btdev.ncmd = 0; - wlinfo("Sending command %04x buf %p to driver\n", - buf->u.hci.opcode, buf); - - btdev->send(btdev, buf); - /* Clear out any existing sent command */ if (g_btdev.sent_cmd) @@ -1017,6 +1012,11 @@ static int hci_tx_kthread(int argc, FAR char *argv[]) } g_btdev.sent_cmd = buf; + + wlinfo("Sending command %04x buf %p to driver\n", + buf->u.hci.opcode, buf); + + btdev->send(btdev, buf); } return EXIT_SUCCESS; /* Can't get here */
