Commit Graph

4394 Commits

Author SHA1 Message Date
Jiang Jiang Jian
a78ad034f5 Merge branch 'bugfix/fix_mem_map_issue_v5.0' into 'release/v5.0'
flash_mmap: fix range issue (v5.0)

See merge request espressif/esp-idf!24529
2023-08-26 10:28:44 +08:00
Armando
53b1c2a2e6 test(flash_mmap): test flash mmap pages 2023-08-25 10:37:48 +08:00
harshal.patil
771f6b2b7e
fix(esp_prov): update devices tuple usage due to API deprecations
- a recent commit fixed the API deprecations,
and the BLEDevice object now needs to be accessed through a tuple.
- thus the changes were made in the code wherein the object was used,
but updating the usage in the condition when de
vname is not None got skipped.
2023-08-24 14:48:39 +05:30
Jiang Jiang Jian
38bd8d3044 Merge branch 'bugfix/esp32s3_usb_otg_console_v5.0' into 'release/v5.0'
system: support USB_OTG CDC console on ESP32-S3 (v5.0)

See merge request espressif/esp-idf!24338
2023-08-21 10:37:29 +08:00
Jiang Jiang Jian
7c91c8f78d Merge branch 'feature/freertos_iram_optimization_5.0' into 'release/v5.0'
freertos: Update linker fragment files to optimise IRAM utilisation (v5.0)

See merge request espressif/esp-idf!24222
2023-08-21 10:33:23 +08:00
Djordje Nedic
3b047f7572 fix: noload being included in ram and flash sizes
This fixes noload sections being included in the total flash and ram
size calculations. These sections represent things that already exist in
the rom or flash in different partitions and are not a part of the app.
2023-08-11 22:32:11 +02:00
radim.karnis
8abc88dab0 fix(build_system): Allow dots in the name of an app binary 2023-08-08 15:14:35 +02:00
Roland Dobai
3c07dc26ed Merge branch 'version_check_fix_dev_5.0' into 'release/v5.0'
fix(tools): check_python_version accept dev releases as requirement (v5.0)

See merge request espressif/esp-idf!25187
2023-08-08 15:20:45 +08:00
Peter Dragun
5369eea710 fix(tools): check_python_version accept dev releases as requirement 2023-08-07 10:27:04 +02:00
Roland Dobai
6e5bcdfe4c Merge branch 'bugfix/sbom_hash_check_v5.0' into 'release/v5.0'
fix(test_submodules.py): don't rely on submodule init (v5.0)

See merge request espressif/esp-idf!25058
2023-08-07 14:04:04 +08:00
harshal.patil
01a870bd8a fix(esp_prov): Fixed the deprecation APIs warnings
- Updated the extraction of service_uuids using AdvertisementData
- Replaced the `get_services()` API with the `services` property
2023-08-02 17:22:18 +05:30
Frantisek Hrbata
951510489d fix(test_submodules.py): don't rely on submodule init
Current version of the test is using "git-submodule foreach", which
requires submodules to be initialized. Non-initialized submodules are
ignored. Our CI is not performing submodule initialization, but instead
it only downloads the submodule content in tools/ci/ci_fetch_submodule.py
from cache and copies it into the submodule path.

Since we already know the submodule path from .gitconfig, we can use it
as argument to git-ls-tree and avoid calling git-submodule at all. This
allows to perform the test even if the submodules are not initialization
and also it makes the code simpler.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-07-28 12:14:41 +02:00
Roland Dobai
35c484324f Merge branch 'bugfix/debug_ext_ctrl_c_v5.0' into 'release/v5.0'
tools: fix waiting on gdb process when interrupted with CTRL+C (v5.0)

See merge request espressif/esp-idf!24934
2023-07-26 21:09:52 +08:00
Frantisek Hrbata
6f8c62b205 fix(debug_ext): CTRL+C handling while waiting on gdb process
idf.py spawns gdb process within a thread and uses Thread.join() to wait
for the gdb process to finish. As CTRL+C(SIGINT) is used by gdb to interrupt the
running program, we catch the SIGINT while waiting on the gdb to finish,
and try Thread.join() again.

With cpython's commit

	commit a22be4943c119fecf5433d999227ff78fc2e5741
	Author: Victor Stinner <vstinner@python.org>
	Date:   Mon Sep 27 14:20:31 2021 +0200

	    bpo-45274: Fix Thread._wait_for_tstate_lock() race condition (GH-28532)

