Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[nrf fromlist] Bluetooth: ATT: lock scheduler when sending from user …
…thread `att_req_send_process` is not thread safe. In the case where the current context is pre-emptible (e.g. when a user sends something over GATT from the main thread): The iterator in `att_req_send_process` can get interrupted mid-processing, breaking the logic and resulting in an assert/crash/data corruption. Additionally, the connection state check in this fn is also not thread-safe, the RX thread could pre-empt us and disconnect right before we attempt to send on an ATT bearer that is on it. This is a hotfix until we have a generalized solution for the host API surface. It seems a lot of our logic assumes cooperative priority. Upstream PR: zephyrproject-rtos/zephyr#69738 Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
- Loading branch information