Commit Graph
306 Commits
Author SHA1 Message Date
Zhang Hai Peng a817312106 fix(ble/bluedroid): preserve ext adv state when set params fails
Only update extend_adv_cb after HCI Set Extended Advertising
Parameters succeeds, so a failed update does not corrupt cached
legacy_pdu and related fields used by adv data validation.


(cherry picked from commit 31bd80fee8)

Co-authored-by: zhanghaipeng <zhanghaipeng@espressif.com>
2026-07-14 10:37:08 +08:00
Island 416cd10dd5 Merge branch 'bugfix/fix_bluedroid_static_random_conn_rpa_v5.4' into 'release/v5.4'
fix(ble/bluedroid): skip identity conversion for static random direct connect (5.4)

See merge request espressif/esp-idf!50083
2026-06-30 10:24:53 +08:00
Zhi Wei Jian 1b340fe82b feat(ble/bluedroid): add CS Security Requirements host support (Core 6.3)
(cherry picked from commit 919622c01c)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-06-26 20:37:44 +08:00
Zhi Wei Jian aed8603a42 feat(ble/bluedroid): add LE UTP host support (Core 6.2)
(cherry picked from commit 3844e24207)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-06-26 20:37:44 +08:00
Zhi Wei JianandCursor 661e297e87 feat(ble/bluedroid): add Shorter Connection Intervals host support (Core 6.2)
Co-authored-by: Cursor <cursoragent@cursor.com>


(cherry picked from commit 2a8a96d650)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-06-26 20:37:44 +08:00
Zhi Wei Jian c72a639097 feat(ble/bluedroid): add LL Extended Feature Set host support (Core 6.0)
(cherry picked from commit d568f2f151)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-06-26 20:37:44 +08:00
Zhi Wei JianandCursor 4812d74f48 feat(ble/bluedroid): add Frame Space Update host support (Core 6.0)
Co-authored-by: Cursor <cursoragent@cursor.com>


(cherry picked from commit 5372ce03a3)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-06-26 20:37:44 +08:00
Zhi Wei Jian 5cff20ac8f feat(ble/bluedroid): add DBAF host support (Core 6.0)
(cherry picked from commit e20d3f0197)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-06-26 20:37:44 +08:00
Zhang Hai Peng ae071465e5 fix(ble/bluedroid): preserve HCI status on BLE 4.2 GAP failures
Return BTM_HCI_ERROR | hci_status from legacy BLE 4.2 GAP HCI command
paths instead of mapping failures to BTM_ILLEGAL_VALUE or
BTM_NO_RESOURCES. Add btm_ble_status_from_hci() helper and propagate
real status through scan start/stop completion callbacks.


(cherry picked from commit 47dd785a18)

Co-authored-by: zhanghaipeng <zhanghaipeng@espressif.com>
2026-06-26 20:24:48 +08:00
Zhang Hai Peng 6d33df6d6b feat(ble/bluedroid): Optimize Bluedroid memory usage
- Delete unused device records (~356B each)


(cherry picked from commit 7d1c0e9a32)

Co-authored-by: zhanghaipeng <zhanghaipeng@espressif.com>
2026-06-26 20:24:27 +08:00
Zhang Hai Peng 865a25c05a fix(ble/bluedroid): reject adv data on legacy directed ext adv
(cherry picked from commit c339cec380)

Co-authored-by: zhanghaipeng <zhanghaipeng@espressif.com>
2026-06-26 20:15:47 +08:00
Zhang Hai Peng 68e37183f1 feat(ble/bluedroid): Add BLE SMP support for multi-ADV with static random addresses
(cherry picked from commit 7986e2faa8)

Co-authored-by: zhanghaipeng <zhanghaipeng@espressif.com>
2026-06-18 10:24:49 +08:00
Zhi Wei Jian beca97bcae fix(ble/bluedroid): fix GAP BLE API parameter validation
(cherry picked from commit e3311c81c4)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-06-10 19:53:47 +08:00
Island 3ff613a06c Merge branch 'bugfix/fix_ble_read_remote_feature_timeout_v5.4' into 'release/v5.4'
Fixed read remote feature timeout when using coded phy(2f683593) (5.4)

