Commit Graph

583 Commits

Author SHA1 Message Date
David Cermak
0ee4c235eb panic/memprot: Fix minor const string correction on panic print 2021-09-09 11:46:21 +02:00
baohongde
e2fb413329 components/bt: add config option to choose Bluetooth intterupt level. 2021-09-09 11:29:17 +08:00
baohongde
6d63fe06fa components/os: add config option to choose system check intterupt level. 2021-09-09 11:29:12 +08:00
baohongde
8a4696d25a components/os: Fix live lock int bt isr using ocd multicore debug
components/os: Fix live lock in bt isr immediately
2021-09-09 11:29:08 +08:00
baohongde
d1db2df316 components/bt: High level interrupt in bluetooth
components/os: Move ETS_T1_WDT_INUM, ETS_CACHEERR_INUM and ETS_DPORT_INUM to l5 interrupt

components/os: high level interrupt(5)

components/os: hli_api: meta queue: fix out of bounds access, check for overflow

components/os: hli: don't spill registers, instead save them to a separate region

Level 4 interrupt has a chance of preempting a window overflow or underflow exception.
Therefore it is not possible to use standard context save functions,
as the SP on entry to Level 4 interrupt may be invalid (e.g. in WindowUnderflow4).

Instead, mask window overflows and save the entire general purpose register file,
plus some of the special registers.
Then clear WindowStart, allowing the C handler to execute without spilling the old windows.
On exit from the interrupt handler, do everything in reverse.

components/bt: using high level interrupt in lc

components/os: Add DRAM_ATTR to avoid feature `Allow .bss segment placed in external memory`

components/bt: optimize code structure

components/os: Modify the BT assert process to adapt to coredump and HLI

components/os: Disable exception mode after saving special registers

To store some registers first, avoid stuck due to live lock after disabling exception mode

components/os: using dport instead of AHB in BT to fix live lock

components/bt: Fix hli queue send error

components/bt: Fix CI fail

# Conflicts:
#	components/bt/CMakeLists.txt
#	components/bt/component.mk
#	components/bt/controller/bt.c
#	components/bt/controller/lib
#	components/esp_common/src/int_wdt.c
#	components/esp_system/port/soc/esp32/dport_panic_highint_hdl.S
#	components/soc/esp32/include/soc/soc.h
2021-09-09 11:29:06 +08:00
Cao Sen Miao
6c0aebe279 esp_flash: add opi flash support in esp_flash chip driver, for MXIC 2021-09-07 14:44:40 +08:00
boarchuz
ec70bc0523 fix compiler warning with silent panic option 2021-09-04 14:46:26 +10:00
Mahavir Jain
e0d29d4ada esp_system: create ld template to abstract few common settings
PMS aware chips require prefetch padding size for instruction fetch, or
some memory alignment considerations. These settings are now exposed
through kconfig options (hidden) and used through common ld template.
This shall help to add and manage future chips support easily for
these considerations.

Closes IDF-3624
2021-09-02 16:13:17 +08:00
Marius Vikhammer
88e7b5f7be Merge branch 'feature/s3_cache_bringup' into 'master'
soc: S3 cache bringup

Closes IDF-2952

See merge request espressif/esp-idf!12887
2021-09-02 02:51:10 +00:00
Marius Vikhammer
bdf3a8ff29 Merge branch 'feature/xtwdt' into 'master'
WDT: Add support for XTAL32K Watchdog timer

Closes IDF-2575

See merge request espressif/esp-idf!15000
2021-09-02 02:44:47 +00:00
Marius Vikhammer
4869b3cd4a WDT: Add support for XTAL32K Watchdog timer 2021-09-02 09:09:00 +08:00
gaoxiaojie
191a494e08 support dcache 64Byte and 16k 2021-09-02 02:27:40 +08:00
jiangguangming
f7137254e9 flash_mmap: register flash2spiram info to ROM 2021-09-02 02:27:40 +08:00
Armando
a3dc625da6 mspi: support 120MHz Quad Flash and PSRAM on ESP32S3 2021-08-31 16:06:44 +08:00
Martin Vychodil
58aed7df98 ESP32S2: No assert()/abort() in Memprot API, use esp_err_t instead
JIRA IDF-3634
2021-08-26 09:20:00 +02:00
Shu Chen
f8f9e545e8 Merge branch 'feature/support_esp32h2_hw_support' into 'master'
Feature/support esp32h2 hw support

Closes IDF-3378 and IDF-3396

See merge request espressif/esp-idf!14545
2021-08-26 06:00:27 +00:00
sly
11dfd802e0 esp32h2: add rtc clock support 2021-08-26 11:25:39 +08:00
Jiang Jiang Jian
cec0f5edfb Merge branch 'optimization/config_option_LWIP_TCPIP_CORE_LOCKING' into 'master'
optimization config option LWIP_TCPIP_CORE_LOCKING

Closes IDF-2478

See merge request espressif/esp-idf!11809
2021-08-25 08:52:43 +00:00
Wu Zheng Hui
3128a2544b Adjust the variable name &
Add mapping support for different sizes of spi ram
2021-08-25 16:06:28 +08:00
wuzhenghui
6ab495b4dc esp32h2: chip env support
brownout init fixed
2021-08-25 11:02:47 +08:00
Erhan Kurubas
2a5d0a041e gcov: add stub table size entry 2021-08-20 15:00:55 +08:00
Erhan Kurubas
ca88b269ed gcov: add gcov callback into the ipc task 2021-08-20 15:00:55 +08:00
Erhan Kurubas
bbf919709f gcov: added dbg stub capabilites and magic number entry to keep backward compatible 2021-08-20 15:00:55 +08:00
xueyunfei
0d07569fff optimization config option LWIP_TCPIP_CORE_LOCKING 2021-08-18 21:32:13 +08:00
simon.chupin
294f9783fc Tools: Fix memory calculations of idf_size.py 2021-08-11 17:51:51 +02:00
Michael (XIAO Xufeng)
064f12cb90 idf_size.py: fixed diram counted twice issue, and improve display
Currently static RAM usage are listed under corresponding physical
memory.

ld: fix linker script for C3 and S3
2021-08-11 17:51:50 +02:00
Marius Vikhammer
85b107bf54 Merge branch 'bugfix/rename_ext_mem_bss_section' into 'master'
ld: rename .ext_ram.noinit to .ext_ram_noinit

See merge request espressif/esp-idf!14717
2021-08-11 05:51:00 +00:00
Marius Vikhammer
6a2f7b6f88 ld: rename .ext_ram.noinit to .ext_ram_noinit
Older versions of the coredump utility tool do not correctly
handle this nameing scheme. Rename to keep forward compatibility.
2021-08-10 11:13:54 +08:00
Jiang Jiang Jian
6e1f8a68b9 Merge branch 'feature/support_esp32s3_wifi_lightsleep' into 'master'
support esp32s3 wifi lightsleep

