Commit graph

5412 commits

Author SHA1 Message Date
Jiang Jiang Jian cd6bbaa727 Merge branch 'bugfix/bootloader_map_size_v3.2' into 'release/v3.2'
bootloader: fix incorrect mapping size (backport v3.2)

See merge request idf/esp-idf!4138
2019-01-24 14:09:35 +08:00
Jiang Jiang Jian 55b8f2ea8c Merge branch 'bugfix/sha_ownership_v3.2' into 'release/v3.2'
hwcrypto sha: Allow SHA contexts to be shared between tasks (backport v3.2)

See merge request idf/esp-idf!4143
2019-01-24 14:08:35 +08:00
Jiang Jiang Jian 1ae9a2ae0b Merge branch 'bugfix/wifi_fix_invalid_csi_data_index_v3.2' into 'release/v3.2'
esp32: fix invalid channel state information(CSI) data index (backort v3.2)

See merge request idf/esp-idf!4129
2019-01-23 22:14:04 +08:00
Jiang Jiang Jian 28eb488892 Merge branch 'bugfix/vfs_unregister_nested_v3.2' into 'release/v3.2'
vfs: fix unregister removing top level VFS instead of nested (backport v3.2)

See merge request idf/esp-idf!4137
2019-01-23 21:54:50 +08:00
Jiang Jiang Jian fcf1dba9cd Merge branch 'bugfix/init_memctl_v3.2' into 'release/v3.2'
bootloader, esp32: add workaround for Tensilica erratum 572 (backport v3.2)

See merge request idf/esp-idf!4134
2019-01-23 21:43:58 +08:00
Angus Gratton 94ed7b8298 hwcrypto sha: Use spinlocks instead of semaphores for small state changes
Significant performance improvement and smaller RAM footprint.
2019-01-23 18:18:13 +08:00
Angus Gratton 24fab0b7a9 hwcrypto sha: Allow SHA contexts to be shared between tasks
Previously, hardware SHA engine "locks" were mutex semaphores. This meant that the task which
started a particular SHA session (in hardware) needed to finalise that session, or an invalid
FreeRTOS state was created.

Replace with binary semaphore which can be shared between tasks.

Includes a unit test, but unit test doesn't crash even without this fix
(some other unknown condition is required).
2019-01-23 18:18:13 +08:00
Angus Gratton c4c1af114e Update esptool.py to v2.6 2019-01-23 17:02:02 +08:00
Ivan Grokhotkov b1ee25afde bootloader: account for load address when mapping cache pages
Bootloader used to calculate the number of cache pages assuming that
load address was aligned, while in reality load address for DROM and
IROM was offset by 0x20 bytes from the start of 64kB page. This
caused the bootloader to map one less page if the size of the image
was 0x4..0x1c less than a multiple of 64kB.

Reported in https://esp32.com/viewtopic.php?f=13&t=6952.
2019-01-23 17:02:02 +08:00
Ivan Grokhotkov cccaa68467 bootloader: fix IROM and DROM swapped in log messages 2019-01-23 17:02:02 +08:00
Ivan Grokhotkov 6080767379 vfs: fix unregister removing top level VFS instead of nested
Credits @neoniousTR.

Fixes https://github.com/espressif/esp-idf/pull/2770
2019-01-23 16:28:48 +08:00
Ivan Grokhotkov 42b6c4953d bootloader, esp32: add workaround for Tensilica erratum 572
If zero-overhead loop buffer is enabled, under certain rare conditions
when executing a zero-overhead loop, the CPU may attempt to execute an invalid instruction. Work around by disabling the buffer.
2019-01-23 16:23:56 +08:00
XiaXiaotian 746e831c19 esp32: fix invalid channel state information(CSI) data index
Due to a hardware limitation in ESP32, the first four bytes of some
    CSI data is invalid, not the last four bytes.

    Correct a mistake of CSI sub-carrier index in documentation.
2019-01-22 20:30:05 +08:00
Tian Hao a953f73c64 Fix some bugs in phy
1. fix bug PHY/RTC functions called in ISR (update phy to v4007)
2. add UnitTest to test it
3. fix task watchdog bug when wifi change channel
4. disable/enable agc to mac deinit/init
2019-01-16 22:04:49 +08:00
jack a80bfc1dcf esp32: fix the incorrect tx complete state issue 2019-01-12 19:40:52 +08:00
Liu Zhi Fu ca54a5ce2a esp32: fix wrongly deleting hardware BA index bug
Fix the bug that hardware BA index will be wrongly removed in
WiFi mode WIFI_MODE_APSTA.
2019-01-11 21:46:28 +08:00
XiaXiaotian f0a6432717 esp32: do defragmentation only for data and management frame
Check frame type before defragmentation. Only data and management frame
    can do defragmentation.