this logic doesn't work anymore, because cpython internally marks the
thread as stopped when join() is interrupted with an exception. IMHO
this is broken in cpython and there is a bug report about this
https://github.com/python/cpython/issues/90882. Problem is that
waiting on a thread to finish is based on acquiring a lock. Meaning
join() is waiting on _tstate_lock. If this wait is interrupted, the
above referenced commit adds a logic that checks if the lock is help,
meaning the thread is done and marks the thread as stopped. But there is
no way to tell if the lock was acquired by us running join() or if it's
held by someone else e.g. still by the thread bootstrap code. Meaning
the thread is still running.

I may be missing something, but I don't see any reason why to spawn gdb
process within a thread. This change removes the thread and spawns gdb
directly. Instead waiting on a thread, we wait on the process to finish,
replacing join() with wait() and avoiding this problem.

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

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-07-20 17:12:32 +02:00
Chen Yudong
d1da86465b ci(esp_prov): remove import future usage 2023-07-20 16:00:21 +08:00
Ivan Grokhotkov
70faa798e7
ci: add build test for CONFIG_ESP_CONSOLE_USB_CDC_SUPPORT_ETS_PRINTF 2023-07-18 18:15:37 +02:00
Ivan Grokhotkov
ce8f2dc894
esp_rom: convert USB related headers to SPDX, update COPYRIGHTS.rst 2023-07-18 18:15:37 +02:00
Ivan Grokhotkov
36bc9ab30c
esp_rom: sync changes for ESP32-S3 USB related files, minor fix for S2
Used esp-rom tag esp32s3-20210327 and did manual cleanup.
Rename s_usb_osglue to rom_usb_osglue like it was done for esp32s2.
Some comments in esp32s2 headers are synced from esp32s3.
2023-07-18 18:15:03 +02:00
Jiang Jiang Jian
b0b3e0dc70 Merge branch 'bugfix/esp_netif_recieve_returns_v5.0' into 'release/v5.0'
esp_netif: Report error if esp_netif_receive() fails (v5.0)

See merge request espressif/esp-idf!24656
2023-07-17 10:28:06 +08:00
Peter Dragun
0055426b3f fix(tools/python_dep_check): replace deprecated pkg_resources with importlib
Closes https://github.com/espressif/esp-idf/issues/11712
2023-07-14 14:56:30 +02:00
Zim Kalinowski
ed93de6efa Merge branch 'bugfix/saving-esp-idf-env-as-utf8-v5.0' into 'release/v5.0'
build system: fix init.bat crash in windows when folder contains unicode characters (v5.0)

See merge request espressif/esp-idf!24669
2023-07-12 16:47:27 +08:00
Roland Dobai
7296cc6451 Merge branch 'asyncio_error_v5.0' into 'release/v5.0'
fix(tools/hints): add guide to fix error with unsupported asyncio (v5.0)

See merge request espressif/esp-idf!24702
2023-07-12 01:09:06 +08:00
Zim Kalinowski
36de1ba9c8 Merge branch 'bugfix/improve-git-describe-handling-v5.0' into 'release/v5.0'
build system: more accurate error information for git_describe (v5.0)

See merge request espressif/esp-idf!24668
2023-07-11 17:06:44 +08:00
Peter Dragun
002efdf88b fix(tools/hints): add guide to fix error with unsupported asyncio
Closes https://github.com/espressif/esp-idf/issues/11732
2023-07-11 10:55:06 +02:00
Roland Dobai
8fa72ec3b7 Merge branch 'monitor_multibyte_decode' into 'release/v5.0'
Tools(monitor): decode multibyte characters on Windows (backport v5.0)

See merge request espressif/esp-idf!24373
2023-07-11 16:40:40 +08:00
Roland Dobai
bd824a04d6 Merge branch 'fix/pyparsing_3.1.0_compatibility_v5.0' into 'release/v5.0'
fix: Compatibility with pyparsing>=3.1.0 (backport v5.0)

See merge request espressif/esp-idf!24370
2023-07-11 16:40:15 +08:00
Roland Dobai
8b01e23558 Merge branch 'fix/ci_coredump_test' into 'release/v5.0'
Tools: remove failing IDF Monitor host tests with coredump and fix print filter without ELF file specified

See merge request espressif/esp-idf!24272
2023-07-11 16:39:06 +08:00
Roland Dobai
f0f859f964 Merge branch 'feature/submodules_sbom_v5.0' into 'release/v5.0'
tools: add sbom information for submodules (v5.0)

