Commit Graph

14660 Commits

Author SHA1 Message Date
Anton Maklakov
e7bfc44caf spiffs: fix format-truncation warning 2022-03-09 10:43:30 +07:00
David Čermák
06df46e26a Merge branch 'bugfix/security_update_pppos_crash' into 'master'
lw-ip: Apply security fixes from upstream; Fix PPPoS and NAPT ip-forward

Closes IDFGH-6668 and IDFGH-6825

See merge request espressif/esp-idf!17227
2022-03-09 03:04:52 +08:00
Mahavir Jain
5ca79a00dd Fix build issues for implicit declaration for esp_fill_random 2022-03-08 14:05:23 +00:00
Sachin Parekh
32a6550e87 mbedtls: Added ECC hardware accelerator support on ESP32C2
ESP32C2 has a ECC hardware accelerator capable of performing point
multiplication and point verification with a significant performance
boost
2022-03-08 14:05:23 +00:00
Sachin Parekh
bc1d35a14e esp32c2/hal: Added ECC HAL layer 2022-03-08 14:05:23 +00:00
Darian
8b902739ac Merge branch 'feature/freertos_smp_base_master_483237711' into 'master'
Add baseline SMP FreeRTOS

Closes IDF-3420, IDF-3348, IDF-3331, IDF-3333, IDF-3701, IDF-3341, IDF-3346, IDF-3339, IDF-3685, IDF-3338, and IDF-3342

See merge request espressif/esp-idf!17016
2022-03-08 19:58:11 +08:00
Omar Chebib
cfee73658b Merge branch 'bugfix/fix_heap_free_memory' into 'master'
Heap: fix free bytes calculation for TLSF heap

Closes IDFGH-6628

See merge request espressif/esp-idf!17337
2022-03-08 18:08:30 +08:00
Shu Chen
fcfe75b7d6 Merge branch 'feature/openthread-update-220303' into 'master'
openthread: Update OpenThread submodule

See merge request espressif/esp-idf!17338
2022-03-08 18:02:20 +08:00
David Cermak
92f7ecd632 lwip: Security fixes; PPPoS null-deref; NAPT ip-forward
* Cherry-pick important fixes to 2.1.2-esp
  - CVE-2020-22283: Attacker could craft a packet that would disclose 8 bytes of some heap memory:
    - icmp6: Don't copy too much data
    - icmp6: Fix copying of chained pbuf in reply
    - icmp6: keep to the RFC and send as much as possible with icmp6 error messages
  - CVE-2020-22284: ZEP - ZigBee Encapsulation Protocol/6LoWPAN is not supported in IDF,
    the netif module (zepif.c) is not included in the build, but users can still inject
    the file into compilation process, implement IO interface and use this.
    - zepif: Copy possibly chained output pbuf properly
    - Add #define for minimum IPv6 MTU length
    - pbuf: Add pbuf_copy_partial_pbuf library function
* PPPoS: Fix null-deref when processing double break packet
  - pppos: fix in_tail null (espressif/esp-lwip@537c69d5)
  - PPP: Add test exhibiting empty packet null-deref (espressif/esp-lwip@202a07da)
* NAPT: Fix PBUF_REF type to clone the pbuf before forwarding
  - IP-FORWARD: If packet-type is PBUF_REF clone it before forwarding
  - Add NAPT unit test to exercise NAT feature for both RAM and REF pbuf types
* version: Update version numbers to match 2.1.2-esp

* Update submodule: 2749568fe1...76303df238
  - test/napt: Add unit test for IP forward with PBUF_REF (espressif/esp-lwip@76303df2)
  - napt: Fix PBUF_REF type to clone the pbuf before forwarding (espressif/esp-lwip@39068263)
  - version: Update version numbers to match 2.1.2-esp (espressif/esp-lwip@2b922919)
  - pppos: fix in_tail null (espressif/esp-lwip@537c69d5)
  - PPP: Add test exhibiting empty packet null-deref (espressif/esp-lwip@202a07da)
  - pbuf: Add pbuf_copy_partial_pbuf library function (espressif/esp-lwip@1c9cd9c1)
  - Add #define for minimum IPv6 MTU length (espressif/esp-lwip@d2dc577b)
  - zepif: Copy possibly chained output pbuf properly (espressif/esp-lwip@64ab7f2a)
  - icmp6: Don't copy too much data (espressif/esp-lwip@4a64731b)
  - icmp6: Fix copying of chained pbuf in reply (espressif/esp-lwip@7c822ff4)
  - icmp6: keep to the RFC and send as much as possible with icmp6 error messages (espressif/esp-lwip@29100ab6)
  - dns: Add API to clear dns cache (espressif/esp-lwip@ee59f77d)
  - CI: Fixed adding gitlab key (espressif/esp-lwip@5a2bdba7)
  - test case: modify test case test_tcp_new_max_num_remove_FIN_WAIT_1 (espressif/esp-lwip@6b090f7d)