See merge request espressif/esp-idf!48062
2026-05-12 18:01:40 +08:00
zhanghaipeng aefcf1c2ee fix(ble): Optimize connection interval minimum parameter check 2026-05-11 11:20:14 +08:00
Jin Cheng 945277cbc6 fix(bt/bluedroid): fixed the vulerabilities from AI code review in Bluedroid 2026-05-11 09:42:17 +08:00
Jin Cheng cb05dc0b3f fix(bt/bluedroid): fixed multiple high-severity issues from AI code review in Bluedroid 2026-05-11 09:42:17 +08:00
Wang Meng Yang 7ea2ed1778 Merge branch 'bugfix/btm_sec_free_dev_v5.4' into 'release/v5.4'
fix(bt): avoid deleting device record on partial transport cleanup (v5.4)

See merge request espressif/esp-idf!47296
2026-04-20 09:35:02 +08:00
Island aee5245e2d Merge branch 'bugfix/fix_some_bluedroid_bugs_260121_v5.4' into 'release/v5.4'
Bugfix/fix some bluedroid bugs 260121 (5.4)

See merge request espressif/esp-idf!46982
2026-04-17 18:11:09 +08:00
yangfeng de7c3d5e73 fix(bt): avoid deleting device record on partial transport cleanup 2026-04-07 11:55:13 +08:00
zhiweijian 1ced86789b fix(ble/bluedroid): Fixed privacy callback triggering multiple times 2026-04-03 14:07:23 +08:00
zhiweijian d2892e882a fix(ble/bluedroid): Fixed bluedrodi CI build error 2026-03-31 14:32:34 +08:00
zhiweijian 0bd4c9a5ad fix(ble/bluedroid): optimize bluedroid host and fix GAP, memory, status and BTM API issues
- return HCI_ERR_MEMORY_FULL on cmd buffer alloc failure
- remove legacy adv/scan semaphores and mutex
- Use the same legacy gap callback instead of each independent legacy gap event callback
2026-03-30 10:49:26 +08:00
Zhi Wei Jian f6e48dd5d7 feat(ble/bluedroid): support adv monitor feature
(cherry picked from commit 1566a50929)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-03-26 17:23:44 +08:00
Zhi Wei Jian c03a27565c fix(ble/bluedroid): BLE GAP/ACL/ISO/SCO null checks, evt_len and resource handling
- btm_acl: malloc/list_append failure handling, remove/memset order in btm_acl_removed
- btm_ble: remove incorrect sec_flags in SMP_OOB/NC/SC_OOB fall-through
- btm_ble_5_gap: btm_ble_hci_status_to_str unreachable return,
  BTM_BleSetExtendedAdvParams/BleStartExtAdv leak and bounds
- btm_ble_addr: fix indent in btm_find_dev_by_identity_addr
- btm_ble_gap: null check p_service_data, pass evt_len to btm_ble_process_adv_pkt,
  bounds in process_adv_pkt
- btm_ble_iso: align param types with declaration
- btm_ble_privacy: handle BTM_BLE_IRK_LIST_INVALID_INDEX in update_resolving_list,
  comment fixes
- btm_devctl: fix btm_vsc_complete param order/type
- btm_sco: add evt_len to btm_sco_process_num_completed_pkts for bounds check
- btm_ble_int.h/btm_int.h: add evt_len to process_adv_pkt and
  process_num_completed_pkts declarations


(cherry picked from commit 65b2cb2728)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-03-25 13:58:36 +08:00
Zhi Wei Jian 9cebea1dba fix(ble/bluedroid): fix GAP, advertising and security issues in BTM layer
- Fix adv state restore and reset if start/stop failed
- Fix periodic adv v2 event without PAWR feature enabled
- Fix periodic adv sync establish skip handling
- Fix resolving list max_size validation
- Fix RPA addr_type update after host-side resolution
- Fix pairing_state reset if p_dev_rec alloc failed
- Fix ISO cis_cnt limit and ext adv parameter check
- Try to delete smp keys even if not in device list



