Commit Graph

177 Commits

Author SHA1 Message Date
Jiang Jiang Jian
5e319c6760 Merge branch 'bugfix/fix_onebyte_watchpoint_setting_v5.0' into 'release/v5.0'
fix(riscv): supports 1 byte and larger than 64byte range watchpoint setting (v5.0 )

See merge request espressif/esp-idf!27216
2023-12-15 19:29:57 +08:00
wuzhenghui
ead822e6ee
fix(esp_hw_support): fix lightsleep current leakage on usb-phy controlled pad 2023-11-23 10:21:02 +08:00
wuzhenghui
8c34ab0e67 fix(riscv): supports 1 byte and larger than 64byte range watchpoint setting 2023-11-22 03:12:06 +00:00
harshal.patil
6fdbd027c5
feat(esp_hw_support): Add locking layer for the ECC peripheral 2023-09-29 11:24:34 +05:30
Lou Tianhao
0c09543d65 feat(pm): add internal pull-up/downs option for gpio used for deepsleep wakeup 2023-09-20 17:30:18 +08:00
Linda
9fb3f19e3a docs: Updated wakeup GPIOs for ESP32-S2, ESP32-S3, ESP32-C6 and ESP32-H2 2023-09-12 11:17:07 +08:00
Planck (Lu Zeyu)
5a5fae5f1e fix(intr_flags_to_level): fix value returned one more than correct value 2023-08-21 10:09:00 +08:00
Lou Tianhao
3727d56c82 Change: rewrite EXT1 triggle mode all_low to any_low when not esp32 2023-07-25 17:53:33 +08:00
Laukik Hase
38c0475616
fix(esp_hw_support): Fix different signed comparison in esp_ptr_in_drom
- Closes https://github.com/espressif/esp-idf/issues/11653
- Closes https://github.com/espressif/esp-idf/issues/11865
2023-07-14 10:52:32 +05:30
Jiang Jiang Jian
a591730d29 Merge branch 'bugfix/tempsensor_wifi_conflict_v5.0' into 'release/v5.0'
temperature_sensor: Fix issue that have conflict with phy / Fix phy pwdet and tsens power cannot be set twice issue (v5.0)

See merge request espressif/esp-idf!24066
2023-06-13 10:47:32 +08:00
Jiang Jiang Jian
838850abab Merge branch 'feature/example_deep_sleep_wake_stub_backport_v5.0' into 'release/v5.0'
example: add deepsleep_wake stub example (backport v5.0)

See merge request espressif/esp-idf!23414
2023-06-12 11:07:59 +08:00
Cao Sen Miao
ca41902ccf temperature_sensor: Add new interface and reference counts so that phy and driver can use together 2023-06-06 01:30:51 +08:00
Jakob Hasse
fa099f23f3 compiler: replaced noreturn by __noreturn__ in header files
* noreturn may be replaced by third-party macros,
  rendering it ineffective

* Closes https://github.com/espressif/esp-idf/issues/11339
2023-05-30 13:21:17 +08:00
Marius Vikhammer
10a98e7e58 Merge branch 'contrib/github_pr_11388_v5.0' into 'release/v5.0'
Update esp_cpu.h to include esp_attr.h (GitHub PR) (v5.0)

See merge request espressif/esp-idf!23739
2023-05-16 09:21:45 +08:00
Zim Kalinowski
0b8800eaae Merge branch 'contrib/github_pr_10895_v5.0' into 'release/v5.0'
Fix possible conversion errors by using __builtin_ffsll (GitHub PR) (v5.0)

See merge request espressif/esp-idf!23691
2023-05-15 18:43:35 +08:00
Jakob Hasse
5946c6ad16 cxx/esp_hw_support: added build test, changed parameter types
Changed rv_utils_intr_edge_ack and esp_cpu_intr_edge_ack to
take uint32_t instead of int to avoid build errors.

The test is to test in particular that __builtin_ffsll, used in
xt_utils.h, which is included via esp_cpu.h, compiles fine
in C++20 with -Wsign-conversion enabled.

Closes https://github.com/espressif/esp-idf/pull/10895
2023-05-15 10:03:12 +08:00
Magnus Sörensen
5f27615587 Update esp_cpu.h
If esp_attr.h is not included then there are no definitions for the symbol 'FORCE_INLINE_ATTR'.
2023-05-15 09:51:25 +08:00
Mahavir Jain
3ac5d6a2dd Merge branch 'fix/esp32s3_ununsed_dcache_as_dram_v5.0' into 'release/v5.0'
esp_hw_support: Update the memory ptr location/property checks to include the unused DCACHE added to DRAM (v5.0)

