Merge branch 'bugfix/handle_buffers_for_ext_adv_rpt_v5.0' into 'release/v5.0'

Nimble: Allocate memory for ext adv reports from lower priority pool. (v5.0)

See merge request espressif/esp-idf!20730
This commit is contained in:
Jiang Jiang Jian
2022-10-25 16:48:20 +08:00

View File

@ -350,7 +350,8 @@ static int host_rcv_pkt(uint8_t *data, uint16_t len)
}
/* Allocate LE Advertising Report Event from lo pool only */
if ((data[1] == BLE_HCI_EVCODE_LE_META) && (data[3] == BLE_HCI_LE_SUBEV_ADV_RPT)) {
if ((data[1] == BLE_HCI_EVCODE_LE_META) &&
(data[3] == BLE_HCI_LE_SUBEV_ADV_RPT || data[3] == BLE_HCI_LE_SUBEV_EXT_ADV_RPT)) {
evbuf = ble_hci_trans_buf_alloc(BLE_HCI_TRANS_BUF_EVT_LO);
/* Skip advertising report if we're out of memory */
if (!evbuf) {