10660 Commits

Author SHA1 Message Date
Jens Gutermuth
457b71f1a3 improve thread safety in esp_timer
Inadequate locking in the esp_timer component allowed corruption
of the s_timers linked list:

1. timer_armed(timer) returns false
2. another task arms the timer and adds it to s_timers
3. the list is locked
4. the timer is inserted into s_timers again

The last step results in a loop in the s_timers list, which causes
an infinite loop when iterated. This change always locks the
list before checking if the timer is already armed avoiding
the data race.
2023-05-18 15:41:53 +08:00
Jiang Jiang Jian
c28f5a5cd2 Merge branch 'bugfix/fix_esp32_bugs_230511_v4.2' into 'release/v4.2'
Fixed some esp32 bugs(backport v4.2)

See merge request espressif/esp-idf!23706
2023-05-17 17:08:44 +08:00
zhiweijian
b9d062ef16 Fixed BLE disconnection failure on ESP32 2023-05-11 20:26:39 +08:00
zwj
0b8b26ec49 Fixed disconnection due to consecutive CRC errors in first 6 intervals 2023-05-11 20:26:29 +08:00
zhiweijian
f563a1e3cc Fixed battery profile wrong condition 2023-05-11 20:25:57 +08:00
Marius Vikhammer
6a3bd9e22b rom: fix newlib time ROM functions being regardless of CONFIG_SPIRAM_CACHE_WORKAROUND
On ESP32 ROM functions are not compatible with CONFIG_SPIRAM_CACHE_WORKAROUND.
This were handled correctly in cmake, but not in make.
2023-05-11 07:22:33 +00:00
xiongweichao
1b459301d6 bt: Fixed the inconsistency between the indicator event received by the HF application layer and the actually received indicator.
Closes https://github.com/espressif/esp-idf/issues/6486
2023-05-04 14:24:42 +08:00
Jiang Jiang Jian
4a52b7845c Merge branch 'bugfix/bt_diable_enbale_crash_v4.2' into 'release/v4.2'
bt:Fixed esp32 controller bug (v4.2)

See merge request espressif/esp-idf!23176
2023-04-24 11:03:08 +08:00
zwj
45a3c35d65 Fixed duplicate scan refresh cycle is not accurate after restarting scan on ESP32 2023-04-23 12:21:20 +00:00
xiongweichao
873856fdf3 bt: added coex adapter operation to get version of coexist module to ESP32 Bluetooth Controller 2023-04-23 12:21:20 +00:00
xiongweichao
37aa555611 bt:Fixed esp32 controller bug
1. Fixed crash after controller disable and re-enable
2. Fixed the crash caused by processing the HCI_Read_Remote_Extented_Features command in the non-connected state
3. Fixed disconnection due to not handling lmp_unsniff_req in LC_WAIT_SNIFF_SUB_RSP state
4. Fixed crash caused by supervision timeout greater than sniff interval

Closes https://github.com/espressif/esp-idf/issues/11164
Closes https://github.com/espressif/esp-idf/issues/10835
2023-04-23 12:21:20 +00:00
chenjianhua
93360655cf bluedroid: report status after clearing the BLE white list 2023-04-21 16:01:09 +08:00
chenjianhua
b242e0e602 bluedroid: fix GATTC cache address save 2023-04-21 15:58:11 +08:00
chenjianhua
1d7317b401 bluedroid: fix adv and scan state conflict 2023-04-21 15:57:58 +08:00
chenjianhua
564c4b644d bluedroid: support get bluetooth device name 2023-04-21 15:57:41 +08:00
liuning
cebf0acaee esp_wifi: fix failed to sleep after scan, coex: fix wifi connecting interrupted by ble 2023-04-14 18:53:13 +08:00
zhangyanjiao
a7ba067c2e wifi_mesh: update mesh doc 2023-04-10 17:21:51 +08:00
zhangyanjiao
a42b845cab esp_wifi:
1. wifi_mesh: fix the heap corrupt issue in MTXON task
2. wifi_mesh: Fix several bugs on mesh network
2023-04-10 17:20:59 +08:00
zhiweijian
3a7dd3c0de Fixed vulnerability attacks that could cause heap overflow in fragmented Blufi packet processing 2023-04-04 15:42:34 +08:00
Jiang Jiang Jian
9dfbf27857 Merge branch 'bugfix/fix_some_ble_bugs_for_4.2' into 'release/v4.2'
Bluedroid: fix some ble bugs (backport 4.2)

