Commit Graph

975 Commits

Author SHA1 Message Date
liuning
f7d005bd34 fix(wifi): fix disconnected abnormal sleep 2023-12-06 11:32:02 +08:00
Jiang Jiang Jian
6da710df94 Merge branch 'bugfix/fix_psram_enabled_psram_initialized_fail_issue' into 'master'
fix(wifi): fix psram enabled but initialized fail issue

Closes IDFGH-10755

See merge request espressif/esp-idf!27218
2023-12-05 19:12:12 +08:00
Darian
e3191df37a Merge branch 'change/deprecate_legacy_xtensa_include_path' into 'master'
change(xtensa): Deprecate legacy include paths

Closes IDF-7230

See merge request espressif/esp-idf!26725
2023-12-05 15:05:29 +08:00
muhaidong
f37448cddb fix(wifi): fix psram enabled but initialized fail issue
Closes https://github.com/espressif/esp-idf/issues/11971
2023-12-05 11:19:59 +08:00
zhangyanjiao
550f858c0f fix(wifi/mesh): fix connection and opmoode error in mesh
1. fix the bug that station can't found AP when the authmode is WPA
2. fix wifi mode error when mesh start after station has connected to router

Closes https://github.com/espressif/esp-idf/issues/12646
2023-12-01 12:03:06 +08:00
Darian Leung
2204c8e137 change(xtensa): Deprecate ".../xtensa_api.h" include path
This commit deprecates the "freertos/xtensa_api.h" and "xtensa/xtensa_api.h"
include paths. Users should use "xtensa_api.h" instead.

- Replace legacy include paths
- Removed some unnecessary includes of "xtensa_api.h"
- Replaced some calls with "esp_cpu_..." equivalents
- Add warning to compatibility header
2023-11-30 21:58:52 +08:00
aditi_lonkar
bdeec024e8 fix(esp_wifi):Fix WDT when esp_supp_dpp_start_listen called multiple times 2023-11-30 15:37:17 +05:30
zhangyanjiao
b495f54329 fix(wifi): fix the crash issue when clear scan ap list 2023-11-29 19:23:35 +08:00
zhangyanjiao
0f18104d53 feat(wifi): add new api to get one scan ap record 2023-11-29 19:19:25 +08:00
Jiang Jiang Jian
145d40a120 Merge branch 'bugfix/fix_wifi_deinit_s_wifi_modem_sleep_lock' into 'master'
fix(wifi): fix wifi deinit s_wifi_modem_sleep_lock

See merge request espressif/esp-idf!27450
2023-11-29 12:15:51 +08:00
liuning
2366bab75f fix(wifi): fix wifi deinit s_wifi_modem_sleep_lock 2023-11-28 20:56:37 +08:00
Shyamal Khachane
d7db8e08e5 fix(esp_wifi): Fix issues with NAN datapath
1. Avoid possible crash scenarios while forming datapath
2. Modify peer records structure thus fixing issues in datapath establishment
3. Fix timer out of bound issue causing "No timer handle" warning
4. Fix miscellaneous service discovery and datapath issues
2023-11-28 10:24:52 +05:30
Shyamal Khachane
05896af6bd fix(esp_wifi): Fix crash while cancelling NAN service 2023-11-24 04:15:39 +00:00
Jiang Jiang Jian
5d3c1bb8ef Merge branch 'bugfix/fix_wifi_init_reentrant_issue' into 'master'
fix(wifi): fix wifi init reentrant issue

Closes WIFIBUG-242

