Commit Graph

6617 Commits

Author SHA1 Message Date
Tomáš Rohlínek
f416523e16 fix(storage/fatfsgen): increase test timeout 2025-03-12 14:45:39 +01:00
Konstantin Kondrashov
2fb93845df Merge branch 'contrib/github_pr_15308' into 'master'
fix(cmake): support CMock subdir option with idf_component_mock (GitHub PR)

Closes IDFGH-14547 and IDFGH-12326

See merge request espressif/esp-idf!36761
2025-03-12 19:26:02 +08:00
Chen Jichang
bfac674769 feat(esp32h4): ci enable public header check (stage7) 2025-03-12 17:19:50 +08:00
Frantisek Hrbata
d20a5fd939 fix: adjust C standard preferences for Linux target
In commit 70407df8c2 ("fix(build): don't call enable_language() before
proje.."), the C standard preferences were mistakenly changed to
`set(preferred_c_versions gnu99 gnu17 gnu11 gnu99)`. This was likely an
oversight from my testing. This corrects the C standard preferences to
the intended order.

Fixes: 70407df8c2 ("fix(build): don't call enable_language() before proje..")
Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2025-03-10 20:34:32 +08:00
Jiang Jiang Jian
4f5bed28e7 Merge branch 'bugfix/provisioning_sec2_aes_iv_usage' into 'master'
fix(provisioning): fix incorrect AES-GCM IV usage in security2 scheme

See merge request espressif/esp-idf!37226
2025-03-08 14:03:53 +08:00
Roland Dobai
7ce80cef7e Merge branch 'fix/linux_std_flags' into 'master'
fix(build): don't call enable_language() before project()

Closes IDFGH-14749

See merge request espressif/esp-idf!37412
2025-03-07 18:10:30 +08:00
Mahavir Jain
00e8d1a832 fix(esp_local_ctrl): update for changes in protocomm security2 scheme 2025-03-07 13:49:12 +05:30
Mahavir Jain
3bd5a22f5a fix(provisioning): fix incorrect AES-GCM IV usage in security2 scheme
Using same IV in AES-GCM across multiple invocation of
encryption/decryption operations can pose a security risk. It can help
to reveal co-relation between different plaintexts.

This commit introduces a change to use part of IV as a monotonic
counter, which must be incremented after every AES-GCM invocation
on both the client and the device side.

Concept of patch version for a security scheme has been introduced here
which can help to differentiate a protocol behavior for the provisioning
entity. The security patch version will be available in the JSON
response for `proto-ver` endpoint request with the field
`sec_patch_ver`.

Please refer to documentation for more details on the changes required
on the provisioning entity side (e.g., PhoneApps).
2025-03-07 13:49:10 +05:30
Erhan Kurubas
0381f5723a Merge branch 'refactor_panic_test_parametrize' into 'master'
test(panic): refactor test parameters with itertools

See merge request espressif/esp-idf!37516
2025-03-06 16:04:02 +08:00
Erhan Kurubas
11e6aa8f1a test(panic): refactor test parameters with itertools 2025-03-05 14:01:25 +01:00
Erhan Kurubas
1153981bc8 feat(tools): update openocd version to v0.12.0-esp32-20250226 2025-03-05 10:36:15 +01:00
Igor Udot
3b41e2ce9a Merge branch 'ci/pytest-mark-formatter' into 'master'
Ci/pytest mark formatter

Closes IDFCI-2662 and IDFCI-2651

See merge request espressif/esp-idf!35476
2025-03-05 15:43:48 +08:00
Mahavir Jain
620ab3b913 Merge branch 'fix/secure_boot_verfication_failure_sig_block_key_digest_mismatch_combo' into 'master'
fix(bootloader_support): Fix SB verification failure when application is not signed with the boot loader's first key

Closes IDF-12556

See merge request espressif/esp-idf!37365
2025-03-05 15:08:24 +08:00
igor.udot
daf2d31008 test: format all test scripts 2025-03-05 12:08:48 +08:00
igor.udot
bbcef0570d ci: add test marks linter 2025-03-04 15:53:32 +08:00
Chen Jichang
b16095cf00 feat(esp32h4): add G0 component support (stage5) 2025-03-04 15:21:58 +08:00
harshal.patil
a6ea9bcd41 fix(secure_boot): Fix SB verification failure when sig block and key digest mismatch
- Secure boot V2 verification failed when multiple keys are used to sign the bootloader
  and the application is signed with a key other than the first key that is used to
  sign the bootloader.
- The issue was introduced as a regression from the commit `ff16ce43`.
- Added a QEMU test for recreating the issue.
- Made SECURE_BOOT_FLASH_BOOTLOADER_DEFAULT independent of SECURE_BOOT_BUILD_SIGNED_BINARIES.
2025-03-04 11:26:51 +05:30
Frantisek Hrbata
70407df8c2 fix(build): don't call enable_language() before project()
For the Linux target, we currently attempt to fallback to older C/CXX
lagnuage standards in the __build_set_lang_version() function. The
language standard support is checked using CMake's language-specific
functions, such as check_c_compiler_flag(). These functions require the
language to be enabled[1] in CMake beforehand, which is done by calling
project() or by enabling the languages later with enable_language(). At
present, we use enable_language() to enable C and CXX languages in
CMake, allowing us to set the standard early, before invoking project().
However, newer CMake versions (>3.29) issue a warning[2] if
enable_language() is called before project(), as noted in CMP0165[3].

It should generally be acceptable to call __build_set_lang_version()
after __project(), but doing so would alter the behavior of the
COMPILE_OPTIONS also for non-Linux targets. Currently, users can
add to COMPILE_OPTIONS even before calling project() in the project's
CMakeLists.txt and the options will be in the desired order. In other
words, appending to COMPILE_OPTIONS can occur either before or after
calling project() in the project's CMakeLists.txt, with the outcome
remaining consistent. This means the user's settings will appear later
and take priority. However, if __build_set_lang_version() is called
after __project(), the user's COMPILE_OPTIONS settings would be
overridden if set before calling project(). Our documentation[4] explicitly
states that COMPILE_OPTIONS and similar properties should be modified
using idf_build_set_property() after calling project() to prevent
default values from overwriting them.

Even with this guidance, some existing components that modify
COMPILE_OPTIONS before invoking project() might be impacted by this
change. Therefore, separate the language standard settings for non-Linux
and Linux targets. For non-Linux targets, these settings are applied in
__build_set_default_build_specifications(), maintaining the current
behavior. For the Linux target, the language standard is set with
__linux_build_set_lang_version() after calling __project(), ensuring the
languages are already enabled in CMake and no warning is issued. Since the Linux
target is still in preview, this approach should be acceptable,
especially with the existing documentation[4].

Closes https://github.com/espressif/esp-idf/issues/15488

[1] https://cmake.org/cmake/help/latest/manual/cmake-toolchains.7.html#languages
[2] https://gitlab.kitware.com/cmake/cmake/-/merge_requests/9396
[3] https://cmake.org/cmake/help/latest/policy/CMP0165.html#policy:CMP0165
[4] https://docs.espressif.com/projects/esp-idf/en/v5.4/esp32/api-guides/
    build-system.html#overriding-default-build-specifications

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2025-03-03 14:52:18 +01:00
Marius Vikhammer
d46b4fbfcf fix(linux_target): fixed TEST_COMPONENTS not working on macOS for linux target
Closes https://github.com/espressif/esp-idf/issues/15490
2025-03-03 16:42:18 +08:00
Frantisek Hrbata
9eb6f68454 fix(build): include test components in the minimal build
When minimal build is enabled, it only includes the main component and
its dependencies. This leads to test components specified through
TEST_COMPONENTS being ignored, meaning no tests are executed. The issue
arises because test components are also checked against the COMPONENTS
variable, and if they aren't listed there, they are disregarded.  To fix
this, explicitly add TEST_COMPONENTS to COMPONENTS when the minimal
build is enabled.

Closes https://github.com/espressif/esp-idf/issues/15485

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2025-02-28 12:42:14 +01:00
Roland Dobai
648dc329f6 Merge branch 'change/move_deprecated_kconfig_checker' into 'master'
change: move check_deprecated_configs.py logic to esp-idf-kconfig

Closes IDF-9092

See merge request espressif/esp-idf!36588
2025-02-28 19:05:02 +08:00
Frantisek Hrbata
4f968c3fc5 Merge branch 'contrib/github_pr_15401' into 'master'
Fix idf_as_lib example (GitHub PR)

Closes IDFGH-14655

See merge request espressif/esp-idf!37127
2025-02-27 15:00:12 +08:00
Frantisek Hrbata
54cb6636ec ci: add idf_as_lib to patterns-build_system rules
The `idf_as_lib` example is used and tested in
`tools/test_build_system/test_cmake.py`. Include `idf_as_lib` in the
build_system rules to ensure the tests are executed whenever there is a
modification in the `idf_as_lib` example.

Expand the `test_build_custom_cmake_project` test to cover all supported
targets, including host build.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2025-02-25 08:54:02 +01:00
Jan Beran
c7993c2725 change: move check_deprecated_configs.py file to esp-idf-kconfig 2025-02-24 12:52:55 +01:00
Chen Ji Chang
33e81e572b Merge branch 'feat/h4_introduce_step2_3' into 'master'
feat(esp32h4): add soc register header files (stage 3/8, part 3/3)

See merge request espressif/esp-idf!37092
2025-02-24 15:39:11 +08:00
Chen Jichang
62700fa36f feat(esp32h4): add soc register header files (stage2_3)
add soc headers made by hand
2025-02-24 12:20:27 +08:00
Marius Vikhammer
a5fe1e2a46 Merge branch 'feature/h21_panic' into 'master'
feat(esph21): bringup and test panic handler

Closes IDF-11546

See merge request espressif/esp-idf!37007
2025-02-21 10:25:03 +08:00
Martin Vychodil
af0f270e17 Merge branch 'bugfix/memprot_s2_intr_peri1' into 'master'
fix(security): ESP32S2 memory protection check for Peri1 RTCSLOW interrupt

See merge request espressif/esp-idf!37105
2025-02-21 01:43:44 +08:00
Aleksei Apaseev
8355b832d3 Merge branch 'ci/add-python-func-and-fix-c-testcase-path-in-junit-report' into 'master'
ci: add python_func attribute and fix C testcase path resolution in JUnit reports

Closes RDT-1013, IDFCI-1990, IDFCI-1964, and IDFCI-1429

See merge request espressif/esp-idf!35058
2025-02-20 10:09:52 +08:00
Martin Vychodil
64ae64fb16 fix(security): Fixed ESP32S2 memory protection check for Peri1 RTCSLOW interrupt
- fixes the issue found in https://github.com/espressif/esp-idf/issues/15359
- extends debug printouts in the related tests
2025-02-19 14:14:27 +01:00
Sudeep Mohanty
b562afa08e fix(panic_handler): Updated panic handler to use RTC WDT
This commit updates the following:
- Updates the panic handler to use only the RTC WDT to reset the system.
- Refactors some of the panic handler code.
- Updates Bluetooth files where in they now feed the WDTs instead of
  reconfiguring them.
- Removes some unnecessary configuration of WDTs from various files.
- Added a unit test to verify that the system does not lock up when the
  panic handler is stuck.
- Updates the memprot unit tests to work with the refactored panic
  handler.

Closes https://github.com/espressif/esp-idf/issues/15166
Closes https://github.com/espressif/esp-idf/issues/15018
Closes https://github.com/espressif/esp-idf/issues/10110
2025-02-18 15:40:54 +01:00
Jeroen Domburg
5d63f251f9 Merge branch 'feature/bitscrambler_add_c5_insn' into 'master'
BitScrambler: Add support for addcti instruction as found in ESP32-C5

See merge request espressif/esp-idf!36906
2025-02-18 14:39:42 +08:00
Aleksei Apaseev
c03b007644 ci: fix testcase path resolution in JUnit reports. switch to the different unity test report mode. add app_path to target test report 2025-02-17 18:55:53 +08:00
Jeroen Domburg
3aaaa2203a feat: BitScrambler: Add support for addcti instruction as found in ESP32-C5 2025-02-17 16:36:52 +08:00
laokaiyao
7e0cb453e8 fix(i2s): fixed i2s_std initializer order for cpp compiler
Closes https://github.com/espressif/esp-idf/issues/15405
2025-02-17 14:44:48 +08:00
Marius Vikhammer
91bff05d9f feat(esph21): bringup and test panic handler 2025-02-17 11:58:55 +08:00
Wan Lei
c7a0e45489 Merge branch 'feat/spi_master_dynamic_freq' into 'master'
feat(spi_master): add transaction config for device multi freq point

Closes IDFGH-12774

See merge request espressif/esp-idf!28579
2025-02-13 15:58:59 +08:00
wanckl
39c85269cc feat(spi_master): add transaction config for dynamic clock speed update
Closes https://github.com/espressif/esp-idf/issues/13753
2025-02-12 20:29:34 +08:00
Aleksei Apaseev
0d6099ec53 Merge branch 'fix/fix-test-report-generator' into 'master'
ci: fix tests related to the build report generator

See merge request espressif/esp-idf!36910
2025-02-12 19:22:31 +08:00
Aleksei Apaseev
897db53113 ci: fix tests build report generator 2025-02-12 19:07:53 +08:00
Roland Dobai
bbdf1e4a2a Merge branch 'feat/use_diag_module' into 'master'
feat(diag): use the esp-idf-diag module as a backend

See merge request espressif/esp-idf!36872
2025-02-12 18:39:53 +08:00
Frantisek Hrbata
bdc94935fa feat(diag): use the esp-idf-diag module as a backend
Replace the original diag implementation in idf.py with the new one in a
separate esp-idf-diag python package. The interface is kept the same as
it was. The simple idf.py diag test is also preserved.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2025-02-11 11:26:47 +01:00
Chen Ji Chang
9342b3fba1 Merge branch 'feat/h4_introduce_step1_add_target' into 'master'
feat(esp32h4): introduce target esp32h4(stage 1)

See merge request espressif/esp-idf!36780
2025-02-11 18:11:08 +08:00
akshat
e532499e5d bugfix(wifi): Fix header file errors and remove esp_supplicant from check_public_headers_exceptions.txt 2025-02-10 17:56:52 +08:00
Chen Jichang
6f83f39dce feat(esp32h4): introduce target esp32h4(stage 1) 2025-02-08 17:07:44 +08:00
Gao Xu
1e8a48db74 Merge branch 'feat/h21_enable_ci_build_test' into 'master'
feat(esp32h21): enable ESP32H21 ci build

Closes IDF-11561

See merge request espressif/esp-idf!36197
2025-02-07 14:10:54 +08:00
gaoxu
5ef4f20778 feat(esp32h21): disable unsupported build test 2025-02-06 15:47:51 +08:00
Bastien Germond
0b8ecbb03a fix(cmake): Support CMock subdir option with idf_component_mock
Closes https://github.com/espressif/esp-idf/pull/15308
Closes https://github.com/espressif/esp-idf/issues/13360
2025-02-05 14:07:19 +02:00
harshal.patil
7d8211bf87 feat(mbedtls): Support both SHA block and DMA modes during runtime
Dynamically switch the SHA operation modes based on the buffer operating length
2025-02-04 16:49:30 +05:30
Erhan Kurubas
f6b407d6b9 test(coredump): collect all expected uart data first, then process lazily 2025-02-01 06:12:11 +08:00