2019-01-10 14:17:21 +08:00
Jiang Jiang Jian c18e86a826 Merge branch 'bugfix/coex_unforce_wifi_if_no_data_buffered_in_beacon_v3.2' into 'release/v3.2'
esp32: unforce wifi if receiving beacon with no data buffered in dream (backport v3.2)

See merge request idf/esp-idf!4036
2019-01-10 14:11:02 +08:00
Jiang Jiang Jian b5d53a0eff Merge branch 'bugfix/timer_delete_dispatch_race_v3.2' into 'release/v3.2'
esp_timer: do not allow deleting timers while callbacks are dispatched (backport v3.2)

See merge request idf/esp-idf!4062
2019-01-10 13:44:15 +08:00
XiaXiaotian 10afc3de77 esp32: unforce wifi if receiving beacon with no data buffered in dream
state and reduce force receiving broadcast data time

    1. If receiving beacon which indicates that there is no data buffered,
    do not force to receive WiFi data.
    2. If receiving beacon which indicates that there is broadcast data
    buffered, reduce the time to force receiving broadcast data.
2019-01-09 14:13:08 +08:00
Jiang Jiang Jian ec7909956d Merge branch 'bugfix/fix_mbox_thread_safe_issue_v3.2' into 'release/v3.2'
tcpip: fix mbox thread-safe issue  (backport v3.2)

See merge request idf/esp-idf!4005
2019-01-09 10:21:22 +08:00
Ivan Grokhotkov d9c3a08813 Merge branch 'bugfix/mdns_udp_send_protected_backport3.2' into 'release/v3.2'
mdns networking udp send protected (Backport 3.2)

See merge request idf/esp-idf!4020
2019-01-08 12:04:23 +08:00
Ivan Grokhotkov eb9a93f9b7 Merge branch 'bugfix/mdns_crash_when_query_backport3.2' into 'release/v3.2'
mdns crash when query (backport 3.2)

See merge request idf/esp-idf!3950
2019-01-08 12:03:52 +08:00
Jiang Jiang Jian 710019a47f Merge branch 'bugfix/fix_the_country_code_bug_v3.2' into 'release/v3.2'
wifi: fix the bug that STA can scan the channel out of the country regdomain range (backport v3.2)

See merge request idf/esp-idf!4068
2019-01-07 20:33:02 +08:00
zhangyanjiao b80eba8d5a wifi: fix the bug that STA can scan the channel out of the country regdomain range 2019-01-04 14:34:36 +08:00
Liu Zhi Fu efa70bc8e3 lwip: fix mbox thread-safe issue
Fix a mbox free thread-safe issue that can lead to crash in sys_arch_mbox_fetch.
2019-01-02 22:48:19 +08:00
Ivan Grokhotkov 31b7db5c38 esp_timer: do not allow deleting timers while callbacks are dispatched
timer_process_alarm function of esp_timer holds a spinlock for the
entire duration of its operation, except for the time when timer
callback function is called. It is possible that when
timer_process_alarm releases the spinlock, a higher priority task may
run and delete the timer. Then the execution will return to
timer_process_alarm, and this will either cause a crash, or undesired
execution of callback after the timer has been stopped or deleted.

To solve this problem, add a mutex which will prevent deletion of timers
while callbacks are being dispatched.
2019-01-02 20:06:06 +11:00
Mahavir Jain 62eb0f4c12 i2s: add (optional) support to clear tx descriptor in underflow case
It has been observed that, in case of underflow (data unavailability) in
I2S transmission, previously filled up tx descriptors continue to get
transmitted on line, causing noise in case of audio use case.

This change adds optional `tx_desc_auto_clear` field during I2S driver intialization
than can zero initialize tx descriptor in case of underflow situation in
interrupt handler itself.

Closes: https://github.com/espressif/esp-idf/issues/1789
(cherry picked from commit 765bf674d0)
2018-12-31 13:42:26 +05:30
Jiang Jiang Jian 155f034b1e Merge branch 'feature/freemodbus_move_rs485_mode_control_v3.2' into 'release/v3.2'
examples: freemodbus port serial slave move uart mode settings into example (backport v3.2)

See merge request idf/esp-idf!4015
2018-12-29 10:28:27 +08:00
Jiang Jiang Jian 47dea73b03 Merge branch 'doc/btdm_modem_sleep_EVED_mode_for_v3.2' into 'release/v3.2'
doc/btdm_modem_sleep_EVED_mode_for_v3.2(backport v3.2)

See merge request idf/esp-idf!4016
2018-12-29 10:27:52 +08:00
Jiang Jiang Jian 28fdf96828 Merge branch 'bugfix/ota_magic_byte_issue_v3.2' into 'release/v3.2'
Bugfix/ota magic byte issue v3.2(backport v3.2)

