bluetooth: hci: spi: log TX retransmissions

Add log output when the HCI interface is forced to retransmit a packet
because the controller is not ready.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
This commit is contained in:
Jordan Yates 2023-10-20 14:00:41 +10:00 committed by Carles Cufí
commit 0f903f04ac

View file

@ -426,10 +426,14 @@ static int bt_spi_send(struct net_buf *buf)
if (!ret) {
/* Transmit the message */
do {
while (true) {
ret = bt_spi_transceive(buf->data, buf->len,
rx_first, 1);
} while (rx_first[0] == 0U && !ret);
if (rx_first[0] != 0U || ret) {
break;
}
LOG_DBG("Controller not ready for SPI transaction of %d bytes", buf->len);
}
}
release_cs();