Closes IDF-1781

See merge request espressif/esp-idf!14569
2021-08-06 12:51:46 +00:00
Roland Dobai
7384149780 Merge branch 'update_copyright_notice_esp32s2_esp32s3' into 'master'
esp32s2, esp32s3: update copyright notice

See merge request espressif/esp-idf!13831
2021-08-06 10:36:07 +00:00
Jan Brudný
562ce4d009 esp32s2, esp32s3: update copyright notice 2021-08-05 15:01:26 +02:00
Sachin Parekh
6582f7070e Update tests for assert and abort
- Place panic_abort in IRAM
- Added abort, assert test case in case of cache disabled
- Expect assert instead of abort in a freertos_mutex test
2021-08-05 11:09:22 +05:30
Li Shuai
d73a09cd8b light sleep: add wifi mac sleep support for esp32s3 2021-08-04 21:58:33 +08:00
Li Shuai
366d0a724a light sleep: set wifi light sleep clock source to rtc slow clock 2021-08-04 21:31:47 +08:00
Zim Kalinowski
1fd56e0b87 Merge branch 'feature/systimer_generate_rtos_tick' into 'master'
freertos(esp32s3): SysTick uses systimer

Closes IDF-2613

See merge request espressif/esp-idf!12246
2021-08-04 12:33:52 +00:00
Konstantin Kondrashov
29f581fc70 freertos(esp32s3): SysTick uses systimer 2021-08-04 20:33:44 +08:00
Armando (Dou Yiwen)
03fb3973a2 Merge branch 'feature/support_quad_flash_octal_psram_on_esp32s3' into 'master'
mspi: support up-to-80MHz quad flash & up-to-80MHz octal psram on esp32s3

Closes IDF-3603

See merge request espressif/esp-idf!14346
2021-08-04 03:57:16 +00:00
Armando
0f91a01a46 mspi: support up-to-80MHz quad flash & up-to-80MHz octal psram on esp32s3 2021-08-03 16:54:00 +08:00
Konstantin Kondrashov
4972605b16 esp_common: Add API for IPC to run small pieces of code on the other CPU, in the context of the level 4 interrupt 2021-08-03 14:35:29 +08:00
Armando (Dou Yiwen)
0dad76329f Merge branch 'feature/support_noinit_section_in_psram_on_esp32' into 'master'
memory: support noinit section in psram on esp32

Closes IDFGH-2621

See merge request espressif/esp-idf!14088
2021-07-31 09:58:59 +00:00
Jiang Jiang Jian
aebdaf08a6 Merge branch 'bugfix/esp32s3_app_core_clock_gate_invalid_issue' into 'master'
fix app cpu core clock gate invalid issue

Closes WIFI-3899

See merge request espressif/esp-idf!14518
2021-07-31 03:00:58 +00:00
Cao Sen Miao
c29b3e2e36 spi_flash: move the unlock patch to bootloader and add support for GD 2021-07-29 10:46:33 +08:00
Armando
ad8e1a395c memory: port SPIRAM noinit segment support to master 2021-07-29 10:28:39 +08:00
Devan Lai
b85011c15f esp32: Add support for noinit variables in SPIRAM
Add Kconfig option SPIRAM_ALLOW_NOINIT_EXTERNAL_MEMORY
When enabled, a new linker script rule (from esp32.extram.noinit.ld)
places any variables in the .ext_ram.noinit section in SPIRAM.

This section is exempted from the startup SPIRAM memory test and is
not zero-initialized or added to the malloc pool, making it usable
for noinit variables that persist across reset.

The EXT_RAM_NOINIT_ATTR macro places variables in this section.
2021-07-29 10:28:38 +08:00
Li Shuai
8a10ba4179 system: fix app cpu core clock gate invalid issue 2021-07-28 11:34:29 +08:00
Michael (XIAO Xufeng)
18bee2380a Merge branch 'refactor/usb_device_driver' into 'master'
tiny_usb: support on esp32-s3

Closes IDF-3234

See merge request espressif/esp-idf!14293
2021-07-26 16:21:55 +00:00
Martin Vychodil
ce28af2dd4 System/memprot: ESP32C3 IRAM section alignment fix (LD)
IRAM section didn't contain sufficient padding for possible CPU instruction prefetch,
ie instruction fetch could happen in DRAM section which is prohibited by the Memprot module.
This is fixed by adding 16B to the end of IRAM section in LD script (C3 CPU prefetch buffer depth is 4 words)

Closes IDF-3554

* fix
2021-07-23 17:11:12 +02:00
Michael (XIAO Xufeng)
fbb6b1b11a Merge branch 'bugfix/fix_uart_reset_issue_on_esp32c3' into 'master'
bugfix(uart): reset uart0 core before uart apb reset

Closes IDF-3362

See merge request espressif/esp-idf!12749
2021-07-22 07:20:58 +00:00
morris
81448dcae8 tiny_usb: rename Kconfig name
1. Renamed Kconfig file of tinyusb (distinguish tinyusb stack from usb
   peripheral)
2. bugfix/typofix/doc update of tinyusb
2021-07-22 10:43:10 +08:00
KonstantinKondrashov
c19b37d2a9 esp_system: Adds sync of FRC & RTC counters in esp_restart
In case when FRC and RTC counters are very different then
the need to sync them before to restart the ESP
to get the correct system time after reboot.
2021-07-21 10:23:24 +05:00
Wangjialin
2b986fbd49 For esp_restart API, reset uart0 core first, then reset uart0 apb side, so as to prevent uart output garbage after cpu reset. (UART0 RST bits will be cleared in ROM)
Add UART0/1 core reset on esp32c3, in case uart driver would also reset uart hardwares.
2021-07-21 11:41:04 +08:00
morris
2058e89448 Merge branch 'feature/fpga_bootloader' into 'master'
Boot ESP32 & ESP32-S2 apps on FPGA