See merge request idf/esp-idf!4004
2018-12-29 10:24:24 +08:00
Jiang Jiang Jian 3969fe0dad Merge branch 'bugfix/lwip_add_hostname_option_in_dhcp_discover_v3.2' into 'release/v3.2'
add hostname option in dhcp discover (backport v3.2)

See merge request idf/esp-idf!3938
2018-12-29 10:07:50 +08:00
Jiang Jiang Jian c70c25afd0 Merge branch 'mesh/bugfix_v3.2' into 'release/v3.2'
mesh: when no parent is found, send probe request

See merge request idf/esp-idf!3940
2018-12-28 14:02:23 +08:00
Jiang Jiang Jian d59d9eef4f Merge branch 'bugfix/bbpll_wakeup_reset_v3.2' into 'release/v3.2'
BBPLL reset fixes (backport v3.2)

See merge request idf/esp-idf!4011
2018-12-24 18:16:47 +08:00
David Cermak 22514e12d8 mdns: fix networking running udp_sendif from lwip thread 2018-12-21 16:44:15 +01:00
David Cermak f48ffb37f2 mdns: check all mallocs for failure and add default hook to log error with free heap
solves crash about _mdns_result_txt_create when stress test
2018-12-21 16:27:58 +01:00
David Cermak 0f041ee7bb mdns: fixed static memory leak 2018-12-21 16:26:39 +01:00
David Cermak c320a3ee4c mdns: resolve memory leak when txt record received multiple times 2018-12-21 16:26:39 +01:00
David Cermak 1f35716ef4 mdns: skip sending search when finished, not properly locked timer task 2018-12-21 16:26:39 +01:00
wangmengyang 358de85eb3 component/bt: add more information and description for bluetooth modem sleep
Add remark that "EVED" mode for bluetooth modem sleep is only used for internal test
2018-12-21 19:29:47 +08:00
qiyueixa 84277e5887 mesh: when no parent is found, send probe request via broadcast
1. fix error in checking Wi-Fi commit ID.
2018-12-21 17:49:58 +08:00
Jiang Jiang Jian 52a70e0489 Merge branch 'bugfix/ext_ram_bss_align_v3.2' into 'release/v3.2'
Fix ext_ram_bss alignment crash (backport v3.2)

See merge request idf/esp-idf!4014
2018-12-21 17:31:33 +08:00
aleks 6523d912f2 examples: freemodbus port serial slave move uart mode settings into example
Update freemodbus component file esp-idf/components/freemodbus/port/portserial.c to remove UART mode settings;
Move UART mode settings into esp-idf/examples/protocols/modbus_slave/main/freemodbus.c
Move UART pin settings from Component config into example Kconfig.projbuild file
Move setup of UART port pins from freemodbus component into example file

TW#27721
Closes https://github.com/espressif/esp-idf/issues/2784#issuecomment-443600157
2018-12-21 09:54:26 +01:00
Angus Gratton aa0d2078b7 psram: Use 8-bit type for _ext_ram_bss_start/_ext_ram_bss_end
Fixes pointer arithmetic when printing size of remaining heap
2018-12-21 19:03:12 +11:00
Angus Gratton 348d6d5d3f multi_heap: Fix bug when start of heap is unaligned
Alignment was accounted for in one place only.

TW27954
2018-12-21 19:03:12 +11:00
Angus Gratton 46228db9a8 linker external bss: Align end of ext bss to word boundary
TW27954
2018-12-21 19:03:12 +11:00
Jiang Jiang Jian 2cac11f162 Merge branch 'bugfix/btdm_fix_crash_adv_scan_coex_v3.2' into 'release/v3.2'
component/bt: fix crash when adv and scan coex and optimize duplicate scan (backport v3.2)

See merge request idf/esp-idf!3994
2018-12-21 15:59:53 +08:00
Jiang Jiang Jian 64eeee4532 Merge branch 'bugfix/btdm_fix_two_bugs_about_pairing_v3.2' into 'release/v3.2'
components/bt: Fix two bugs about pairing(backport 3.2)

See merge request idf/esp-idf!3995
2018-12-21 14:26:19 +08:00
Ivan Grokhotkov c7a297195f soc/rtc: reset another BBPLL related register
Follow-up to b21ffc8a: an additional register needs to be reset.

Ref. https://github.com/espressif/esp-idf/issues/2711
2018-12-21 12:40:08 +08:00
Ivan Grokhotkov 19e96add8a soc/rtc: reset BBPLL configuration after enabling it
A workaround to reset BBPLL configuration after light sleep. Fixes the
issue that Wi-Fi can not receive packets after waking up from light
sleep.

Ref. https://github.com/espressif/esp-idf/issues/2711
2018-12-21 12:39:49 +08:00