See merge request espressif/esp-idf!24241
2023-07-11 16:38:18 +08:00
David Cermak
12d09e0b3b esp_netif: Make esp_netif_receive() return value configurable 2023-07-11 06:51:49 +02:00
Jiang Jiang Jian
afe026f318 Merge branch 'bugfix/increase_pm_dump_time_field_length_v5.0' into 'release/v5.0'
Power Management: increase pm_dump time field width (backport v5.0)

See merge request espressif/esp-idf!24449
2023-07-11 12:24:23 +08:00
Jiang Jiang Jian
e99b7835fa Merge branch 'bugfix/update_esp_rom_layout_v5.0' into 'release/v5.0'
esp_rom: fix rom layout issues (backport v5.0)

See merge request espressif/esp-idf!24640
2023-07-11 12:22:40 +08:00
Jiang Jiang Jian
c10505f939 Merge branch 'bugfix/fix_esp32s3_psram_access_failed_in_dfs_v5.0' into 'release/v5.0'
esp_pm: fix esp32s3 psram access failed when dfs is enabled (backport v5.0)

See merge request espressif/esp-idf!24199
2023-07-11 12:19:43 +08:00
Marius Vikhammer
e004907bd5 versions: Update version to 5.0.3 2023-07-10 17:23:26 +08:00
Zim Kalinowski
56994aeb0b build system: more accurate error information for git_describe
Closes https://github.com/espressif/esp-idf/issues/9071

See merge request espressif/esp-idf!23891
2023-07-10 11:36:04 +08:00
Zim Kalinowski
a205213cc8 build system: fix init.bat crash in windows when folder contains unicode characters 2023-07-10 11:34:56 +08:00
Jiang Guang Ming
ce1042a267 esp_rom: fix rom layout issues 2023-07-07 01:25:17 -07:00
wuzhenghui
3eae74e966 bugfix: increase pm_dump time field width
Closes https://github.com/espressif/esp-idf/issues/11704
2023-06-28 14:35:20 +08:00
Frantisek Hrbata
b947cab073 tools: add sbom information for submodules
This adds SBOM information for submodules, which are not managed
by Espressif. Meaning there is no fork for them in the espressif
namespace. Other submodules should add sbom.yml manifest file to
the root of their git repository.

The SBOM information for submodules is stored in the .gitmodules file.
Each SBOM related variable has the "sbom-" prefix and the following
variables may be used:

sbom-version:
   submodule version

sbom-cpe:
   CPE record if available in NVD. This will be used by the SBOM
   tool to check for possible submodule vulnerabilities. The
   version in the CPE can be replaced with the "{}" placeholder,
   which will be replaced by the "sbom-version" value from above.

sbom-supplier:
   Person or organization who is providing the submodule.
   It has to start with "Person:" or "Organization:" prefix
   as required by the SPDX-2.2 standard.

sbom-url:
   URL to the project if exists, e.g. github.

sbom-description:
   Project description.

sbom-hash:
   Submodule SHA as recorded in the git-tree. This field is used by
   CI to check that the submodule checkout hash and info in .gitmodules
   are in sync. IOW if submodule is updated and it has SBOM info in
   .gitmodules, the .gitmodules has to be updated too. The test is
   part of this commit. The checkout has of the submodule can be found
   by using "git submodule status".

Example for micro-ecc submodule
---8<---
[submodule "components/bootloader/subproject/components/micro-ecc/micro-ecc"]
	path = components/bootloader/subproject/components/micro-ecc/micro-ecc
	url = ../../kmackay/micro-ecc.git
	sbom-version = 1.0
	sbom-cpe = cpe:2.3🅰️micro-ecc_project:micro-ecc:{}:*:*:*:*:*:*:*
	sbom-supplier = Person: Ken MacKay
	sbom-url = https://github.com/kmackay/micro-ecc
	sbom-description = A small and fast ECDH and ECDSA implementation for 8-bit, 32-bit, and 64-bit processors
	sbom-hash = d037ec89546fad14b5c4d5456c2e23a71e554966
---8<---

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-06-27 10:05:29 +02:00
Peter Dragun
57e188c2e3 fix(monitor/ansi_converter): decode multibyte characters 2023-06-23 09:32:13 +02:00
Darian Leung
feee3a3059 freertos: Refactor OS startup functions
This commit refactors the OS startup functions as follows:

- Moved the OS/app startup functions listed below to "app_startup.c". Their
    implementations are now common to all ports (RISC-V and Xtensa) of all
    FreeRTOS implementations (IDF and Amazon SMP).
    - esp_startup_start_app()
    - esp_startup_start_app_other_cores()
- Removed esp_startup_start_app_common() as app startup functions are now
    already common to all ports.
- Added extra logs to "main_task" to help with user debugging

Note: Increased startup delay on "unity_task". The "unity_run_menu()" is non
blocking, thus if the main task or other startup tasks have not been freed
by the time "unity_run_menu()" is run, those tasks will be freed the next time
"unity_task" blocks. This could cause some tests to have a memory leak, thus
the "unity_task" startup delay has increased.
2023-06-22 17:17:18 +02:00
radim.karnis
7b98762ff5 fix: Compatibility with pyparsing>=3.1.0 2023-06-22 11:29:14 +02:00
Fu Hanxi
4ff607e9a8 ci: ignore pkg_resources deprecation warning 2023-06-21 07:30:25 +08:00
Roland Dobai
169d7dc3c9 tools: Fix IDF Monitor print filter when no ELF file is supplemented
A different serial handler class is used when there was no ELF file
passed do esp-idf-monitor. This fix will ensure that print filter check
is respected in this case as well.
2023-06-19 16:56:20 +02:00
Roland Dobai
6212ce9d94 tools: Remove ELF-file-based IDF Monitor tests 2023-06-19 16:56:20 +02:00
wuzhenghui
d202fc5993 ci: sync master flash_psram test and add access psram with DFS unity test 2023-06-15 14:14:25 +08:00
Anton Maklakov
70998e211a tools: add ULP toolchain for linux-i686 platform
Closes https://github.com/espressif/esp-idf/issues/11561
2023-06-13 12:50:21 +07:00
Marek Fiala
5a7eae4743 Tools bugfix: Removed working directory when using idf.py
Added check for existence of current working directory when using idf.py

Closes https://github.com/espressif/esp-idf/issues/11476
2023-06-09 14:28:11 +02:00
Frantisek Hrbata
9156bbb55c tools: extend information in project_description.json
This extends information provided in the project_description.json file.
Newly added information can be used in the SBOM generating tool and
also to improve hints regarding the the component dependency issues.

Added fields

version:
   This adds versioning to the project_description.json file,
   so it's easy to identify if it contains the required information.

project_version:
   Can be used as a version for the resulting binary e.g. `hello_world.bin`.

idf_path:
   This one is probably not necessary, but it allows tools to run even without
   esp-idf environment exported(e.g. export.sh).

c_compiler:
   The `CMAKE_C_COMPILER` value with full path to the compiler binary. This can
   be used to get information about toolchain, which was used to build the project.

common_component_reqs:
   List of common components as presented in cmake's __COMPONENT_REQUIRES_COMMON
   and set in tools/cmake/build.cmake:__build_init().

build_component_info:
   Detailed information about components used during build. It's a
   dictionary with the component name as a key and each component has
   a dictionary with detailed information. Following is an example for
   the efuse component.

   "efuse": {
       "alias": "idf::efuse",
       "target": "___idf_efuse",
       "prefix": "idf",
       "dir": "/home/fhrbata/work/esp-idf/components/efuse",
       "type": "LIBRARY",
       "lib": "__idf_efuse",
       "reqs": [],
       "priv_reqs": [ "bootloader_support", "soc", "spi_flash" ],
       "managed_reqs": [],
       "managed_priv_reqs": [],
       "file": "/home/fhrbata/work/blink/build/esp-idf/efuse/libefuse.a",
       "sources": [ "/home/fhrbata/work/esp-idf/components/efuse/esp32s3/esp_efuse_table.c", ... ],
       "include_dirs": [ "include", "esp32s3/include" ]
   }

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-06-08 14:30:07 +02:00
Frantisek Hrbata
30735b33ef tools: fix make_json_list to return empty json list for empty cmake list
Currently make_json_list() returns '[ "" ]' for empty cmake list. Fix this
so empty json list is returned instead.

Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
2023-06-08 14:30:07 +02:00
Marius Vikhammer
e77e6eb963 Merge branch 'bugfix/use_safe_noreturn_attr_v5.0' into 'release/v5.0'
compiler: replaced noreturn by __noreturn__ in header files (v5.0)

See merge request espressif/esp-idf!23812
2023-06-01 10:17:58 +08:00