See merge request espressif/esp-idf!8270
2021-07-18 08:06:38 +00:00
Angus Gratton
c1ca7a35b0 ldgen: Remove some remaining references to TARGET.project.ld.in 2021-07-16 20:14:27 +08:00
Angus Gratton
f0471b18b2 esp32h2: Move from target component to esp_hw_support (new structure) 2021-07-16 20:14:27 +08:00
Renz Bagaporo
b06dba7823 esp32: move app linker scripts 2021-07-16 20:14:27 +08:00
Renz Bagaporo
fddc0b6799 esp32: move remaining tests 2021-07-16 20:14:27 +08:00
Renz Bagaporo
7c22cccb9c esp32: cleanup build script 2021-07-16 20:14:27 +08:00
Angus Gratton
1a626ef6ca esp32: App can boot on FPGA image
Includes fix for detecting ESP32 ECO3 on FPGA
2021-07-16 10:50:06 +10:00
Angus Gratton
bbbbd5cf0c esp32s2: FPGA can boot to Hello World 2021-07-16 10:50:06 +10:00
Omar Chebib
0771bd1711 espsystem: Rearchitecture and fix eh_frame_parser bugs
eh_frame_parser is architecture independent, thus the files have
been rearchitectured. Some bugs have been fixed in the test.
A README file has also been added to eh_frame_parser host test
directory.

eh_frame_parser is now able to detect empty gaps in .eh_frame_hdr
table (missing DWARF information).
Fix a bug occuring when parsing backtraces originated from abort().
Fix build missing dependencies issue.
2021-07-15 12:47:51 +08:00
Omar Chebib
b967dc0dbf espsystem: add support for RISC-V panic backtrace
Add .eh_frame and .eh_frame_hdr sections to the binary (can be
enabled/disabled within menuconfig). These sections are parsed
when a panic occurs. Their DWARF instructions are decoded and
executed at runtime, to retrieve the whole backtrace. This
parser has been tested on both RISC-V and x86 architectures.

This feature needs esptool's merge adjacent ELF sections feature.
2021-07-13 15:42:40 +08:00
morris
1560d6f1ba soc: add reset reasons in soc component 2021-07-13 10:45:38 +08:00
Shu Chen
ee23a489b9 esp32h2: code clean up 2021-07-01 19:53:50 +08:00
Shu Chen
5e3689ae0f esp32h2: update esp_system and esp_hw_support to support esp32h2 2021-07-01 19:53:11 +08:00
Shu Chen
7d4b2617e1 esp32h2: copy esp_system and esp_hw_support from esp32c3
Copy the esp32c3 code without any change:
 * components/esp_hw_support/include/soc/esp32h2
 * components/esp_hw_support/port/esp32h2
 * components/esp_system/port/soc/esp32h2
2021-07-01 19:53:11 +08:00
Angus Gratton
2f8debdde1 Merge branch 'feature/esp32s3_remove_rtc_apb_freq_reg' into 'master'
esp32s3: Remove APB frequency RTC register

See merge request espressif/esp-idf!11137
2021-06-29 23:50:23 +00:00
Angus Gratton
1969e4b8e5 Merge branch 'bugfix/panic_handler_disable_wdts_early' into 'master'
esp_system: Reconfigure the WDTs at the start of the panic handler

Closes IDFCI-361

See merge request espressif/esp-idf!14138
2021-06-29 23:48:40 +00:00
Angus Gratton
57fa883127 esp32s3: Remove APB frequency RTC register
Usage of this register changed between ESP32-S3 beta2 and the
final chip.
2021-06-29 17:38:46 +10:00
Angus Gratton
14c7d4965b esp_system: Reconfigure the WDTs at the start of the panic handler
This is mostly important on ESP32 ECO3 with the
ESP32_ECO3_CACHE_LOCK_FIX, because when we stall the other CPU core
before we disable the TG1 WDT then the first CPU can get stuck
in WDT ISR handle_livelock_int routine waiting for the other CPU.
2021-06-28 17:24:39 +10:00
Ivan Grokhotkov
d7928bf1db Merge branch 'feature/esp32c3_apptrace' into 'master'
apptrace: refactoring & esp32c3 support

See merge request espressif/esp-idf!11702
2021-06-28 06:00:24 +00:00
Michael (XIAO Xufeng)
afc2bc94b3 Merge branch 'feature/add_opi_flash_psram_support' into 'master'
spi flash: opi flash psram support and spi timing tuning  support on 727

Closes IDF-3097

See merge request espressif/esp-idf!12946
2021-06-28 01:59:19 +00:00
Armando
bc248278f8 spiflash: add octal spi psram support on 727 2021-06-25 19:41:57 +08:00
Alexey Gerenkov
20fd09728f apptrace: Adds ESP32-C3 support 2021-06-24 13:16:14 +03:00
Alexey Gerenkov
821869d98d apptrace: Refactors apptrace for better support various tracing HW 2021-06-24 13:16:13 +03:00
Jakob Hasse
64750acbb0 [esp_system]: added __cxx_eh_arena_size_get again
* This function has been accidentally removed.
  It is necessary to provide the emergency
  exception memory pool size for C++ code.
  Since our libstdc++ always has exceptions
  enabled, this function must exist here even if
  -fno-exception is set for user code.
2021-06-22 14:14:08 +08:00
Cao Sen Miao
f2fe0847d5 usb_serial_jtag: add initial support for S3 (including flashing, monitoring, writing, and reading) but console is not avaliable now 2021-06-18 12:42:41 +08:00
Angus Gratton
059353b0c2 Merge branch 'feature/refactor_common_secure_boot_code' into 'master'
secure_boot/flash_encryption: Refactoring

Closes IDF-2582 and IDF-2035

See merge request espressif/esp-idf!12963
2021-06-16 23:21:45 +00:00
Konstantin Kondrashov
f339b3fc96 efuse(esp32): Deprecate esp_efuse_burn_new_values() & esp_efuse_write_random_key()
These functions were used only for esp32 in secure_boot and flash encryption.
Use idf efuse APIs instead of efuse regs.
2021-06-17 07:21:36 +08:00
Marius Vikhammer
f124536948 system: add support for reset reason hint on S3 2021-06-15 13:39:51 +08:00
Angus Gratton
d995086621 Merge branch 'bugfix/memprot_bypass' into 'master'
System/Security: Memprot bypassing mitigation

Closes IDF-2700

See merge request espressif/esp-idf!13795
2021-06-09 00:02:30 +00:00
Jiang Jiang Jian
5cbea220b0 Merge branch 'feature/decouple_esp_phy' into 'master'
esp_phy: decouple esp_phy component from esp_wifi and bt

See merge request espressif/esp-idf!13742
2021-06-04 05:20:17 +00:00
Shu Chen
6061a547e5 esp_phy: decouple esp_phy component from esp_wifi and bt
* add esp-phy-lib submodule
* move libphy.a and phy_init.c from esp_wifi to esp_phy
* move librtc.a from esp_wifi to esp_phy
* move libbtbb.a from bt to esp_phy
* corresponding updates to build system
2021-06-03 16:17:31 +08:00
Angus Gratton
dc6b950257 doc: Add performance guides for execuion speed, binary size, RAM usage
Closes https://github.com/espressif/esp-idf/issues/7007
Closes https://github.com/espressif/esp-idf/issues/6715
Closes https://github.com/espressif/esp-idf/issues/3781
Closes https://github.com/espressif/esp-idf/issues/2566
2021-06-03 13:55:34 +10:00
Martin Vychodil
1e58eb6928 system/security: Memprot bypassing mitigation
Check Memprot lock bit(s) during the system startup, abort/reset on any Memprot parts found locked during this phase.
There is no legal reason to disallow the Memprot configuration by the system, so it's either a critical bug in the
application or an malicious attempt to bypass the system security.
Error message is printed before digital system reset.