See merge request espressif/esp-idf!26718
2023-11-23 10:57:28 +08:00
liuning
b47bf9e742 fix(wifi): fix wifi init reentrant issue 2023-11-22 17:39:56 +08:00
jgujarathi
b47b75f6c8 fix(esp_wifi): Expand situations for REASON_NO_AP_FOUND_WITH_COMPATIBLE_SECURITY
- Fixes issue with connecting and discovering WEP APs
- Expsnds the reasons for trigerring a disconnect using
REASON_NO_AP_FOUND_WITH_COMPATIBLE_SECURITY
-- SAE-PK configured as compulsory in sta config but disabled for the AP
-- SAE-H2e configured as compulsory in sta config but disabled for an AP
that has authmode as WPA3-PSK or WPA3-WPA2-PSK.
-- Open AP found but we have set password or enabled enterprise mode.
-- SAE H2E only ap but we have SAE HnP setup in config.
-- WPA3-EXT_PSK AP but SAE-H2E disabled in config
2023-11-22 11:29:30 +05:30
muhaidong
147463a0ac fix(wifi): allow some special igtk keyindx to workaround faulty APs 2023-11-16 20:20:08 +08:00
ding huan
5fe34d7ed1 fix(conn): Change second connect delay time to 730 2023-11-16 10:51:01 +08:00
Sarvesh Bodakhe
b42e14c9b7 fix(wifi): fix bug in 'esp_wifi_deauthenticate_internal' and other improvements 2023-11-15 08:27:50 +05:30
zhangyanjiao
1b5fb22da8 feat(wifi/vendor): get more wifi information in csi rx callback 2023-11-13 16:08:45 +08:00
zhangyanjiao
6d4e41f992 doc(Wi-Fi/Vendor): Update comments for wifi_csi_info_t 2023-11-13 16:08:45 +08:00
xueyunfei
9df662703b Fix(esp_wifi): Add the missing header file to the wifi header files. 2023-11-13 16:08:45 +08:00
jgujarathi
47e8de1d4d fix(esp_wifi): Add more descriptive reasons for disconnect
Adds 3 more ddisconnect reasons in case of No AP found.
1. REASON_NO_AP_FOUND_IN_RSSI_THRESHOLD : AP rejected because it did
   not meet rssi threshold.

2. REASON_NO_AP_FOUND_IN_AUTHMODE THRESHOLD : AP rejected because it
   did not meet security threshold.

3. REASON_NO_AP_FOUND_WITH_COMPATIBLE_ SECURITY : AP rejected because
   of incompatible security configuration. These situations could include
   -- bss offerring WEP, but our password is not WEP compliant,
   -- Encrypted AP bss but we have no password config set.
   -- AP is Enterprise but we have not setup enterprise config and vice versa

    Closes https://github.com/espressif/esp-idf/issues/5957
2023-11-13 14:22:59 +08:00
muhaidong
407ff67128 fix(wifi): sta not pmf capable when ap requires should reject profile 2023-11-08 19:12:37 +08:00
zhangyanjiao
7cd1115815 fix(wifi/mesh): fix the IE crypto disable error and update doc 2023-11-08 10:24:45 +08:00
muhaidong
deed5684ce change(wifi): update esp_coexist_internal.h and esp_modem_wrapper.h 2023-11-06 21:55:33 +08:00
muhaidong
3e98a7be6e docs(esp_mesh): update esp_mesh_internal.h 2023-11-06 21:55:21 +08:00
muhaidong
0851c7135d update(wifi): update esp_wifi_crypto_types.h 2023-11-06 21:55:11 +08:00
muhaidong
dea39f359e update(esp_coexist): update esp coexist header file 2023-11-06 21:54:59 +08:00
zhangyanjiao
9cab732a29 fix(wifi): fix rate check error in fragment 2023-11-06 11:09:44 +08:00
xuxiao
5c3a7ec88a fix(wifi): fix esp32c6 rxctrl info is not correct 2023-11-03 13:55:45 +08:00
alanmaxwell
8a47c4875b fix(wifi): optimize wifi bin size and fix some issue
1.Optimize bin size for STA only mode
2.Change fragment threshold to 256
3.Support fragment for LR mode
4.Fix ampdu duration issue
5.Fix rx fragment fail in Open mode.
2023-11-02 14:05:45 +08:00
Kapil Gupta
4dd480ce83 fix(esp_wifi): Fix key install issue in PTK renew 2023-11-01 13:39:50 +05:30
Shreyas Sheth
8b8d4a0ffc fix(wifi): wpa3 softap fix deauth when assoc req recv before sae is finished 2023-10-31 06:13:49 +00:00
Sarvesh Bodakhe
0a95914839 fix(esp_wifi): Fix issue of station disconnecting immediately when AP RSSI is zero 2023-10-27 09:35:20 +05:30
alanmaxwell
4d33bf7ee9 feat(wifi): support esp32c3 v1.1 WiFi
1.bringup c3 v1.1 and sync func to c3 eco7 rom
2.support to set null&probe lifetime
3.support to adjust listen interval to dtim period
4.support tx pkt w/o wake null
5.allow to tx null0 if requtest to rx data
2023-10-20 11:01:07 +08:00
Jiang Jiang Jian
6db16c6e81 Merge branch 'feature/sta_sae_ext_key' into 'master'
feat(wifi): Add support for sae ext key for station