Closes https://github.com/espressif/esp-idf/issues/8300
Closes https://github.com/espressif/esp-idf/issues/8451
2022-03-08 09:38:42 +01:00
Darian Leung
c2f2b1e228 freertos: Add SMP FreeRTOS porting notes
This commit adds some notes about the SMP FreeRTOS port
2022-03-08 14:59:18 +08:00
Darian Leung
27f5c90e2e freertos: Fix usage of vTaskSuspendAll()/xTaskResumeAll()
IDF FreeRTOS uses vTaskSuspendAll()/xTaskResumeAll() to stop preemption
on a particular core. However, those functions behave differently in FreeRTOS SMP.
This commit replaces all calls of vTaskSuspendAll()/xTaskResumeAll() with
vTaskPreemptionDisable()/vTaskPreemptionEnable() when compiling with SMP FreeRTOS.
2022-03-08 14:59:18 +08:00
Darian Leung
883da858b0 freertos: Fix various build errors
This commit fixes various build errors in IDF (and tests) when compiling
with SMP FreeRTOS:

- Updated usage of xTaskGetIdleTaskHandle()
- Disable sysview tracing macros
- Update some task snapshot functions
- Disabled test_freertos_hooks.c test as vApplicationIdleHook() and
  vApplicationTickHook() are used.
2022-03-08 14:59:18 +08:00
Darian Leung
9da5d7c40a freertos: Add changes to FreeRTOS SMP sources
This commit adds the necessary changes to the FreeRTOS SMP source and
and header files so that it can be compatible with ESP-IDF.
2022-03-08 14:59:18 +08:00
Darian Leung
37c270b337 freertos: Update Xtensa port files to support FreeRTOS SMP
This commit updates the copied Xtensa port to support the new porting interfaces
of the FreeRTOS SMP kernel. These modifications are mainly contained in

- FreeRTOSConfig.h
- FreeRTOSConfig_smp.h
- portmacro.h
- port.c

Some porting interfaces have changed in FreeRTOS SMP. In order to allow building
with IDF, compatibility interfaces have been added.
2022-03-08 14:59:18 +08:00
Darian Leung
163ddc3818 freertos: Update components CMakeLists.txt and Add SMP Kconfig option
This commit does the following:

- Add a Kconfig option to select between the IDF FreeRTOS kernel and the
  FreeRTOS SMP kernel.
- Updates the freertos component's CMakeLists.txt so that FreeRTOS SMP
  files are now built based the the new configuration option.

This commit WILL NOT compile. The port files for FreeRTOS SMP still need to
be updated.
2022-03-08 14:59:18 +08:00
Darian Leung
89dd2fe7f5 freertos: Copy IDF xtensa port files
This commit copies over ESP-IDF Xtensa portable files to the
FreeRTOS-Kernel-SMP directory. No changes were made, this commit
only copies the portable source files.

Notes:
- This commit WILL NOT compile
- Some SPDX header dates were updated to pass pre-commit check
2022-03-08 14:59:18 +08:00
Darian Leung
2d1afaf35b freertos: Add FreeRTOS SMP upstream files
This commit copies over the sources files from
https://github.com/FreeRTOS/FreeRTOS-Kernel/tree/smp based on the
commit 4832377117b4198db43009f2b548497d9cdbf8da

The FreeRTOS SMP sources are added to components/freertos/FreeRTOS-Kernel-SMP