Closes IDF-2700
2021-06-01 00:07:09 +02:00
Dmitry
00a7ecb5a3 Code cleanup. Bugfix after rebase with master. Formating. 2021-05-13 15:03:40 +03:00
Dmitry
f8197c2446 Fix problem with panic handler with gdbstubs. 2021-05-11 16:09:32 +03:00
Dmitry
7bb91f912c gdbstub component 2021-05-11 15:55:39 +03:00
Ivan Grokhotkov
c88287851d Merge branch 'feature/raise_log_level' into 'master'
feature: Set maximum log level, add startup time example

Closes IDFGH-3599 and IDFGH-333

See merge request espressif/esp-idf!12714
2021-05-03 08:52:27 +00:00
Jiang Jiang Jian
efb9f87951 Merge branch 'bugfix/fix_728_series_reboot_failure' into 'master'
[system]: Fix two  (re)boot failure issues on ESP32S3Beta

Closes WIFI-3548, WIFI-3559, and IDF-3170

See merge request espressif/esp-idf!13268
2021-04-30 03:20:47 +00:00
Michael (XIAO Xufeng)
76fbb689fd Merge branch 'bugfix/remove_uart2_c3' into 'master'
uart: remove misleading ld files and soc defs for UART2

See merge request espressif/esp-idf!13340
2021-04-29 05:18:25 +00:00
wuzhenghui
57d43d1bc5 fix 728 series reboot failure 2021-04-29 03:10:47 +00:00
Jeroen Domburg
2c75f63f89 * ets_delay_us(1) has too much overhead; change logic
* Fix MR comments
2021-04-28 16:38:24 +08:00
Michael (XIAO Xufeng)
a0d13a31ec uart: fix misleading files for UART2
Includes: header files, ld files and clk.c

ESP32-C3 only have UART0 and UART1.
2021-04-27 17:40:19 +08:00
Angus Gratton
69309c88a0 Merge branch 'bugfix/fix_c3_typos' into 'master'
esp32c3: fix typos of c3 path

See merge request espressif/esp-idf!13318
2021-04-23 13:05:09 +00:00
Shu Chen
ff3320ca8a esp32c3: fix typos of c3 path 2021-04-23 18:11:39 +08:00
Angus Gratton
6e80811ca2 log: Remove redundant definition of LOG_LOCAL_LEVEL
After adding a maximum setting, the default value of LOG_LOCAL_LEVEL
will be CONFIG_LOG_MAXIMUM_LEVEL not CONFIG_LOG_DEFAULT_LEVEL
2021-04-23 18:13:04 +10:00
Ivan Grokhotkov
9069f70db3 system: add option to enable undefined behavior sanitizer (UBSAN)
Closes https://github.com/espressif/esp-idf/issues/1574
2021-04-22 23:33:45 +02:00
Omar Chebib
bb9aa806f7 panic: handlers can now be placed in flash
By unchecking "Place panic handler code in IRAM" in the menuconfig,
the panic handlers will be placed in flash. Of course, flash cache must
be activated when entering panic handlers.
2021-04-15 11:58:46 +08:00
Martin Vychodil
f27c9c5139 esp32c3: memprot API upgrade and test application
Closes IDF-2641
2021-04-12 13:44:11 +10:00
Marius Vikhammer
38d9251bda sleep: disable switch-case jump tables from being placed in flash
sleep_modes.c contains switch statements that should be placed in flash.
Settings for avoiding this was not updated during sleep_modes refactor.
2021-04-09 14:16:27 +08:00
Angus Gratton
cef3b26a91 Merge branch 'refactor/move_from_esp_system' into 'master'
Movements from esp_system

Closes IDF-2165

See merge request espressif/esp-idf!12695
2021-04-08 10:16:08 +00:00
Angus Gratton
70cab5bd81 Merge branch 'bugfix/ulp_riscv_unintended_wake' into 'master'
ulp: unintended wakeup in ulp_riscv

See merge request espressif/esp-idf!12894
2021-04-08 01:52:41 +00:00
Renz Bagaporo
586023790e esp_system: move sleep modes to esp_hw_support, power down light sleep to esp_pm 2021-04-07 17:53:37 +08:00
Renz Bagaporo
c112bd8b57 esp_system: move intr_alloc 2021-04-07 17:53:37 +08:00
Renz Bagaporo
8762bfebde esp_system: move asysnc memcpy to esp_hw_support 2021-04-07 17:53:37 +08:00
Angus Gratton
c22eb769e7 Merge branch 'bugfix/panic_instrprohibited' into 'master'
esp_system: fix instrprohibited panic backtrace regression

See merge request espressif/esp-idf!13023
2021-04-07 05:14:19 +00:00
Angus Gratton
94ac251091 Merge branch 'doc/general_notes' into 'master'
doc: Update docs about startup sequence and memory types

Closes IDF-2321, IDF-2409, and IDFGH-1540

See merge request espressif/esp-idf!12636
2021-04-05 23:51:25 +00:00
Renz Bagaporo
75624c5355 esp_system: fix instrprohibited panic backtrace regression
First PC should have been ignored in the case of InstProhibited panic
when printing backtrace.
2021-04-05 22:05:27 +08:00
Angus Gratton
6b57f33858 Merge branch 'refactor/movements_from_target_components' into 'master'
Movement from target components 1

See merge request espressif/esp-idf!12482
2021-04-05 02:37:21 +00:00
Renz Bagaporo
301c48b6b2 esp_system: remove duplicate panic backtrace code 2021-04-01 07:22:57 +00:00
Angus Gratton
3c9e9a7704 Merge branch 'bugfix/renable_unit_tests' into 'master'
ci: enable previously disabled unit tests

