mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
esp_system: Minor update for esp32c6
This commit is contained in:
parent
5115e31175
commit
1eb9a24a48
@ -75,7 +75,7 @@ void esp_crosscore_int_send_print_backtrace(int core_id);
|
||||
void esp_crosscore_int_send_twdt_abort(int core_id);
|
||||
|
||||
#endif // CONFIG_ESP_TASK_WDT_EN
|
||||
#endif // !CONFIG_IDF_TARGET_ESP32C3 && !CONFIG_IDF_TARGET_ESP32H2 && !CONFIG_IDF_TARGET_ESP32C2
|
||||
#endif // !CONFIG_IDF_TARGET_ESP32C3 && !CONFIG_IDF_TARGET_ESP32H2 && !CONFIG_IDF_TARGET_ESP32C2 && !CONFIG_IDF_TARGET_ESP32C6
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -11,8 +11,7 @@
|
||||
#include "esp_attr.h"
|
||||
#include "esp_log.h"
|
||||
#include "esp_rom_sys.h"
|
||||
#include "riscv/riscv_interrupts.h"
|
||||
#include "riscv/interrupt.h"
|
||||
#include "riscv/rv_utils.h"
|
||||
#include "esp_rom_uart.h"
|
||||
#include "soc/gpio_reg.h"
|
||||
#include "esp_cpu.h"
|
||||
@ -33,7 +32,7 @@
|
||||
void IRAM_ATTR esp_restart_noos(void)
|
||||
{
|
||||
// Disable interrupts
|
||||
riscv_global_interrupts_disable();
|
||||
rv_utils_intr_global_disable();
|
||||
// Enable RTC watchdog for 1 second
|
||||
wdt_hal_context_t rtc_wdt_ctx;
|
||||
wdt_hal_init(&rtc_wdt_ctx, WDT_RWDT, 0, false);
|
||||
|
@ -195,7 +195,9 @@ FORCE_INLINE_ATTR void rv_utils_dbgr_break(void)
|
||||
|
||||
FORCE_INLINE_ATTR bool rv_utils_compare_and_set(volatile uint32_t *addr, uint32_t compare_value, uint32_t new_value)
|
||||
{
|
||||
// Single core target has no atomic CAS instruction. We can achieve atomicity by disabling interrupts
|
||||
// ESP32C6 starts to support atomic CAS instructions, but it is still a single core target, no need to implement
|
||||
// through lr and sc instructions for now
|
||||
// For an RV target has no atomic CAS instruction, we can achieve atomicity by disabling interrupts
|
||||
unsigned old_mstatus;
|
||||
old_mstatus = RV_CLEAR_CSR(mstatus, MSTATUS_MIE);
|
||||
// Compare and set
|
||||
|
@ -241,3 +241,6 @@
|
||||
|
||||
//Interrupt medium level, used for INT WDT for example
|
||||
#define SOC_INTERRUPT_LEVEL_MEDIUM 4
|
||||
|
||||
// Interrupt number for the Interrupt watchdog
|
||||
#define ETS_INT_WDT_INUM (ETS_T1_WDT_INUM)
|
||||
|
Loading…
Reference in New Issue
Block a user