Closes WIFI-6170

See merge request espressif/esp-idf!24833
2023-10-19 18:49:15 +08:00
Zim Kalinowski
fa1a3ce0b5 Merge branch 'refactor/components_linux_compatible' into 'master'
Exclude all currently incompatible components from Linux build

Closes IDF-8318 and IDF-5996

See merge request espressif/esp-idf!25598
2023-10-18 20:17:49 +08:00
Shreyas Sheth
ee9ce51133 feat(wifi): Add SAE EXT key support for esp station 2023-10-18 17:10:31 +05:30
jgujarathi
6ddeba878c fix(esp_wifi): Fixes issues in beacon_timeout, PMKSA and AID assignment
- Fixes issue wheere beacon timeout would get triggerred multiple times
  leading to a m f probe req.

- Fix missing PMKSA flush scenarios.

- Fix wrong AID assigned to station when multiple stations try to connect
  simultaneously with mixed order of auth-request and assoc-request frames.
2023-10-17 15:35:14 +05:30
Jakob Hasse
548022fbe6 refactor(linux): excluded all non-Linux components from build
* All components which won't build (yet) on Linux are excluded.
  This enables switching to Linux in an application without
  explicitly setting COMPONENTS to main in the main
  CMakeLists.txt.
* ESP Timer provides headers for Linux now
* automatically disabling LWIP in Kconfig if it is not available

doc(linux): brought section
  "Component Linux/Mock Support Overview" up to date
2023-10-16 17:06:54 +08:00
liuning
516496b9d3 fix(pm): fix soc wakeup after wifi disconnected, station no respond after m f null, crash when connected to non_trans bssid 2023-10-13 18:14:54 +08:00
Niklas Kaaf
2d6dcee136 fix: "erro code" -> "error code" typos
Closes https://github.com/espressif/esp-idf/pull/12330
2023-10-13 18:13:54 +08:00
alanmaxwell
16ec59907e fix(wifi): Fix some wifi issue
1.fix multi antenna issue
2.fix dirty eb when rx HE rate action for C6
3.fix h/w modem state consecutive times when the modem sleep type is modified in runtime
2023-10-13 10:45:31 +08:00
CC
65054e1def esp_wifi.h typo
typo in esp_wifi_scan_get_ap_num comment
APIs -> APs
2023-10-11 13:52:08 +08:00
liuning
79a1cb38dd (fix)esp_wifi: wifi beacon timeout after connection established 2023-10-10 05:50:13 +00:00
muhaidong
d8b600e90b fix(wifi): fix some wifi issues
1. fix enable psram wapi dhcp fail issue
2. fix c6 esp_wifi_set_max_tx_power fail issue
3. fix wrong wifi mode connect crash issue
4. fix null data sequence number issue
2023-10-09 19:17:28 +08:00
alanmaxwell
99ac807418 fix(wifi): Support ESP32 PHY enabled not enter WiFi RX state by default 2023-09-26 16:23:58 +08:00
alanmaxwell
9e07fa9312 fix(phy): move phy tx power track to IDF 2023-09-26 16:23:58 +08:00
alanmaxwell
503299fb32 fix(phy): Fix PHY enabled enter WiFi RX state default 2023-09-26 16:23:58 +08:00
Chen Yudong
2e11919f70 fix(ci): change build-test-rules files folder 2023-09-20 19:17:06 +08:00
Zim Kalinowski
d9a9a4a17f Merge branch 'fix/test_app_trim_builds' into 'master'
fix(test_apps): Trim builds of component test apps

See merge request espressif/esp-idf!25789
2023-09-20 18:32:57 +08:00
Xu Xiao
b82a55d41b Merge branch 'bugfix/fix_some_esp32c6_wifi_bugs' into 'master'
fix(wifi): fix some esp32c6 wifi bugs