See merge request espressif/esp-idf!12582
2021-04-01 03:23:22 +00:00
Renz Bagaporo
bbc599493e esp32: move common fragment definitions 2021-03-31 19:17:33 +08:00
Renz Bagaporo
4a08264e7a esp_system: split esp_system.h header 2021-03-31 19:13:03 +08:00
Renz Bagaporo
a7bac58480 esp32: move system api to esp_system 2021-03-31 19:13:03 +08:00
Renz Bagaporo
393bd64a1e esp32: move crosscore int 2021-03-31 19:13:03 +08:00
Renz Bagaporo
7d85c42e52 esp32: move brownout and cache err int setup 2021-03-31 19:13:03 +08:00
Renz Bagaporo
6014e3a198 esp32: move stack check test 2021-03-31 19:13:03 +08:00
Renz Bagaporo
3639c2322b ulp: clear rtc int at initialization
Closes https://github.com/espressif/esp-idf/issues/6654
2021-03-31 17:15:55 +08:00
Angus Gratton
d44034c54d Merge branch 'bugfix/dual_core_app_on_single_core_esp32' into 'master'
esp_system: fix dual core app issue on single core esp32

Closes IDF-2154

See merge request espressif/esp-idf!10728
2021-03-31 01:06:52 +00:00
Marius Vikhammer
b4d2fb56a0 ci: enable previously disabled unit tests 2021-03-29 18:36:41 +08:00
Angus Gratton
a2740be080 Merge branch 'refactor/systimer_reset_alternative' into 'master'
Systimer reset alternative on S2 (and others)

See merge request espressif/esp-idf!12694
2021-03-29 09:27:41 +00:00
Renz Bagaporo
8d32232899 esp_system: check early for single core variant 2021-03-29 06:50:47 +00:00
Jiang Jiang Jian
72ddc6ee40 Merge branch 'bugfix/esp32c3_light_sleep_gpio_reset_issue' into 'master'
light sleep: add software workaround for esp32c3 gpio reset issue

See merge request espressif/esp-idf!12715
2021-03-29 04:55:55 +00:00
Angus Gratton
38af9dffe1 esp_system: Mark the startup array as 'const' to save RAM 2021-03-29 15:11:49 +11:00
Renz Bagaporo
32aa5f7e25 esp_system: add notes on timekeeping 2021-03-25 16:09:33 +08:00
Renz Bagaporo
d7e9567c00 esp_system, esp_timer: fix time function description 2021-03-25 15:47:19 +08:00
Renz Bagaporo
131bbbd5c4 esp_system: test system time for rtc compensation 2021-03-25 15:47:19 +08:00
Renz Bagaporo
cb5a8342d4 esp_system: revert reset of systimer clk at startup 2021-03-25 15:37:48 +08:00
Li Shuai
b3bc27972e light sleep: add software workaround for esp32c3 gpio reset issue 2021-03-25 15:03:09 +08:00
Omar Chebib
49f5fb5112 esp_system: add VDD_SDIO power domain configuration to documentation
Add a warning in `sleep_modes` doc page to explain how to keep
VDD_SDIO power domain ON.
2021-03-24 12:04:57 +08:00
Omar Chebib
87325fa964 esp_system: add VDD_SDIO power domain configuration for light sleep
VDD_SDIO power domain can now be configured for light sleep
by the application. It is now possible to keep the power domain
ON during light sleep, keeping the GPIOs connected to it powered.
The power domain will, by default be:
- Kept ON if CONFIG_ESP_SYSTEM_PD_FLASH is not set
- Turned OFF if not set

The application can still force it to be ON by calling
`esp_sleep_pd_config(ESP_PD_DOMAIN_VDDSDIO, ESP_PD_OPTION_ON);`
2021-03-24 12:04:57 +08:00
Angus Gratton
fa2946d651 Merge branch 'feature/support_esp32s3_beta_3' into 'master'
Support ESP32S3 beta 3 target

Closes IDF-2908

See merge request espressif/esp-idf!12661
2021-03-23 10:17:58 +00:00
Michael (XIAO Xufeng)
67ba80f2ec Merge branch 'bugfix/reduce_the_consumption_of_touch_sensor_during_deep_sleep' into 'master'
fix: reduce the consumption of touch sensor during deep sleep

See merge request espressif/esp-idf!12248
2021-03-22 07:10:44 +00:00
Angus Gratton
54edd4fc58 Merge branch 'feature/wdt_c3' into 'master'
wdt: Fix RTC_SLOW_CLK for chips, corrects WDT timeout.

Closes IDF-2118 and IDF-2332

See merge request espressif/esp-idf!12796
2021-03-22 06:48:58 +00:00
Angus Gratton
1581744c10 Merge branch 'feature/main_task_affinity_pr6627' into 'master'
Allow selection of different core for main task

Closes IDFGH-4828

See merge request espressif/esp-idf!12654
2021-03-22 06:46:24 +00:00
KonstantinKondrashov
aa1338bf23 wdt: Fix timeout and RTC_SLOW_CLK
RTC_SLOW_CLK
ESP32:    150kHz
ESP32-S2:  90kHz
ESP32-S3: 150kHz
ESP32-C3: 150kHz
2021-03-19 00:15:18 +08:00
Marius Vikhammer
2aead8ba57 Support ESP32S3 Beta 3 target
Update ROM API. Port changes from bringup branch.
2021-03-18 10:24:22 +08:00
KonstantinKondrashov
a90f29fced wdt: Updates 2021-03-18 02:31:28 +08:00
Michael (XIAO Xufeng)
be30289364 Merge branch 'feature/c3_example_tests' into 'master'
CI: add Example_GENERIC for C3

Closes IDF-2935

See merge request espressif/esp-idf!12557
2021-03-16 09:43:38 +00:00
Angus Gratton
d709631393 secure boot: Add boot check for SBV2 "check app signature on update"
As this mode uses the public keys attached to the existing app's signatures to
verify the next app, checking that a signature block is found on boot prevents
the possibility of deploying a non-updatable device from the factory.
2021-03-15 12:30:20 +00:00
fuzhibo
6b361ed70f fix: reduce the consumption of touch sensor during deep sleep 2021-03-15 03:59:54 +00:00
Marius Vikhammer
c85d949c1f ci: run Example_GENERIC for C3
Add support for running example_GENERIC tests for C3 on label.

Fix examples that fail.
2021-03-15 10:27:07 +08:00
Jiang Jiang Jian
ae65cffff0 Merge branch 'bugfix/esp32c3_light_sleep_default_params_optimize' into 'master'
light sleep: some default parameters optimization

See merge request espressif/esp-idf!12461
2021-03-11 03:33:46 +00:00
Angus Gratton
fd164b82b6 Merge branch 'refactor/move_from_xtensa' into 'master'
Movements from xtensa

Closes IDF-2164