Notes:
- This commit WILL NOT compile correctly. It simply copies over sources files
- copyright_ignore.txt entries added so that we can avoid using SPDX headers
- Portable files are not added yet
2022-03-08 14:58:57 +08:00
Omar Chebib
4ce4c5a68a Heap: fix free bytes calculation for TLSF heap
* Closes https://github.com/espressif/esp-idf/issues/8270
2022-03-08 11:42:23 +08:00
Cao Sen Miao
12e050b38c opi_flash: Add new 16MB opi flash (MXIC25UW12345G) support,
Closes https://github.com/espressif/esp-idf/issues/7996
2022-03-08 11:02:49 +08:00
Aditya Patwardhan
8f67af174e Merge branch 'contrib/github_pr_8462' into 'master'
Add WolfSSL esp_tls TLS1.3 configuration option (GitHub PR)

Closes IDFGH-6838 and IDFGH-6683

See merge request espressif/esp-idf!17324
2022-03-08 10:57:05 +08:00
Zim Kalinowski
0440aca4e3 Merge branch 'feature/reevaluate_headers_include_dirs' into 'master'
esp_hw_support/esp_system: Re-evaluate header inclusions and include directories

See merge request espressif/esp-idf!16763
2022-03-08 01:32:24 +08:00
morris
4aa81975d1 Merge branch 'bugfix/i2c_fix_typo_of_slave_macro' into 'master'
i2c: fix typo in SOC_I2C_SUPPORT_SALVE

Closes IDFGH-6893

See merge request espressif/esp-idf!17373
2022-03-07 23:38:13 +08:00
Ivan Grokhotkov
5f1c6ac605 Merge branch 'contrib/github_pr_8500' into 'master'
Fix compiler error in mbedtls (GitHub PR)

Closes IDFGH-6879 and IDFGH-6881

See merge request espressif/esp-idf!17380
2022-03-07 22:17:30 +08:00
Vamshi Gajjela
a9454c9776 Merge branch 'feature/sdmmc_erase_cmd_support' into 'master'
[sdmmc] Add erase command support

Closes IDFGH-5947 and IDFGH-5935

See merge request espressif/esp-idf!17054
2022-03-07 21:52:23 +08:00
Ivan Grokhotkov
5bc1cd7d26 Merge branch 'feature/flash_emu_linux_component' into 'master'
[spi_flash] LINUX target emulation of Partition API

See merge request espressif/esp-idf!13929
2022-03-07 20:36:38 +08:00
Simon
4bf4a020a6 Merge branch 'refactor/abstract_temperature_sensor' into 'master'
temperature_sensor: Refactor temperature sensor to new APIs (follow rule of driverNG) and support esp32s3

Closes IDF-3665, IDF-3367, and IDF-1793

See merge request espressif/esp-idf!16787
2022-03-07 20:17:39 +08:00
Alexander Klassen
a46776ad02 Add WolfSSL esp_tls TLS1.3 configuration option
Closes https://github.com/espressif/esp-idf/issues/8313
2022-03-07 09:44:23 +00:00
Jiacheng Guo
323b35af58 openthread: Update OpenThread submodule
* Remove log region macros and move to the new OpenThread logging module
* Remove TREL support
2022-03-07 15:45:16 +08:00
Island
f31be6ca5d Merge branch 'feature/add_proxy_conn_and_disconn_event' into 'master'
ble_mesh: stack: Add proxy server connect and disconnect event

See merge request espressif/esp-idf!16917
2022-03-07 15:10:22 +08:00
0xFEEDC0DE64
9b7c345bce Fix compiler error in mbedtls
Closes https://github.com/espressif/esp-idf/pull/8500
Closes https://github.com/espressif/esp-idf/issues/8499
Closes IDFGH-6879
Closes IDFGH-6881
2022-03-07 12:15:08 +05:30
morris
75e835efe6 Merge branch 'bugfix/fix_regi2c_analog_cali_num_macro' into 'master'
regi2c: fix analog calibration register num macro

See merge request espressif/esp-idf!17376
2022-03-07 14:08:47 +08:00
Sudeep Mohanty
a9fda54d39 esp_hw_support/esp_system: Re-evaluate header inclusions and include directories
This commit updates the visibility of various header files and cleans up
some unnecessary inclusions. Also, this commit removes certain header
include paths which were maintained for backward compatibility.
2022-03-07 11:18:08 +05:30
Konstantin Kondrashov
e17b0df8ec Merge branch 'feature/adds_efuses_to_table' into 'master'
efuse: Adds ERR_RST_ENABLE efuse for C3 and S3

