mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-08-16 15:16:36 +00:00
The Bluetooth Specification allows for optional Controller to Host flow control based on the same credit-based mechanism as the Host to Controller one. This is particularly useful in 2-chip solutions where the Host and the Controller are connected via a physical link (UART, SPI or similar) where the Host is sometimes required to ask the Controller to throttle its data traffic while still making sure that relevant events get through the line. This implementation is based on a simple queue of pending events and data that is populated whenever the Controller detects that the Host is out of buffers and then emptied whenever the Host notifies the Controller that is ready to receive data again. Events relevant to the connections are also queued to preserve the order of arrival. At this point the Controller ignores the connection handle sent by the Host and treats all connections equally, and it also queues events even for connections that have no data pending in the queue. Both this items can be improved if necessity arises. Note that Number of Completed Packets will still flow freely from the Controller to the Host regardless of the pending ACL data packets, which might lead to inconsistencies in the sequential order of certain operations that include bi-directional data transfer. Jira: ZEP-1735 Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no> |
||
---|---|---|
.. | ||
hci_driver.c | ||
hci_internal.h | ||
hci.c | ||
Makefile |