See merge request espressif/esp-idf!10556
2021-03-11 00:24:25 +00:00
Li Shuai
92ddbcda05 deep sleep: power down wifi and bt during deep sleep 2021-03-10 18:22:41 +00:00
baohongde
33df1358ef Fix issues during light sleep and DFS 2021-03-09 13:49:59 +08:00
0xFEEDC0DE64
6928db7670 Allow selection of different core for main task
Closes https://github.com/espressif/esp-idf/pull/6627
2021-03-09 10:13:28 +11:00
Angus Gratton
d6f4d99d93 core system: Fix warnings in compilation when assertions are disabled
Adds a CI config for hello world that sets this, to catch future regressions
2021-03-03 10:26:57 +11:00
fuzhibo
cfe59031a5 fix: clear interrupt in touch sensor initialization 2021-03-01 03:57:01 +00:00
Renz Bagaporo
1efdcd69d9 xtensa: move out trax 2021-02-26 19:45:48 +08:00
Renz Bagaporo
0f03f450ff esp_hw_support: create esp_cpu
Create a esp_cpu header that contains CPU-related functions and
utilities.
2021-02-26 13:34:29 +08:00
Renz Bagaporo
7e0e91bf76 arch: move debug helpers 2021-02-26 13:34:29 +08:00
Renz Bagaporo
91a5770fd2 arch: move shared stack implementation to esp_system 2021-02-26 13:34:29 +08:00
Cao Sen Miao
a8343bc470 esp_system: support gpio wakeup from deep sleep on esp32c3 2021-02-26 12:26:49 +08:00
Angus Gratton
501af6dfa2 Merge branch 'feature/secure_boot_revoke_check' into 'master'
secure_boot: Checks secure boot efuses

Closes IDF-2609

See merge request espressif/esp-idf!12148
2021-02-25 22:38:42 +00:00
Angus Gratton
a0eb455ec3 Merge branch 'refactor/misc_move_from_esp_common' into 'master'
Movements from esp_common

Closes IDF-1947

See merge request espressif/esp-idf!9692
2021-02-24 23:16:52 +00:00
Michael (XIAO Xufeng)
7ef60b8bde Merge branch 'bugfix/gdma_pair_uninstall_concurrency_issue' into 'master'
gdma: fix wrong level of {group,pair} reference count

See merge request espressif/esp-idf!12269
2021-02-24 09:33:33 +00:00
Angus Gratton
f72c296827 Merge branch 'bugfix/deepsleep_disable_brownout_s2' into 'master'
deep_sleep: on S2 disable the brown out detector before deep sleeping

Closes IDF-2716 and IDFGH-4341

See merge request espressif/esp-idf!12348
2021-02-24 05:48:19 +00:00
Renz Bagaporo
43f6c7a533 esp_common: simplify component build script 2021-02-24 12:16:37 +08:00
Renz Bagaporo
349f0cad3e esp_common: other movements 2021-02-24 12:16:37 +08:00
Renz Bagaporo
51e66d0f82 esp_common: move configs 2021-02-24 12:16:37 +08:00
Renz Bagaporo
03dce3668c esp_common: move tests 2021-02-24 12:16:37 +08:00
Renz Bagaporo
5e8799bbfe esp_common: move some headers 2021-02-24 12:16:37 +08:00
Renz Bagaporo
c16ceafa5c esp_common: move esp_err 2021-02-24 12:16:37 +08:00
Renz Bagaporo
91287f424b esp_common: move shared stack 2021-02-24 12:16:37 +08:00
Renz Bagaporo
0e0914476c esp_common: move freertos hooks 2021-02-24 12:16:37 +08:00
Renz Bagaporo
840e2c0e50 esp_common: move stack check 2021-02-24 12:16:37 +08:00
Renz Bagaporo
883aba20be esp_common: move stack check 2021-02-24 12:16:37 +08:00
Renz Bagaporo
5a56f794ec esp_common: move dbg stubs 2021-02-24 12:16:37 +08:00
Renz Bagaporo
1d55e6d6b8 esp_common: move brownout init 2021-02-24 12:16:37 +08:00
Renz Bagaporo
deaad431f4 esp_common: move task, int wdt 2021-02-24 12:16:37 +08:00
Renz Bagaporo
5fce7f4a41 esp_common: move dbg_stubs 2021-02-24 12:16:37 +08:00
morris
e926298160 async_mcp: clean eof flag when prepare rx descriptors 2021-02-24 11:38:57 +08:00
KonstantinKondrashov
90f2d3199a secure_boot: Checks secure boot efuses
ESP32 V1 and V2 - protection bits.
ESP32xx V2: revoke bits, protection bits

- refactor efuse component
- adds some APIs for esp32 chips as well as for esp32xx chips
2021-02-23 03:56:21 +08:00
morris
bf2480f62d efuse: can disable boot ROM log from Kconfig 2021-02-22 20:56:43 +08:00
morris
0f5d1c1c46 rtc: supported disable rom log temporarily 2021-02-22 20:56:43 +08:00
Marius Vikhammer
0a4e5c99f9 deep_sleep: on S2 disable the brown out detector before deep sleeping
On S2 the brown out detector would occasionally trigger erroneously during deep sleep.

Disable it before sleeping to circumvent this issue.

Closes https://github.com/espressif/esp-idf/issues/6179
2021-02-18 18:39:06 +08:00
Angus Gratton
807c8549e1 Merge branch 'bugfix/esp32s2_wakeup_from_light_sleep_fix' into 'master'
esp32s2 light sleep fix

Closes IDFCI-122

See merge request espressif/esp-idf!10269
2021-02-11 07:34:57 +08:00
morris
e361498a2a intr_alloc: re-enable unit test 2021-02-02 20:25:50 +08:00
Angus Gratton
dfda84c2ab esp_system: Fix some ESP_EARLY_LOG lines not being output fully
At least on ESP32, calling esp_rom_uart_set_clock_baudrate() causes the
contents of the UART FIFO to be discarded.
2021-02-01 14:24:38 +11:00
Jiang Jiang Jian
28faf93c51 Merge branch 'feature/esp32c3_power_down' into 'master'
esp32c3 : power down MAC and BB only if both Wi-Fi and BT power down

Closes FC3-99

See merge request espressif/esp-idf!12076
2021-01-28 23:27:19 +08:00
baohongde
eef66789d4 Mac BB power down in light sleep
components/bt: Do not use feature: timer support isr dispatch method

disable controller after wake up finished.

protect critical section of power down

choose clk in sleep

components/coex: mac bb power down in light sleep

components/coex: Macro changed

components/os: protect reserved interrupt number

update phy to phy_version 300,6e46ba7,Jan 25 2021

some bugfix
2021-01-28 22:28:04 +08:00
Ivan Grokhotkov
9a20283485 Merge branch 'bugfix/scan_test_missing_build_apps_without_tests' into 'master'
ci: bugfix: scan_test missing build apps without tests