See merge request espressif/esp-idf!17294
2022-03-07 13:05:55 +08:00
Armando
f41c9d154a regi2c: fix analog calibration register num macro 2022-03-07 11:48:57 +08:00
Kevin Guilloy
1fce1616c4 i2c: fix typo in SOC_I2C_SUPPORT_SALVE
Merges: https://github.com/espressif/esp-idf/pull/8513
2022-03-07 10:40:57 +08:00
Armando (Dou Yiwen)
748037708f Merge branch 'bugfix/fix_adc_digital_not_reset_issue' into 'master'
adc: fix adc digital part not reset issue

Closes IDF-4680

See merge request espressif/esp-idf!17279
2022-03-06 13:49:18 +08:00
wangjialiang
089637cfa3 ble_mesh: stack: Bugfix the proxy client abnormal disconnection 2022-03-05 11:14:28 +00:00
wangjialiang
c49b5b2409 ble_mesh: stack: Add proxy server connect and disconnect event 2022-03-05 11:14:28 +00:00
Vamshi Gajjela
964592e189 fatfs: Add trim ioctl call, set FF_USE_TRIM as default option.
FF_USE_TRIM is set by default with this commit. Fatfs invokes disk_ioctl
with CTRL_TRIM to erase the sectors calling sdmmc_erase_sectors to choose the right
argument for the erase operation based on media type.
2022-03-05 16:35:37 +05:30
Vamshi Gajjela
ffdbeee9f6 sdmmc: Add erase command-38. Support erase/trim/discard/sanitize
options.

Erase command (38) for SD cards allows option for erase/dicard/fule
operation at block level and for MMC cards supports option for
discard/trim at block level. When Sanitize is executed only the
portion of data that was unmapped by a Discard command shall be
removed by the Sanitize command.

Unit test cases added to verify ERASE feature in SD/SDSPI mode.
TRIM/DISCARD/SANITIZE tests for eMMC devices.

Closes https://github.com/espressif/esp-idf/pull/7635
Closes https://github.com/espressif/esp-idf/issues/7623
2022-03-05 16:02:01 +05:30
Armando (Dou Yiwen)
48daa38a63 Merge branch 'bugfix/fix_adc_calibration_light_sleep_issue' into 'master'
adc: fix calibration error when waking up from light sleep

Closes IDF-4406, IDF-4605, IDFGH-6252, and IDFGH-6651

See merge request espressif/esp-idf!16259
2022-03-04 23:05:09 +08:00
Martin Vychodil
9a5f39ec2c spi_flash: Linux target emulation of Partition API
Emulator of Partition API layer for Linux OS
2022-03-04 14:36:46 +00:00
Ivan Grokhotkov
c8b43ee0c1 Merge branch 'bugfix/sdspi_example_esp32s3' into 'master'
examples: sdspi: re-enable for ESP32-S3, add Kconfig options for pins

Closes IDF-4641

See merge request espressif/esp-idf!17067
2022-03-04 18:42:53 +08:00
morris
a0283234cd Merge branch 'feature/support_esp32h2_gpio' into 'master'
esp32h2: support GPIO peripheral, IO_MUX, GPIO matrix

Closes IDF-4232 and IDF-3439

See merge request espressif/esp-idf!16609
2022-03-04 18:22:28 +08:00
Cao Sen Miao
b248046bcb Temperature_sensor: Create new temperature sensor API 2022-03-04 18:13:35 +08:00
Cao Sen Miao
214e206111 Temperature_sensor: Add temperature support for ESP32-S3 2022-03-04 18:13:27 +08:00
Cao Sen Miao
441900caa2 Temperature_sensor: keep legacy drivers 2022-03-04 17:59:07 +08:00
Mahavir Jain
171b4ec13a Merge branch 'fix/update_licenses_of_file_wrt_mbedtls_3_1_change' into 'master'
mbedtls: Update licenses of files updated in mbedtls-3.1 update

Closes IDF-4725

See merge request espressif/esp-idf!17335
2022-03-04 13:55:11 +08:00
Jiang Jiang Jian
081828d494 Merge branch 'bugfix/add_pll_track_feature_mr_master' into 'master'
Add pll track feature

Closes BT-2030

See merge request espressif/esp-idf!17284
2022-03-04 13:53:59 +08:00
Aditya Patwardhan
4582af75b8 mbedtls: Update licenses of files updated in mbedtls-3.1 update 2022-03-04 05:18:58 +00:00