(cherry picked from commit e0ccc644a8)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-03-25 10:27:34 +08:00
yangfeng 23a7b191ca feat(bt): Add APIs to control transmit power level
- API to read ACL real RSSI
- APIs to read/write tx power of inq/iscan/page/pscan/ACL
2026-03-16 15:45:51 +08:00
chenjianhua f35659e032 feat(ble/bluedroid): Add an API to resolve RPA 2026-03-11 20:11:24 +08:00
zhiweijian dd35a4eaef feat(ble/bluedroid): Add new bluedroid host examples 2026-01-30 20:14:59 +08:00
zhanghaipeng 01fc843a33 feat(ble/bluedroid): add periodic advertising create sync retry mechanism 2026-01-09 14:11:17 +08:00
Zhi Wei Jian 5026daf6c3 fix(ble/bluedroid): Fixed bluedroid host get white list size error
(cherry picked from commit f4dfd42725)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:15 +08:00
Zhi Wei Jian f59bff13ee fix(ble/bluedroid): Fixed bt buuld error
fix(ble/bluedroid): disable power management if bt is disabled


(cherry picked from commit 6f27074c1e)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:15 +08:00
Zhi Wei Jian 1b29279016 fix(ble/bluedroid): optimize bluedroid host code
(cherry picked from commit 3b18da2bde)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:14 +08:00
Zhi Wei Jian d80ad53deb fix(ble/bluedroid): Add BLE_TOPOLOGY_CHECK
(cherry picked from commit 728c4c8a10)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:13 +08:00
Zhi Wei Jian a9efe24334 fix(ble/bluedroid): disable bluedroid background connection
(cherry picked from commit 1f5fa1e72b)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:13 +08:00
Zhi Wei Jian 42a266c01b fix(ble/bluedroid): change tGATT_BG_CONN_DEV to GATT_BG_CONN_DEV
(cherry picked from commit ac7812ef8d)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:12 +08:00
Zhi Wei Jian 4ba19e25d8 fix(ble/bluedroid): disable exception list if scan is not enabled
(cherry picked from commit ec6809611a)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:12 +08:00
Zhi Wei Jian ac58ccf453 fix(ble/bluedroid): disable vendor hci function
(cherry picked from commit 715184fa36)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:12 +08:00
Zhi Wei Jian cf53406f18 fix(ble/bluedroid): Delete btm_ble_send_extended_scan_params
(cherry picked from commit 1174ad41a5)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:11 +08:00
Zhi Wei Jian 4ff844477c fix(ble/bluedroid): change bluedroid scan callback name
(cherry picked from commit b9440efbe9)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:11 +08:00
Zhi Wei Jian 30c6a3e92e fix(bluedroid): delete bluedroid gatt_listen
(cherry picked from commit db17c7cea3)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:10 +08:00
Zhi Wei Jian d56d60633c fix(ble/bluedroid): Delete observe and inquiry
(cherry picked from commit 34448a7455)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:10 +08:00
Zhi Wei Jian a68fcdeb3c fix(ble/bluedroid): delete bluedroid unused code
(cherry picked from commit 5145b366f7)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:09 +08:00
Zhi Wei Jian a4bf740553 fix(ble/bluedroid): Delete BLE_HOST_READ_TX_POWER_EN
(cherry picked from commit 1c0c48b814)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:07 +08:00
Zhi Wei Jian a187a51067 fix(ble/bluedroid): Delete BLE_HOST_ENABLE_TEST_MODE_EN
(cherry picked from commit f08ff1448b)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:06 +08:00
Zhi Wei Jian 223db5fec2 fix(ble/bluedroid): delete BLE_HOST_ENERGY_INFO_EN
(cherry picked from commit b4c4b3e410)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:05 +08:00
Zhi Wei Jian 221ab95dae fix(ble/bluedroid): Delete BLE_VND_INCLUDED
(cherry picked from commit 57c52bd4ec)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:05 +08:00
Zhi Wei Jian 07a919918c fix(ble/bluedroid): Delete BLE_ANDROID_CONTROLLER_SCAN_FILTER
(cherry picked from commit 702292d451)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:04 +08:00
Zhi Wei Jian 534e505ff6 fix(ble/bluedroid): Delete BLE_HOST_BLE_SCAN_PARAM_UNUSED
(cherry picked from commit 5fdcc3bdea)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:03 +08:00
Zhi Wei Jian f590e7c58d fix(ble/bluedroid): Delete BLE_HOST_CONN_SCAN_PARAM_EN
(cherry picked from commit b175f3cc97)

Co-authored-by: zhiweijian <zhiweijian@espressif.com>
2026-01-07 17:24:03 +08:00