See merge request espressif/esp-idf!12138
2021-01-28 17:48:24 +08:00
Martin Vychodil
69096ddce5 Security: ESP32C3 memory protection feature (IRAM0/DRAM0)
Software support for PMS module.
Allows controlled memory access to IRAM (R/W/X) and DRAM0 (R/W)
On/locked by default, configurable in Kconfig (esp_system)

Closes https://jira.espressif.com:8443/browse/IDF-2092
2021-01-27 08:44:03 +01:00
Jiang Jiang Jian
d097988608 Merge branch 'bugfix/keep_esp_rtc_time_correct' into 'master'
newlib: Keep esp rtc time correct

See merge request espressif/esp-idf!11932
2021-01-27 15:22:43 +08:00
Fu Hanxi
e4e375f488 fix: add spi_flash.h for s2, s3, c3 targets in cpu_start.c
update s2, s3, c3 ld files spi_flash_attach to esp_rom_spiflash_attach
2021-01-27 12:35:49 +08:00
Angus Gratton
b432fc8853 esp_system: Enable deep sleep reset reason test for ESP32-C3 2021-01-25 17:20:04 +00:00
Angus Gratton
d3ffaf4684 esp_system: Add soc_caps guards in esp_sleep.h 2021-01-25 17:20:04 +00:00
Angus Gratton
4026e7b250 esp_system esp32c3: Fix uart flush on entering deep sleep 2021-01-25 17:20:04 +00:00
Michael (XIAO Xufeng)
d7d1dee208 system: reset dma when soft reset 2021-01-25 04:51:40 +00:00
Chen Jian Xing
f71adec8fb Support ESP32S3 (beta2) WiFi 2021-01-25 00:18:42 +08:00
Renz Bagaporo
59f7242de1 ci: revert disable esp32s2 timer test 2021-01-22 14:51:50 +08:00
Renz Bagaporo
2dc7b556f3 esp32s2: reset systimer clk on startup 2021-01-22 14:51:50 +08:00
Jiang Jiang Jian
9c5a9ae8fd Merge branch 'bugfix/support_esp32c3_lightsleep_master_cpu_pd_issue' into 'master'
fix cpu pd bug of normal light sleep

See merge request espressif/esp-idf!12083
2021-01-22 14:03:10 +08:00
Angus Gratton
3532f52f60 Merge branch 'bugfix/ldgen_ignore_nonexistent_archives_and_obj' into 'master'
ldgen: check mappings

Closes IDF-1624

See merge request espressif/esp-idf!8557
2021-01-21 15:59:35 +08:00
ninh
25dcc68b5d newlib: keep esp_rtc_get_time_us when rewrite the value of RTC_SLOW_CLK_CAL_REG 2021-01-21 02:28:21 +00:00
Li Shuai
58ab3975ea light sleep: fix cpu pd bug of normal light sleep 2021-01-21 10:03:39 +08:00
Li Shuai
6ef2a7def0 bootloader: fix external 32k xtal not found error 2021-01-20 16:51:20 +08:00
Jiang Jiang Jian
26ae354dc5 Merge branch 'feature/support_esp32c3_lightsleep_master' into 'master'
support esp32c3 lightsleep for master

Closes IDF-2106

See merge request espressif/esp-idf!11975
2021-01-20 16:00:06 +08:00
Angus Gratton
55970fe3a2 Merge branch 'feature/esp32c3_support_brownout' into 'master'
esp32c3: Adds support BROWNOUT reset

Closes IDF-2397

See merge request espressif/esp-idf!11910
2021-01-20 12:19:56 +08:00
Li Shuai
f168ac3b39 light sleep: add cpu power down support for esp32c3 2021-01-19 14:51:50 +08:00
Li Shuai
a43de3a44b fix set UART_FORCE_XOFF can't stop new Tx request issue 2021-01-19 14:51:22 +08:00
Li Shuai
ac7d1bec76 light sleep: overhead time accuracy optimization for esp32c3 2021-01-19 14:50:58 +08:00
Li Shuai
aa7fd175b9 light sleep: light sleep support for esp32c3 2021-01-19 14:50:58 +08:00
Renz Bagaporo
d1c800fbbb components: fix ldgen check errors 2021-01-19 11:17:18 +08:00
KonstantinKondrashov
d81a93ae4c esp32c3: Adds support BROWNOUT reset 2021-01-18 15:38:09 +08:00
ninh
659d805411 esp_wifi: light sleep optimization 2021-01-18 15:31:03 +08:00
Angus Gratton
5938b9a892 Merge branch 'feature/support_esp32c3_master_cmake_reset_reason' into 'master'
esp32c3: Add UTs for reset_reason

Closes IDF-2091

See merge request espressif/esp-idf!11546
2021-01-18 07:12:21 +08:00
Konstantin Kondrashov
d23c7690f2 esp32c3: Add UTs for reset_reason 2021-01-18 07:12:21 +08:00
ninh
27aa6c289f components/pm: Add slp gpio configure workaround 2021-01-15 15:34:45 +08:00
Michael (XIAO Xufeng)
2d3f22918f Merge branch 'feature/gdma_channel_allocator' into 'master'
gdma channel allocator

Closes IDF-2124

See merge request espressif/esp-idf!11570
2021-01-14 10:52:49 +08:00
Angus Gratton
f683db7aea Merge branch 'feature/c3_IDF-2554' into 'master'
global: Uses CCOUNT API instead of XTHAL macro

Closes IDF-2554

See merge request espressif/esp-idf!11954
2021-01-13 12:55:21 +08:00
Angus Gratton
820639cede Merge branch 'bugfix/c3_init_priority' into 'master'
fix[cxx/system]: init_priority ordering on RISCV

Closes IDF-2206 and IDFGH-4527

See merge request espressif/esp-idf!11660
2021-01-13 12:52:21 +08:00
Angus Gratton
9769be3fde Merge branch 'bugfix/fix_sign_compare' into 'master'
global: fix sign-compare warnings for system level components

See merge request espressif/esp-idf!11252
2021-01-13 12:45:05 +08:00
morris
40a6a0fac6 async_mcp: apply gdma driver 2021-01-13 10:52:27 +08:00
ninh
6dd6c8c3cf ci: fix IDFCI-377 2021-01-12 13:04:53 +00:00
KonstantinKondrashov
dada7cd035 global: Uses CCOUNT API instead of XTHAL macro 2021-01-12 16:24:23 +08:00
morris
753a929525 global: fix sign-compare warnings 2021-01-12 14:05:08 +08:00
Marius Vikhammer
9c8e4fd4c5 C3: build and run unit tests
Enable building and running of unit tests in CI for C3 as well as fix
related compile errors