See merge request espressif/esp-idf!22704
2023-03-20 14:02:59 +08:00
Jiang Jiang Jian
8e8ef2b469 Merge branch 'bugfix/close_rf_in_deep_sleep_backport_v4.2' into 'release/v4.2'
deep sleep: further optimize sleep current if RF is enabled (backport v4.2)

See merge request espressif/esp-idf!22735
2023-03-20 14:02:17 +08:00
Jiang Jiang Jian
03ad2abdee Merge branch 'feature/esp32_ulp_allow_8kb_v4.2' into 'release/v4.2'
esp32: allow up to 8 kB of ULP program size (v4.2)

See merge request espressif/esp-idf!22707
2023-03-20 14:00:59 +08:00
wuzhenghui
b158a891fe deep sleep: close rf to optimize sleep current 2023-03-19 18:37:58 +08:00
wuzhenghui
0270f9d435 Revert "deep sleep: optimize sleep current in wifi softap mode"
This reverts commit f16e8cb48ea5895d2ca0a4ad5d13f706716ef595.
2023-03-17 12:06:55 +08:00
Ivan Grokhotkov
3ccd1ae6e2 esp32: allow up to 8 kB of ULP program size
The remaining 4 kB had been reserved for storing RF calibration and
BT stack state since 4e092be6. However, these features never got
implemented. If we ever need to place RF related data into RTC slow
memory, we can do this by creating a variable with RTC_NOINIT_ATTR
instead.

https://github.com/espressif/esp-idf/issues/6515
2023-03-10 18:08:14 +08:00
chenjianhua
c912fcba45 fix ble adv tx power map 2023-03-10 17:15:24 +08:00
chenjianhua
c5dc8389ed bluedroid: fix ble rpa generate and update by host 2023-03-10 17:15:24 +08:00
chenjianhua
763143a89a fix esp hid crash when auth failed 2023-03-10 17:15:24 +08:00
Jakob Hasse
3705e39db9 refactor(nvs): custom allocator for all objects allocated in NVS 2023-03-04 14:07:10 +00:00
Darian Leung
f3a8a911c0 twai: Add errata workaround for listen only mode
This commit adds a workaround for the TWAI listen only mode errata which is
present on the ESP32, ESP32-S2, ESP32-S3, and ESP32-C3. twai_get_status_info()
has also been updated to account for the fact that TEC/REC are frozen in
listen only mode.

Errata Description:

When the TWAI controller is put into listen only mode, it should not influence
the TWAI bus in any way (i.e., should never send a dominant bit). However,
on the targets listed above, the TWAI controller will send dominant bits in an
error frame (i.e., active error frame), even if the controller is set to listen
only mode.

Workaround:

We can force the TWAI controller into the error passive state on startup (by
setting the REC to >= 128). Since the TEC/REC are frozen in listen only mode,
the TWAI controller will remain error passive and only send recessive bits
(i.e., passive error frames), thus will not influence the TWAI bus.