See merge request espressif/esp-idf!23268
2023-05-11 16:48:32 +08:00
jiangguangming
24a38e3153 feature: add example deep sleep wake stub
Closes https://github.com/espressif/esp-idf/issues/8208
2023-05-04 16:46:15 +08:00
Laukik Hase
e0bedd19ab
esp_hw_support: Update memory ptr location/property checks
- to acknowledge the unused DCACHE added to DRAM for ESP32-S3

- For ESP32-S3, when the DCACHE size is set to 16 kB, the unused 48 kB is added to
  the heap in 2 blocks of 32 kB (from 0x3FCF0000) and 16 kB (from 0x3C000000).
- But, if we try allocating memory from the 16 kB block and run an `esp_ptr_internal`
  check on that memory pointer, it fails as the address block from 0x3C000000
  corresponds to the external memory symbols SOC_DROM_LOW and SOC_EXTRAM_DATA_LOW.
  (E.g. freertos - If the IDLE task stack buffer gets allocated from this region,
  the firmware will abort due to this failure).
- Thus, the checks `esp_ptr_internal`, `esp_ptr_in_drom` and `esp_ptr_byte_accessible`
  have been updated to acknowledge this memory as a part of the DRAM.

Co-authored-by: Mahavir Jain <mahavir@espressif.com>
2023-05-04 10:54:34 +05:30
Li Shuai
d84cdace52 sleep: fix sleep current issue caused by sar adc 2023-04-20 11:45:58 +08:00
Armando
85980884d7 adc: improve adc power logic 2023-04-20 10:34:37 +08:00
Song Ruo Jing
27f9ee66d5 gpio: Fix IO hold function related problems
1. Fix deep sleep wakeup IOs can not be unhold issue
2. Correct hold related APIs' description
3. Fix gpio_force_hold_all API

docs: Add GPIO wakeup source to sleep_modes doc for ESP32C3 and C2
2023-03-17 14:44:29 +08:00
Jiang Jiang Jian
4abb6efb36 Merge branch 'bugfix/fix_gpio_wakeup_related_issues_in_ssc_sleep_test_backport_v5.0' into 'release/v5.0'
sleep: fix gpio wakeup related issues(backport v5.0)

See merge request espressif/esp-idf!22332
2023-02-27 15:12:13 +08:00
morris
27ca6549d5 Merge branch 'bugfix/gdma_uhci_id_5.0' into 'release/v5.0'
gdma: correct the dma trigger of UHCI && fix async memcpy conflict with peripheral DMA (v5.0)

See merge request espressif/esp-idf!22006
2023-02-18 15:02:32 +08:00
jingli
50feb8f75b soc_caps: remove SOC_GPIO_SUPPORT_SLP_SWITCH
all esp chips support this feature
2023-02-09 17:29:40 +08:00
morris
6b8d4dfe14 gdma: prevent mutli-channels connect to the same peripheral
1. add check in the gdma driver, to prevent multiple channels connecting
   to the same peripheral
2. memory copy DMA ID will occupy the peripheral's DMA ID on some ESP
   targets (e.g. esp32c3/s3). We should search for a free one when
install async memcpy driver.

Closes https://github.com/espressif/esp-idf/issues/10575
2023-02-01 11:06:48 +08:00
morris
ac05d033b9 gdma: correct the dma trigger of uart
GDMA trigger actually is not assigned to UART controller, but for UHCI
controller
2023-02-01 11:02:24 +08:00
Chip Weinberger
caf794ad26 [Docs] specify Digital Signature byte order, and esp_ds_sign() clarification 2022-12-22 15:41:30 +05:30
Jiang Jiang Jian
77333d2d64 Merge branch 'bugfix/fix_current_leakage_when_hold_digital_io_during_deep_sleep_backport_v5.0' into 'release/v5.0'
esp_hw_support/sleep: fix current leakage when hold digital io during deep sleep(backport v5.0)

See merge request espressif/esp-idf!20806
2022-12-05 14:00:59 +08:00
Marius Vikhammer
c60ccebb77 Merge branch 'bugfix/share_intr_v5.0' into 'release/v5.0'
intr_alloc: fixed freed interrupt sources not being able to be allocated again with different flags (v5.0)

See merge request espressif/esp-idf!21285
2022-12-05 12:09:52 +08:00
jingli
21c9ec5eee esp_hw_support/sleep: fix current leakage when hold digital io during deep sleep 2022-12-02 12:24:52 +00:00
Jiang Jiang Jian
df80bc864d Merge branch 'bugfix/fix_xtal_related_rtc_params_for_esp32_backport_v5.0' into 'release/v5.0'
esp32/rtc: fix xtal unstable in some cases when sleep(backport v5.0)