Also enables building of C3 test apps
2021-01-11 11:34:37 +08:00
Chen Jian Xing
5b44295cb9 esp_wifi: fix esp32c3 code issues
1. enable wifi clk and rm dport header
2.syn phy_init_data.h from esp32
2021-01-10 16:16:28 +08:00
Jakob Hasse
ed42758549 [cxx/system]: fix init_priority ordering on RISCV
* C++ init_priority attributes work now on RISCV
* Add debug output for init_array functions

Closes IDF-2206
Closes https://github.com/espressif/esp-idf/issues/6351
2021-01-07 16:04:17 +08:00
Jiang Jiang Jian
c05321424f Merge branch 'bugfix/lightsleep_accuracy_opt' into 'master'
Lightsleep overhead time accuracy optimization

See merge request espressif/esp-idf!11291
2021-01-06 14:02:10 +08:00
Angus Gratton
da44e06f02 Merge branch 'feature/riscv_test_branch_cleanup' into 'master'
cleanup: move freertos code out from riscv component plus complete the interrupt-allocator implementation for C3

Closes IDF-2126, IDF-2228, IDF-2301, and IDF-2545

See merge request espressif/esp-idf!11136
2021-01-06 12:36:29 +08:00
Jiang Jiang Jian
eb9c2d584f Merge branch 'bugfix/fix_tx_issue_after_esp_restart' into 'master'
components/bt: Shutdown Bluetooth before esp_restart.

See merge request espressif/esp-idf!11698
2021-01-06 12:32:03 +08:00
ninh
dc7bdb9857 adjust lightsleep overhead time and cali slowclk 2021-01-06 03:40:28 +00:00
ninh
e908a32381 put pm_slp_iram_opt and pm_rtos_iram_opt related attributes in esp_pm/linker.lf 2021-01-06 03:40:28 +00:00
morris
9e7d2c0065 esp32c3: format and clean up interrupt and os port code 2021-01-05 15:39:46 +08:00
Felipe Neves
5d316ac142 interrupt: added INTC FLEXIBLE capabillity to esp32c3 CPU caps 2021-01-05 15:39:46 +08:00
Felipe Neves
544a3f7df5 interrupt-allocator: reject vector allocation if its marked as not-implemented. and search to next available 2021-01-05 15:39:46 +08:00
Felipe Neves
09bc1580be intr_allocator: add abstractions for priority, type and edge-ack interrupt controller functions 2021-01-05 15:39:46 +08:00
Omar Chebib
c218f669ba panic on RISC-V: Take into account Merge Request comments 2020-12-31 15:46:17 +08:00
Ivan Grokhotkov
5962b1dc56 panic: print register dump on abort for RISC-V
Register values are necessary to perform host-side backtracing on
RISC-V. Print them in case of an abort as well.
2020-12-31 15:46:17 +08:00
Omar Chebib
b6a450f824 panic: Add support for SoC-level panic
SoC level exceptions such as watchdog timer and cache errors are now supported.
Such exceptions now triggers a panic, giving more information about how
and when it happened.
2020-12-31 15:46:17 +08:00
Marius Vikhammer
eed154a583 esp_system: sync with C3 changes
Fixes interrupt allocation issue
2020-12-31 15:20:05 +11:00
Marius Vikhammer
f54e9269f3 esp_system: Don't compile sleep_mode.c on c3 2020-12-31 15:20:05 +11:00
Marius Vikhammer
68608f804c esp32c3: Misc fixes needed to build & run 2020-12-31 15:20:05 +11:00
Marius Vikhammer
3458469204 newlib: Update esp32c3 ROM support, use single init function 2020-12-31 09:27:37 +11:00
Angus Gratton
62cc864cbe Merge branch 'feature/c3_hw_sup_merge_master' into 'master'
esp_hw_support: merge C3 changes to master

See merge request espressif/esp-idf!11820
2020-12-30 20:06:23 +08:00
Marius Vikhammer
eb788deb03 esp_hw_support: merge C3 changes to master
Merge RTC related C3 changes to master
2020-12-30 12:20:41 +08:00
Ivan Grokhotkov
b7b9ea4361 newlib: add _RETARGETABLE_LOCKING support
This adds support for the retargetable locking implementation in
newlib 3. This feature will be enabled in the future toolchain builds.
With the present version of the toolchain, this code doesn't get used.

When _RETARGETABLE_LOCKING gets enabled, newlib locking implementation
will be modified as follows:

- Legacy ESP-specific _lock_xxx functions are preserved. This is done
  because ROM copies of newlib in ESP32 and ESP32-S2 rely on these
  functions through the function pointer table. Also there is some
  code in IDF which still uses these locking functions.

- New __retarget_lock_xxx functions are introduced. Newlib expects
  these functions to be provided by the system. These functions work
  pretty much the same way as the ESP-specific _lock_xxx functions,
  except one major difference: _lock_acquire receives the lock pointer
  by value, and as such doesn't support lazy initialization.

- Static locks used by newlib are now explicitly initialized at
  startup. Since it is unlikely that these static locks are used at
  the same time, all compatible locks are set to point to the same
  mutex. This saves a bit of RAM. Note that there are still many locks
  not initialized statically, in particular those inside FILE
  structures.
2020-12-29 16:18:04 +01:00
Ivan Grokhotkov
7f3b16a99d freertos: always enable static allocation
to use it for newlib locks
2020-12-29 16:18:04 +01:00
Angus Gratton
1b0442b963 Merge branch 'feature/unify_rtc_fast_mem_as_heap_config_across_chips' into 'master'
esp_system: make rtc fast memory to heap configuration unified across chips

Closes IDF-2503

See merge request espressif/esp-idf!11693
2020-12-29 11:41:05 +08:00
Mahavir Jain
880a63b2e9 esp_system: make rtc fast memory to heap configuration unified across chips
Closes IDF-2503
2020-12-24 09:46:35 +05:30
Angus Gratton
61c77d9212 esp_system: Add port-specific esp32c3 files 2020-12-24 13:40:01 +11:00
Angus Gratton
55155c3f82 esp_system: Rename _init_start symbol to _vector_table 2020-12-24 13:40:01 +11:00
Angus Gratton
cfbded2ea1 esp_system: Add extra MMU config step for ESP32-C3 2020-12-24 13:40:01 +11:00
Angus Gratton
01696afc34 esp32c3: Add new esp_sleep_is_valid_wakeup_gpio() function 2020-12-24 13:40:01 +11:00
Angus Gratton
a5aac93051 esp_rom: Small changes for esp32c3 support
Updated from internal commit 6d894813
2020-12-24 13:40:01 +11:00
Liu Ning
57aa65eeed components/pm: Add sleep related code iram opt chioce 2020-12-23 14:45:36 +08:00
baohongde
3b0fc48ab4 components/bt: Shutdown Bluetooth before esp_restart. 2020-12-21 20:08:10 +08:00