zephyrproject-rtos / zephyr

Primary Git Repository for the Zephyr Project. Zephyr is a new generation, scalable, optimized, secure RTOS for multiple hardware architectures.
https://docs.zephyrproject.org
Apache License 2.0
10.84k stars 6.6k forks source link

Bluetooth: Extended adv reports with legacy data should also be discardable #51650

Closed martintv closed 2 years ago

martintv commented 2 years ago

Describe the bug For the same reason legacy adv reports are discaradble, extended adv reports with just legacy data should also be

To Reproduce I haven't proved that this is a issue by testing it

Expected behavior No deadlocks should happen because the adv reports cloggs up the rx thread.

Impact For me this is just an annoyance, because I have worked around it.

Logs and console output N/A

Environment (please complete the following information): N/A

Additional context I made this draft PR to show how I think it should be fixed https://github.com/zephyrproject-rtos/zephyr/pull/51649 But the fix needs to be applied more places before merging.. I think all these places: drivers/bluetooth/hci/h4.c:167: (rx.hdr[sizeof(*hdr)] == BT_HCI_EVT_LE_ADVERTISING_REPORT)) { drivers/bluetooth/hci/hci_b91.c:38: case BT_HCI_EVT_LE_ADVERTISING_REPORT: drivers/bluetooth/hci/spi.c:343: (rxmsg[3] == BT_HCI_EVT_LE_ADVERTISING_REPORT)) { drivers/bluetooth/hci/ipm_stm32wb.c:188: (mev->subevent == BT_HCI_EVT_LE_ADVERTISING_REPORT)) { drivers/bluetooth/hci/userchan.c:67: (buf[3] == BT_HCI_EVT_LE_ADVERTISING_REPORT)) { drivers/bluetooth/hci/rpmsg.c:46: case BT_HCI_EVT_LE_ADVERTISING_REPORT:

laurenmurphyx64 commented 2 years ago

Closed assuming https://github.com/zephyrproject-rtos/zephyr/pull/51649 fixed, please re-open if this is still an issue