See merge request espressif/esp-idf!20799
2022-12-02 20:24:25 +08:00
Sachin Parekh
634c2c8bf1
esp32s3/memprot: Set permission for Icache region 2022-12-01 09:19:07 +05:30
Marius Vikhammer
521a726316 intr_alloc: fixed freed interrupt sources not being able to be allocated again with different flags
Mark the vector descriptor source as freed.
2022-11-28 10:43:01 +08:00
jingli
e04c8505e1 esp32/rtc: fix xtal unstable in some cases when sleep
1. add xtal buf wait to fix high temperature restart issue
2. add min sleep value to fix xtal stop due to too short sleep time issue
2022-10-26 16:11:27 +08:00
morris
d7580183a6 Merge branch 'bugfix/rtc_periph_ulp_touch_v5.0' into 'release/v5.0'
sleep_modes: allow using touch/ULP with RTC_PERIPH domain (including EXT0 wakeup source) (v5.0)

See merge request espressif/esp-idf!19767
2022-08-26 18:46:25 +08:00
Michael (XIAO Xufeng)
2ab4ce4bb1 Update components/esp_hw_support/include/esp_sleep.h 2022-08-25 12:28:00 +08:00
Marius Vikhammer
76207273fd docs: fix documentation wrongly stating ESP_SLEEP_WAKEUP_GPIO is light sleep only
ESP_SLEEP_WAKEUP_GPIO is also a valid deep sleep wakeup cause on targets
with SOC_GPIO_SUPPORT_DEEPSLEEP_WAKEUP

Closes https://github.com/espressif/esp-idf/issues/9567
2022-08-24 10:50:49 +08:00
Darian Leung
aa25d83787 esp_hw_support: Fix esp_light_sleep_start() deadlock
esp_light_sleep_start() will stall the other CPU via esp_ipc_isr_stall_other_cpu(). After stalling the other CPU,
will call esp_clk_... API which themselves take locks. If the other stalled CPU is holding those locks, this will
result in a deadlock.

This commit adds a workaround calling esp_clk_private_lock() to take the lock before stalling the other CPU.
2022-08-11 18:38:51 +08:00
jingli
8cd7c30bc7 kconfig: refactor xtal freq kconfig to common configuration item 2022-08-08 13:53:02 +08:00
Jiang Jiang Jian
b885499c74 Merge branch 'refactor/move_common_adc_part_to_hw_support' into 'master'
esp_adc: move esp_adc out of g1 dependency list

Closes IDF-5637

See merge request espressif/esp-idf!19159
2022-08-01 15:39:45 +08:00
wuzhenghui
7cb9304b65 Clean IRAM and DRAM address space conversion macros 2022-07-29 17:07:39 +08:00
Armando
5e6a16380a esp_adc: move adc common hw related code into esp_hw_support 2022-07-28 03:49:48 +00:00
morris
5e50ec1d66 systimer: add helper functions to convert between tick and us 2022-07-25 16:08:52 +08:00
Darian
c8ee369a7c Merge branch 'feature/deprecate-old-cpu-api' into 'master'
HAL: Deprecate old CPU/SoC/Interrupt Controller HAL API

Closes IDF-4919 and IDF-5032

See merge request espressif/esp-idf!18987
2022-07-23 00:37:33 +08:00
morris
741b031e83 soc: added SOC_TOUCH_SENSE_SUPPORTED macro 2022-07-22 00:12:36 +00:00
Guillaume Souchere
0bac33ed41 esp_system: Remove deprecate section from esp_cpu.h
- Remove esp_cpu_in_ocd_mode() from esp_cpu.h. Users should call esp_cpu_dbgr_is_attached() instead.
- Remove esp_cpu_get_ccount() from esp_cpu.h. Users should call esp_cpu_get_cycle_count() instead.
- Remove esp_cpu_set_ccount() from esp_cpu.h. Users should call esp_cpu_set_cycle_count() instead.
- Other IDF components updated to call esp_cpu_dbgr_is_attached(), esp_cpu_get_cycle_count() and esp_cpu_set_cycle_count() as well.
2022-07-22 00:06:06 +08:00
Guillaume Souchere
dcae121d80 hal: Deprecate soc_hal.h and soc_ll.h interface
This commit marks all functions in soc_hal.h and soc_ll.h as deprecated.
Users should use functions from esp_cpu.h instead.

Also added missing wrap funcions for esp_cpu_stall() in test_panic.c files.
2022-07-22 00:06:06 +08:00
Guillaume Souchere
6005cc9163 hal: Deprecate interrupt_controller_hal.h, cpu_hal.h and cpu_ll.h interfaces
This commit marks all functions in interrupt_controller_hal.h, cpu_ll.h and cpu_hal.h as deprecated.
Users should use functions from esp_cpu.h instead.
2022-07-22 00:06:06 +08:00