Commit Graph

13616 Commits

Author SHA1 Message Date
Ivan Grokhotkov
004ea31cb7 Merge branch 'bugfix/loadable_elf_test_eco3_v4.1' into 'release/v4.1'
tests: gdb_loadable_elf: adjust the breakpoint location for ESP32 ECO3 (v4.1)

See merge request espressif/esp-idf!14041
2021-06-21 15:50:31 +00:00
David Cermak
6980b57a97 ci/test: Fix esp_http_client test not to use pointer after free 2021-06-21 21:47:39 +08:00
Euripedes Rocha
e0c2145cc7 bugfix/mqtt examples: Updates the CA certificates used.
- Updates the CA certificates.
- Updates the URI names to reflect the new URI in the service used in
  the examples.

Closes IDFGH-4986
Closes https://github.com/espressif/esp-idf/issues/6776
2021-06-21 21:45:08 +08:00
liqigan
72e5dfb4e3 fix a2dp sink RxSbcQ bugs
Closes https://github.com/espressif/esp-idf/issues/6712
Closes https://github.com/espressif/esp-idf/issues/7100
2021-06-21 20:16:42 +08:00
ChenJianxing
e2526915b7 esp_wifi: fix amsdu & fragment vulnerabilities 2021-06-21 19:26:43 +08:00
Wang Meng Yang
14e6b55923 Merge branch 'feat/ble_mesh_make_unprov_beacon_interval_configurable_v4.1' into 'release/v4.1'
Feat/ble mesh make unprov beacon interval configurable (v4.1)

See merge request espressif/esp-idf!14063
2021-06-21 09:22:28 +00:00
Wang Meng Yang
620049646d Merge branch 'bugfix/btdm_set_discoverable_after_create_server_v4.1' into 'release/v4.1'
components/bt: Set discoverable after create server

See merge request espressif/esp-idf!13727
2021-06-21 09:15:48 +00:00
wangjialiang
16898897a9 ble_mesh: stack: Fix crash for net_key_del when subnet is NULL 2021-06-21 11:26:10 +08:00
wangjialiang
9aecaa6fd0 ble_mesh: stack: Make unprovisioned beacon interval configurable.
Closes https://github.com/espressif/esp-idf/issues/6722
2021-06-21 11:26:03 +08:00
Renz Bagaporo
bf341d966c components: fix ldgen check errors 2021-06-21 09:52:03 +10:00
Renz Bagaporo
b9d288879d ci: exempt upstream libmbedtls mapping for sha256 2021-06-21 09:45:23 +10:00
Renz Bagaporo
23aff378f4 ldgen: fix sections info parsing
Fixes an issure where the first part of an object file name is not
included, due to matching the rule for a section entry previously.

Reduce depedency on matching literal strings in sections which might
change depending on toolchain (ex. matching 'elf32-xtensa-le')

Make sure parsing rule succeeds for the entirety of the sections info
string by adding 'parseAll=True'.

Add test for sections info parsing.
2021-06-21 09:45:23 +10:00
Renz Bagaporo
ffefe603ae ci: enabled ldgen mapping check in ci 2021-06-21 09:45:23 +10:00
Renz Bagaporo
8c6ec0bd48 ldgen: allow checking mappings 2021-06-21 09:36:26 +10:00
Ivan Grokhotkov
8ef0017662 gdbstub: fix thread list generation
This commit fixes an issue with gdbstub, where it would list threads
with TIDs 1 to N in qfThreadInfo/qsThreadInfo responses, and then
would tell GDB that the current TID is 0 in the qC response. This
caused an assertion failure in GDB, because it couldn't find the
thread structure corresponding to TID 0:

src/gdb/gdb/thread.c:93: internal-error: thread_info* inferior_thread(): Assertion `tp' failed.

The issue was caused by the logic of qfThreadInfo/qsThreadInfo.
If the "paniced" task index was 1, the code would report it in the
response to qfThreadInfo, and then mistakenly skip task with index 0
in qsThreadInfo, due to the use of pre-increment instead of a
post-increment.

With that issue fixed, GDB assertion doesn't happen anymore. However
the code contained a deeper problem, which manifested itself in the
fact that GDB would incorrectly show task index 0 as the current task,
after the above fix.

Previous version of the code assumed that when GDB requests the thread
list, it uses the first thread returned by the target as the "default"
thread, and subsequently shows the user that the program is stopped
in that thread. This assumption was incorrect. In fact, after
connecting to a remote target, GDB obtains information about the
"default" or "current" thread from two sources:
1. the 'thread' special register indicated in the status response
   ($T00thread;00000001#ee)
2. if the target has only sent the plain stop response ($T00#ee), GDB
   would ask for the current thread using a qC packet.
With that in mind, it is not necessary to report the paniced task as
the first task in qfThreadInfo response. We can simply returns the
tasks in their natural order, and then indicate the current task in
the qS packet response.

However even that change does not fully resolve the issues with task
list. The previous version of this code also incorrectly interpreted
the meaning of GDB TIDs -1 and 0. When GDB sends an "Hg0" command
early in the connection process, it doesn't expect the server to set
task 0 as the current task, as the code assumed. Rather, it tells the
server to "set any (arbitrary) task as the current one", and the most
logical thing to do for the server that is already in "stopped" state
is to keep the current task selection.

Since TID 0 has a special meaning in GDB remote protocol, gdbstub code
is now modified to map task indices (which start from 0) to GDB TIDs.
GDB TIDs are arbitrary, and for simplicity we keep the same order and
start counting them from 1.

The summary of all the above changes is:

1. Use "task index + 1" as the TID reported to GDB
2. Report the tasks in natural order; don't complicate the code to
   make the paniced task first in the list.
3. Centralize modification of 'current_task_index' and 'regfile'
   in the new 'set_active_task' function, to improve encapsulation.
2021-06-18 16:04:02 +02:00
Ivan Grokhotkov
f9f318d666 cmake: set IDF_VERSION_* variables at requirement expansion stage
Currently IDF_VERSION_* variables are not available to the component
CMakeLists.txt files at the requirements expansion stage. This makes
it harder to write component CMakeLists files compatible with
different IDF versions.

Include version.cmake from the requirements expansion script, add a
build system test.
2021-06-18 15:29:53 +02:00
Ivan Grokhotkov
0d5ec69adc tests: gdb_loadable_elf: adjust the breakpoint location for ESP32 ECO3
The previous location was the return from the first ets_printf call
that prints ROM sign-on message. Since the main function was patched
in ECO3, the new address no longer works — there is no instruction at
0x40007901 in ECO3 ROM. This could be solved by setting two
breakpoints (one would work for ECO <=2, the other for ECO3), but we
would need to remove the unused breakpoint later.
Fix this by setting the breakpoint at ets_printf. This means that when
debugging a loadable ELF the ROM sign-on message will no longer be
shown, but this doesn't seem to be an issue.
2021-06-18 15:10:06 +02:00
Krzysztof Budzynski
ac5511972f Merge branch 'bugfix/make_docs_ldgen_v4.1' into 'release/v4.1'
docs: remove quotes in ldgen documentation for adding fragment file (v4.1)

See merge request espressif/esp-idf!14002
2021-06-18 08:44:21 +00:00
Island
4dab171c9f Merge branch 'bugfix/AuthValue_leak_v4.1' into 'release/v4.1'
ble_mesh: stack: Fix AuthValue Leak and Predictable AuthValue in Bluetooth... (v4.1)

See merge request espressif/esp-idf!14007
2021-06-18 06:09:37 +00:00
Krzysztof Budzynski
d8ef56e630 Merge branch 'docs/update_docs_for_doc_751_v4.1' into 'release/v4.1'
docs: update the documents based on customer feedbacks (v4.1)

See merge request espressif/esp-idf!13960
2021-06-17 10:14:00 +00:00
Itay Perl
27fe437412 app_update: fix incorrect first byte from esp_ota_get_app_elf_sha256
At -O2 optimization level, GCC seems to optimize out the copying of the
first byte of the checksum, assuming it is zero. This "miscompilation"
happens because the esp_app_desc struct is declared const, but then modified
post-compilation. Casting to volatile disables the optimization.

Closes: https://github.com/espressif/esp-idf/pull/6389
2021-06-17 17:32:49 +08:00
wangjialiang
bfcaa64b49 ble_mesh: stack: Fix AuthValue Leak and Predictable AuthValue in Bluetooth Mesh Provisioning Leads to MITM 2021-06-17 17:23:49 +08:00
morris
41c82efcb9 i2s: fix driver uninstall issue 2021-06-17 16:37:11 +08:00
Island
cb1a17e7ce Merge branch 'bugfix/impersonation_attacks_and_AuthValue_disclosure_v4.1' into 'release/v4.1'
ble_mesh: stack: Add check the value of Provisioning Random & Confirmation... (v4.1)

See merge request espressif/esp-idf!13930
2021-06-17 07:20:12 +00:00
Renz Bagaporo
c97984de99 docs: remove quotes in ldgen documentation for adding fragment file
Closes https://github.com/espressif/esp-idf/issues/5142
2021-06-17 09:13:40 +02:00
laokaiyao
45ee699eae driver/timer: only re-enable alarm in callback when auto reload is true
closes https://github.com/espressif/esp-idf/issues/7001
2021-06-17 10:37:32 +08:00
wangjialiang
4c453660ae ble_mesh: stack: Add check the value of Provisioning Random & Confirmation sent and received by provisioner 2021-06-16 17:03:38 +08:00
Michael (XIAO Xufeng)
fd1a67dd61 Merge branch 'bugfix/spi_flash_cs_setup_v4.1' into 'release/v4.1'
spi_flash: fix cs line setup to make the flash driver more stable(backport v4.1)

See merge request espressif/esp-idf!13964
2021-06-16 07:36:06 +00:00
David Čermák
1f76c9014b Merge branch 'bugfix/start_emac_after_phy_reset_v4.1' into 'release/v4.1'
esp_eth: restart negotiation in esp_eth_start (v4.1)

See merge request espressif/esp-idf!13700
2021-06-16 06:00:32 +00:00
Jiang Jiang Jian
84f3d3e69a Merge branch 'bugfix/enable_pmf_in_iperf_test_v4.1' into 'release/v4.1'
iperf example: set PMF capable to connect to PMF required APs (v4.1)

See merge request espressif/esp-idf!13871
2021-06-16 04:39:17 +00:00
David Čermák
afb5248ec8 Merge branch 'bugfix/mdns_interface_del_crash_v4.1' into 'release/v4.1'
mdns: Fix of crash when wifi interface get deleted and mdns receives the packets(Backport v4.1)

See merge request espressif/esp-idf!13855
2021-06-15 12:00:10 +00:00
Suren Gabrielyan
b1e5705bbd mdns: Fix of crash when wifi interface get deleted and mdns receives the packets
Closes https://github.com/espressif/esp-idf/issues/6973
2021-06-15 16:54:44 +08:00
He Yin Ling
5438706922 Merge branch 'bugfix/example_test_socket_issue_4.1' into 'release/v4.1'
CI: example test socket issue (4.1)

See merge request espressif/esp-idf!13906
2021-06-15 08:48:27 +00:00
Michael (XIAO Xufeng)
cd99f0856c Merge branch 'bugfix/freemodbus_change_max_task_prio_v41' into 'release/v4.1'
Bugfix/freemodbus change max task prio (backport v4.1)

See merge request espressif/esp-idf!13721
2021-06-15 07:55:03 +00:00
Cao Sen Miao
7180526645 spi_flash: fix cs line setup to make the flash driver more stable 2021-06-15 15:11:47 +08:00
Wang Fang
b9ca1e9b48 docs: update the documents based on customer feedbacks 2021-06-15 14:54:11 +08:00
Anton Maklakov
d7612c14c9 Merge branch 'ci/unify_all_target_test_artifacts_paths_v4.1' into 'release/v4.1'
ci: unify target test artifacts to all .log file and $LOG_PATH (v4.1)

See merge request espressif/esp-idf!13850
2021-06-11 07:32:59 +00:00
Island
a22cd6f542 Merge branch 'bugfix/btdm_enable_gattc_cache_will_crash_v4.1' into 'release/v4.1'
component/bt: fix enable gattc nvs cache lead to crash

See merge request espressif/esp-idf!13917
2021-06-10 02:56:50 +00:00
Wang Meng Yang
1f075dc346 Merge branch 'bugfix/btdm_incorrectly_spelled_v4.1' into 'release/v4.1'
component/bt: fix Spelling mistakes (release v4.1)

See merge request espressif/esp-idf!12817
2021-06-09 10:05:53 +00:00
XieWenxiang
9daeddac0b component/bt: Modify some ambiguous descriptions(release v4.1) 2021-06-09 14:14:18 +08:00
Island
4789575f49 Merge branch 'bugfix/bt_impersonation_passkey_fix_v4.1' into 'release/v4.1'
Bluedroid: Check only x component of passkey to avoid passkey impersonation attack. (v4.1)

See merge request espressif/esp-idf!13760
2021-06-09 02:55:44 +00:00
Chen Yudong
dc433b50b0 test: fix socket issue in iperf example test 2021-06-08 17:20:32 +08:00
He Yin Ling
069182853e test: fix iperf example errors:
1. fix TypeError when running with python3
2. fix throughput chart x/y axis label error
3. make test case compatibile with iperf bin on earlier release branches
2021-06-08 17:20:18 +08:00
Chen Yudong
911cc3710b CI: fix connection failures in asio example tests 2021-06-08 17:18:45 +08:00
xiewenxiang
a1f743772f component/bt: fix enable gattc nvs cache lead to crash 2021-06-07 17:56:55 +08:00
Chinmay Chhajed
74b48f1df7 Bluedroid: Check only x component of passkey to avoid passkey impersonation attack. 2021-06-07 07:18:16 +00:00
Ivan Grokhotkov
935deb4082 Merge branch 'bugfix/idfpy_global_action_callbacks_order_v4.1' into 'release/v4.1'
idf.py: Run global_action_callbacks in predictable order (v4.1)

See merge request espressif/esp-idf!13683
2021-06-07 05:09:49 +00:00
Angus Gratton
1e84e87f7f pthread: Fix possible deadlock when using pthread_join() and Debug log level
Possible for a joined task to be deleted at the moment it is logging,
meaning it might hold the stdout lock. In that case the lock isn't
released and the next task to try and take it (i.e. call printf)
will block indefinitely.
2021-06-07 02:15:36 +00:00
Wang Meng Yang
27a3d44f68 Merge branch 'bugfix/invalid_feat_page_exec_v4.1' into 'release/v4.1'
bt controller: Fixed handling for invalid feature page.

See merge request espressif/esp-idf!13573
2021-06-07 01:50:06 +00:00
He Yin Ling
381f2008ac example: set PMF capable to connect to PMF required APs 2021-06-04 17:59:57 +08:00