See merge request espressif/esp-idf!25968
2023-09-20 14:17:25 +08:00
xuxiao
cb4b798867 fix(wifi): fix some esp32c6 wifi bugs 2023-09-19 13:27:01 +08:00
Jiang Jiang Jian
ea8b5c28ea Merge branch 'bugfix/fix_wifi_fail_to_enter_lightsleep_when_disconnected_esp32c6' into 'master'
fix(sleep_modem): fix lightsleep failure if enable lightsleep at phy disabled

Closes WIFI-5725 and WIFI-6208

See merge request espressif/esp-idf!25902
2023-09-19 07:16:55 +08:00
Darian Leung
287bdc5e61 fix(test_apps): Trim builds of component test apps
Some component test apps do not use the "set(COMPONENTS main)" command in their
project level "CMakeLists.txt", thus leading to their builds pulling in all
ESP-IDF components.

This commit trims the build of multiple component test apps:

- Add "set(COMPONENTS main ...)" to project level "CMakeLists.txt"
- Add missing "PRIV_REQUIRES" in some "main" component "CMakeLists.txt"

Also removed repeated configuraiton options in legacy_i2c_driver/sdkconfig.ci.defaults
as they are already specified in legacy_i2c_driver/sdkconfig.defaults
2023-09-18 17:16:37 +08:00
Kapil Gupta
3b748a6cb7 Merge branch 'feature/rename_wpa2_ent_to_eap_client' into 'master'
WiFi: Rename WPA2 enterprise APIs to EAP Client.

See merge request espressif/esp-idf!25233
2023-09-18 16:16:54 +08:00
liuning
1314a9f8cf esp_wifi: support connectionless manually pwr mgmt 2023-09-18 13:16:54 +08:00
liuning
c6db306833 sleep_modem: split esp_wifi_internal_mac_sleep_configure, add lock for pm functions 2023-09-18 11:49:52 +08:00
xueyunfei
f0e5434dc1 feat(esp_wifi):static buf for management,control,qos null,null data rx packet 2023-09-15 14:55:57 +08:00
Kapil Gupta
3fa88a3536 change(wifi): Add dependency of group 19 for MbedTLS crypto 2023-09-14 18:02:22 +05:30
jgujarathi
906685898d fix(esp_wifi): Fix issues with extended caps IE, scan and HT40 mode
-Merges the addition of extended caps IE for assoc req, probe resp
 and beacons in a single place. This ensures that there are no
 duplicate Extended Caps IE in the frame. Moves the capability
 indication for BTM and HT20/40 from supplicant to wifi libs.

-Fix issue with frequent disconections when scanning for only a single
 channel.

-Prints error message and returns ESP_ERR_NOT_SUPPORTED in case
 esp32c2 tries to set bandwidth to HT40.
2023-09-14 10:19:27 +05:30
muhaidong
4b645ef85d fix(wifi): fix ccmp and gcmp PN became large issue 2023-09-13 16:23:10 +08:00
Jiang Jiang Jian
5933779f2d Merge branch 'feature/configurable_wpa2_ent' into 'master'
esp_wifi: Make enterprise support configurable to save binary size.

Closes WIFI-3597