Closes https://github.com/espressif/esp-idf/issues/9157
2023-02-24 20:38:37 +08:00
Jin Cheng
c25d227280 Fixed build errors when sniff subrating is enabled. 2023-02-16 15:25:41 +08:00
Sarvesh Bodakhe
3bc7626603 esp_wifi: Update wifi libs
Update wifi libs with below changes -
1. reject AP when assoc comeback time given is greater than 5 seconds
2023-01-11 14:39:24 +05:30
Shyamal Khachane
a858328f3b wpa_supplicant: Set PMK from PMKSA incase of caching 2023-01-09 10:22:15 +05:30
Shyamal Khachane
7d70759991 esp_wifi: Fix open auth issue after commit message exchange 2023-01-09 10:22:15 +05:30
Jiang Jiang Jian
8da3f6ec7f Merge branch 'bugfix/fix_softap_beacon_memory_leak_issue_v4.2' into 'release/v4.2'
esp_wifi: fix softap beacon memory leak issue(Backport v4.2)

See merge request espressif/esp-idf!21813
2023-01-06 12:03:53 +08:00
muhaidong
d6722f1ae1 esp_wifi: fix softap beacon memory leak issue
1. fix softap beacon memory leak issue.
2. fix esp wifi sta get ap info does not return connected ssid issue.
3. update inactive timer when recv ps-poll or success send data.
2022-12-27 19:34:13 +08:00
Kapil Gupta
a519f63740 esp_wifi: Add changes to skip SAE handshake during WPS connection 2022-12-27 15:33:33 +05:30
Kapil Gupta
81a0c6a27d esp_wifi: Flush PMK caching if bss akm has changed 2022-12-27 15:32:46 +05:30
Kapil Gupta
4a5f26d7fc Correct SSID copy length during WPS scan 2022-12-27 15:32:35 +05:30
Jiang Jiang Jian
c135695a18 Merge branch 'bugfix/fix_ble_some_bugs_20221219_v4.2' into 'release/v4.2'
backport some BLE bugs 20221219 (backport v4.2)

See merge request espressif/esp-idf!21720
2022-12-21 12:00:08 +08:00
Jiang Jiang Jian
7c9bdca900 Merge branch 'bugfix/spp_vfs_memory_leak_v4.2' into 'release/v4.2'
Component_bt/fix esp_spp_vfs_register memory leak(v4.2)

See merge request espressif/esp-idf!21717
2022-12-21 11:59:58 +08:00
zwj
18d0ba010d Update bt lib for ESP32
- Add config to set duplicate scan list refresh period
- overwrite the oldest device infor if the list is full
- Fixed duplicate scan period is not accurate
- Change default TX power to 9 dBm
- Fixed disconnect reason 0x1f (unspecified error)
- Fixed connection timeout due to terminate ind has not been acknowledged
- Fixed some memory was not released after bluetooth controller initialization failed on ESP32
2022-12-20 17:21:21 +08:00
xiongweichao
7f371f7864 bt: Fixed repeated register of vfs_id causing memory leaks 2022-12-20 15:13:44 +08:00
xiongweichao
1d43c9103c Assert when malloc user_data fail 2022-12-20 15:13:25 +08:00
xiongweichao
41d064578f Fixed memory leak when SPP initialization failed 2022-12-20 15:12:48 +08:00
chenjianhua
2fd6fa2773 bluedroid: fix ble connection update with same params 2022-12-19 20:05:50 +08:00
chenjianhua
310be0d052 bluedroid: fix encrypt keysize of GATT characteristic permission 2022-12-19 20:05:50 +08:00
chenjianhua
b24bc2482b bluedroid: correct the length of att read by type pdu 2022-12-19 20:05:50 +08:00
Jiang Jiang Jian
698aae95cf Merge branch 'contrib/github_pr_9529_v4.2' into 'release/v4.2'
component_bt: Fixed memory leak due to not freeing memory if posting a message to a thread fails(v4.2)

See merge request espressif/esp-idf!21474
2022-12-13 13:56:24 +08:00
morris
083483effc Merge branch 'bugfix/fix_slave_gpio_cs_mixed_with_iomux_bus_v4.2' into 'release/v4.2'
spi_slave: fix slave can't use iomux bus mixed with gpio cs_pin (v4.2)

See merge request espressif/esp-idf!21379
2022-12-12 15:50:41 +08:00