See merge request espressif/esp-idf!24345
2023-09-13 10:17:44 +08:00
Shyamal Khachane
f2905d1388 fix(esp_wifi): WPA3 enterprise 192 bit fix and config modification
1. Added SOC caps dependency for enabling 192 bit security in wifi enterprise example
2. Fixed authmode in log and connected event for WPA3 enterprise 192 bit security
2023-09-12 10:43:17 +05:30
Shreyas Sheth
9b5bbb5bd7 fix(wifi): Fix sta connecting with wpa security in enterprise mode 2023-09-06 06:00:48 +00:00
Xu Xiao
8847eeec0c feat(wifi): optimize esp32c6 iperf performance 2023-09-04 14:34:54 +08:00
Shyamal Khachane
fb1037f032 fix(esp_wifi): Skip PMK cache usage if configured password is incorrect 2023-08-31 12:39:26 +00:00
ding huan
22697a2e37 ci(wifi): Test connect api at different phase 2023-08-30 10:31:02 +08:00
aditi_lonkar
c88e7106ec esp_wifi: Make enterprise support configurable to save binary size. 2023-08-25 11:00:54 +05:30
Shreyas Sheth
043b8b55a1 docs(wifi): Update wifi and wifi security documentation
1. Update documentation for WPA3 Enterprise and WPA3 Enterprise 192-bit
mode
2. Update documentation for WPA3 OWE and OWE transition mode
3. Update documentation related to SAE PK, SAE PWE and Transition Disable
4. Update documnetation for wifi connect API
5. Fix config paramter information for wifi scan start
6. Fix documentation related to scan threshold config setting
7. Replace ESP_ERR_WIFI_ARG error code as ESP_ERR_INVALID_ARG
8. Update documentation for 802.11R Fast transition
2023-08-21 12:29:11 +00:00
zhangyanjiao
e9e149fc88 fix(wifi): fix some bugs in LR and bandwidth
1. Fix the LR rate set fail for espnow and 80211 tx
2. Check phy bandwidth when setting espnow peer rate

Closes https://github.com/espressif/esp-idf/issues/11751
2023-08-17 17:55:57 +08:00
Nachiket Kukade
29e6603ba7 fix(wifi): Fix EAPOL Key TxDone callback implementation
Fix issues arising due to not distinguishing between M2 and M4
TxDone during 4-way handshake. Also fix EAPOL frame rate to lowest
possible rate.
2023-08-14 16:50:42 +05:30
muhaidong
b871eff7d7 fix(wifi): fix disassociation callback miss free key issue 2023-08-11 15:09:03 +08:00
Nachiket Kukade
fc3798f590 fix(wifi): Fix error propagation while initiating FTM 2023-08-03 16:59:28 +05:30
Shyamal Khachane
e986bda085 fix(esp_wifi): Fix some OWE issues
1. Allow flow of traffic after 4 way handshake is completed
2. Fix beacon timeout issue in transition mode
2023-08-03 09:41:43 +05:30
liuning
12b894fd5d fix(esp_wifi): fix no mac retention at wifi start 2023-08-02 21:33:41 +08:00
Kapil Gupta
2b18dd4899 fix(wifi): Prevent PMF config overwritten by tx_cb 2023-08-02 11:33:33 +00:00
xueyunfei
217226d3c9 Fix(esp_wifi):revert send wake up and sleep null between scaning 2023-08-01 20:27:22 +08:00
jgujarathi
cabb41d889 fix(esp_wifi) : Trigger null data frame TX before offchan channel switch.
Moves the location of null data frame TX to before channel switch during
offchannel action frame TX req.
2023-07-31 16:51:57 +05:30
zhangyanjiao
a33a78f73f fix(wifi): fix the RX error when softAP and ESP-NOW both encrypted 2023-07-26 10:32:01 +08:00
David Čermák
70951831c0 Merge branch 'bugfix/netif_default_sta_init' into 'master'
wifi: Fix default wifi-netif creation to assert if no event loop

Closes IDFGH-10321

See merge request espressif/esp-idf!24361
2023-07-21 21:56:37 +08:00
Shreyas Sheth
691eed15cc fix(wifi): Fix memory leak caused by assoc IE and retry timer 2023-07-20 10:13:25 +05:30
Shyamal Khachane
a9e6deb615 fix(esp_wifi): Discard commit frame received at confirmed state in SAE 2023-07-18 08:09:08 +05:30
Shreyas Sheth
88cbcf4696 fix(wifi): Bugfix ignore immediate assoc req received by AP
1) Ignore immediate assoc req received from the station while we are
processing the older one
2) Create station mutex (sta->lock) only for stations connecting with wpa3
security
3) Fix regression caused by 4cb4faa9
2023-07-15 13:53:51 +05:30
wuzhenghui
2b600df4ee fix(esp_pm): Constrains the minimum frequency of APB_MAX when the modem is working 2023-07-14 20:10:16 +08:00
Li Shuai
b84d811684 Wi-Fi/power save: fix the some mac issues of wifi power save
Some APs are configured to hide the SSID, the length field of the SSID element
in the Beacon frame is set to 0. This can cause incorrect parsing of the Beacon
by the Wi-Fi MAC hardware.

Some APs send two beacon frames with different BSSID in a TBTT cycle. After
correctly parsing the beacon of the associated AP, it continue to receive the
other beacon frame, which will cause the MAC to remain in a wait RX/TXING
state, blocking the Wi-Fi go to sleep.
2023-07-13 21:25:07 +08:00
xuxiao
4960c10664 feat(wifi): itwt support itwt wake duration unit 2023-07-13 11:15:17 +08:00
muhaidong
444760b9e6 feat(external coex): add set tx line flag api 2023-07-12 19:24:29 +08:00
zhangyanjiao
7ae5822f0e fix(wifi): Add bugfixes and improvements
1. Update wifi security mode
2. Add check for memory allocation in tx buffers
3. Fix association refused temporarily comeback time set to zero issue
2023-07-11 21:25:24 +08:00
david zuhn
3d8f7b3895 spelling correction in documentation
Signed-off-by: zhangyanjiao <zhangyanjiao@espressif.com>

Closes https://github.com/espressif/esp-idf/pull/9721
2023-07-11 14:33:44 +08:00
David Cermak
20fcc23f88 fix(wifi): Fix default wifi-netif creation to assert if no event loop
- Added ESP_ERROR_CHECK() checks to `esp_wifi_set_default_wifi_..._handlers()` calls
- Added ESP_ERROR_CHECH() to `esp_netif_attach_wifi_...()` calls
- Updated documentation to reflect the changes

Closes https://github.com/espressif/esp-idf/issues/11580
2023-07-10 16:56:16 +02:00
Nachiket Kukade
6e6139061d fix(esp_wifi): Enable FTM for ESP32C2, fix other FTM issues
Enable FTM for ESP32C2 and update wifi libs with below fixes -

1. Bugfixes in Initiator and Responder mode
2. Fix wrong RTT value in first FTM procedure without connection
3. Update FTM calibration values for ESP32S2, S3, C3 and C2
4. Update distance estimation logic
5. Add some useful command parameters in FTM example
6. Fix bug when number of FTM measurement frames received is more
   than (number_of_brusts * FTMs per brust).

Co-authored-by: Sarvesh Bodakhe <sarvesh.bodakhe@espressif.com>
2023-07-10 10:41:37 +05:30
zhangyanjiao
277f0f4470 feat(wifi): Add API to get RSSI info after station connects to AP
- Add esp_wifi_sta_get_rssi() function to retrieve RSSI info after station connects to AP
2023-07-06 17:27:42 +08:00
Shyamal Khachane
6138ec7a61 fix(esp_wifi): NAN Service discovery and datapath bugfixes
1. Increase timeout value for NDP Accepted/Rejected events.
    2. Update publisher ID incase publisher restarts(service).
    3. Ignore service discovery frames with invalid/inactive service ID.
    4. Update NAN documentation
2023-07-05 10:35:14 +05:30
muhaidong
79ddd24d23 fix(wifi): fix some wifi bugs
1. esp_wifi: fix association request miss verify ssid issue
2. esp_wifi: fix wpa3 softAP allocate aid issue
2023-07-04 19:49:34 +08:00
jgujarathi
2fe35e8b49 esp_wifi : Add a obss scan timer disarm upon sta disconnect.
Adds a obss scan timer disarm when a sta disconnects from an AP.
2023-07-03 17:55:57 +05:30
jgujarathi
1302c5a622 esp_wifi : Fix collection of issues during sta scan and roam.
1) Fix issue during split scan to allow for data tx.
2) Fix issue when parsing wpa_ie to set correct authmode when AP
   supports both WPA_EAP and WPA_EAP_SHA256 authmode.
   Closes https://github.com/espressif/esp-idf/issues/11202
3) Fix an occasional crash during sta roam.
4) Add home_channel_dwell_time to wifi_scan_config_t. This allows
   configuration of the time spent between scanning consecutive
   channels for tx.
2023-07-03 04:05:52 +00:00
chenjianxing
3472c2a02a esp_wifi: decouple softap for esp32c2. 2023-06-28 13:47:31 +08:00
Liu Ning
8514469092 esp_wifi: fix ret when setting channel at wifi not started, fix timer callback 2023-06-27 21:34:53 +08:00