forked from espressif/esp-idf
refactor(soc): reformat code with astyle
This commit is contained in:
@@ -1,25 +1,21 @@
|
|||||||
// Copyright 2015-2019 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2015-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#include "soc/adc_periph.h"
|
#include "soc/adc_periph.h"
|
||||||
|
|
||||||
/* Store IO number corresponding to the ADC channel number. */
|
/* Store IO number corresponding to the ADC channel number. */
|
||||||
const int adc_channel_io_map[SOC_ADC_PERIPH_NUM][SOC_ADC_MAX_CHANNEL_NUM] = {
|
const int adc_channel_io_map[SOC_ADC_PERIPH_NUM][SOC_ADC_MAX_CHANNEL_NUM] = {
|
||||||
/* ADC1 */
|
/* ADC1 */
|
||||||
{ADC1_CHANNEL_0_GPIO_NUM, ADC1_CHANNEL_1_GPIO_NUM, ADC1_CHANNEL_2_GPIO_NUM, ADC1_CHANNEL_3_GPIO_NUM, ADC1_CHANNEL_4_GPIO_NUM,
|
{
|
||||||
ADC1_CHANNEL_5_GPIO_NUM, ADC1_CHANNEL_6_GPIO_NUM, ADC1_CHANNEL_7_GPIO_NUM, -1, -1},
|
ADC1_CHANNEL_0_GPIO_NUM, ADC1_CHANNEL_1_GPIO_NUM, ADC1_CHANNEL_2_GPIO_NUM, ADC1_CHANNEL_3_GPIO_NUM, ADC1_CHANNEL_4_GPIO_NUM,
|
||||||
|
ADC1_CHANNEL_5_GPIO_NUM, ADC1_CHANNEL_6_GPIO_NUM, ADC1_CHANNEL_7_GPIO_NUM, -1, -1
|
||||||
|
},
|
||||||
/* ADC2 */
|
/* ADC2 */
|
||||||
{ADC2_CHANNEL_0_GPIO_NUM, ADC2_CHANNEL_1_GPIO_NUM, ADC2_CHANNEL_2_GPIO_NUM, ADC2_CHANNEL_3_GPIO_NUM, ADC2_CHANNEL_4_GPIO_NUM,
|
{
|
||||||
ADC2_CHANNEL_5_GPIO_NUM, ADC2_CHANNEL_6_GPIO_NUM, ADC2_CHANNEL_7_GPIO_NUM, ADC2_CHANNEL_8_GPIO_NUM, ADC2_CHANNEL_9_GPIO_NUM}
|
ADC2_CHANNEL_0_GPIO_NUM, ADC2_CHANNEL_1_GPIO_NUM, ADC2_CHANNEL_2_GPIO_NUM, ADC2_CHANNEL_3_GPIO_NUM, ADC2_CHANNEL_4_GPIO_NUM,
|
||||||
|
ADC2_CHANNEL_5_GPIO_NUM, ADC2_CHANNEL_6_GPIO_NUM, ADC2_CHANNEL_7_GPIO_NUM, ADC2_CHANNEL_8_GPIO_NUM, ADC2_CHANNEL_9_GPIO_NUM
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2010-2016 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2010-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#ifndef _SOC_BB_REG_H_
|
#ifndef _SOC_BB_REG_H_
|
||||||
#define _SOC_BB_REG_H_
|
#define _SOC_BB_REG_H_
|
||||||
@@ -37,5 +29,4 @@
|
|||||||
#define BB_DC_EST_FORCE_PD_V 1
|
#define BB_DC_EST_FORCE_PD_V 1
|
||||||
#define BB_DC_EST_FORCE_PD_S 0
|
#define BB_DC_EST_FORCE_PD_S 0
|
||||||
|
|
||||||
|
|
||||||
#endif /* _SOC_BB_REG_H_ */
|
#endif /* _SOC_BB_REG_H_ */
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2010-2016 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2010-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#ifndef _SOC_BOOT_MODE_H_
|
#ifndef _SOC_BOOT_MODE_H_
|
||||||
#define _SOC_BOOT_MODE_H_
|
#define _SOC_BOOT_MODE_H_
|
||||||
@@ -50,8 +42,6 @@
|
|||||||
/*SDIO_Slave download Mode V1.1*/
|
/*SDIO_Slave download Mode V1.1*/
|
||||||
#define IS_01101(v) (((v)&0x1f)==0x0d)
|
#define IS_01101(v) (((v)&0x1f)==0x0d)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP))
|
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP))
|
||||||
|
|
||||||
/*do not include download mode*/
|
/*do not include download mode*/
|
||||||
|
@@ -411,7 +411,6 @@ typedef enum {
|
|||||||
ADC_RTC_CLK_SRC_DEFAULT = SOC_MOD_CLK_RC_FAST, /*!< Select RC_FAST as the default clock choice */
|
ADC_RTC_CLK_SRC_DEFAULT = SOC_MOD_CLK_RC_FAST, /*!< Select RC_FAST as the default clock choice */
|
||||||
} soc_periph_adc_rtc_clk_src_t;
|
} soc_periph_adc_rtc_clk_src_t;
|
||||||
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////MWDT/////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////MWDT/////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -446,7 +445,6 @@ typedef enum {
|
|||||||
LEDC_USE_RTC8M_CLK __attribute__((deprecated("please use 'LEDC_USE_RC_FAST_CLK' instead"))) = LEDC_USE_RC_FAST_CLK, /*!< Alias of 'LEDC_USE_RC_FAST_CLK' */
|
LEDC_USE_RTC8M_CLK __attribute__((deprecated("please use 'LEDC_USE_RC_FAST_CLK' instead"))) = LEDC_USE_RC_FAST_CLK, /*!< Alias of 'LEDC_USE_RC_FAST_CLK' */
|
||||||
} soc_periph_ledc_clk_src_legacy_t;
|
} soc_periph_ledc_clk_src_legacy_t;
|
||||||
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////SDMMC///////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////SDMMC///////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -476,7 +474,6 @@ typedef enum {
|
|||||||
CLKOUT_SIG_INVALID = 0xFF,
|
CLKOUT_SIG_INVALID = 0xFF,
|
||||||
} soc_clkout_sig_id_t;
|
} soc_clkout_sig_id_t;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -36,7 +36,6 @@ typedef enum clock_out_channel {
|
|||||||
(channel == CLKOUT_CHANNEL_3) ? FUNC_CLK_OUT3 : -1)
|
(channel == CLKOUT_CHANNEL_3) ? FUNC_CLK_OUT3 : -1)
|
||||||
#define IS_VALID_CLKOUT_IO(gpio_num) ((gpio_num == CLKOUT_CHANNEL1_GPIO) || (gpio_num == CLKOUT_CHANNEL2_GPIO) || (gpio_num == CLKOUT_CHANNEL3_GPIO))
|
#define IS_VALID_CLKOUT_IO(gpio_num) ((gpio_num == CLKOUT_CHANNEL1_GPIO) || (gpio_num == CLKOUT_CHANNEL2_GPIO) || (gpio_num == CLKOUT_CHANNEL3_GPIO))
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
||||||
|
@@ -6,7 +6,6 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
|
||||||
#define DAC_GPIO25_CHANNEL DAC_CHAN_0
|
#define DAC_GPIO25_CHANNEL DAC_CHAN_0
|
||||||
#define DAC_CHAN0_GPIO_NUM 25
|
#define DAC_CHAN0_GPIO_NUM 25
|
||||||
#define DAC_CHANNEL_1_GPIO_NUM DAC_CHAN0_GPIO_NUM //`DAC_CHANNEL_1_GPIO_NUM` is defined for DAC legacy driver, indicating the first DAC channel.
|
#define DAC_CHANNEL_1_GPIO_NUM DAC_CHAN0_GPIO_NUM //`DAC_CHANNEL_1_GPIO_NUM` is defined for DAC legacy driver, indicating the first DAC channel.
|
||||||
|
@@ -8,7 +8,6 @@
|
|||||||
|
|
||||||
#include "esp_bit_defs.h"
|
#include "esp_bit_defs.h"
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
@@ -58,7 +57,6 @@ extern "C" {
|
|||||||
//MMU entry num, 384 entries that are used in IDF for Flash
|
//MMU entry num, 384 entries that are used in IDF for Flash
|
||||||
#define SOC_MMU_ENTRY_NUM 384
|
#define SOC_MMU_ENTRY_NUM 384
|
||||||
|
|
||||||
|
|
||||||
#define SOC_MMU_DBUS_VADDR_BASE 0x3E000000
|
#define SOC_MMU_DBUS_VADDR_BASE 0x3E000000
|
||||||
#define SOC_MMU_IBUS_VADDR_BASE 0x40000000
|
#define SOC_MMU_IBUS_VADDR_BASE 0x40000000
|
||||||
|
|
||||||
@@ -88,9 +86,6 @@ extern "C" {
|
|||||||
#define SOC_MMU_DRAM1_LINEAR_ADDRESS_LOW (SOC_DRAM1_CACHE_ADDRESS_LOW & SOC_MMU_LINEAR_ADDR_MASK)
|
#define SOC_MMU_DRAM1_LINEAR_ADDRESS_LOW (SOC_DRAM1_CACHE_ADDRESS_LOW & SOC_MMU_LINEAR_ADDR_MASK)
|
||||||
#define SOC_MMU_DRAM1_LINEAR_ADDRESS_HIGH (SOC_DRAM1_CACHE_ADDRESS_HIGH & SOC_MMU_LINEAR_ADDR_MASK)
|
#define SOC_MMU_DRAM1_LINEAR_ADDRESS_HIGH (SOC_DRAM1_CACHE_ADDRESS_HIGH & SOC_MMU_LINEAR_ADDR_MASK)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -10,7 +10,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#define GPIO_MATRIX_CONST_ONE_INPUT (0x38)
|
#define GPIO_MATRIX_CONST_ONE_INPUT (0x38)
|
||||||
#define GPIO_MATRIX_CONST_ZERO_INPUT (0x30)
|
#define GPIO_MATRIX_CONST_ZERO_INPUT (0x30)
|
||||||
|
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2015-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
#ifndef _SOC_PID_H_
|
#ifndef _SOC_PID_H_
|
||||||
#define _SOC_PID_H_
|
#define _SOC_PID_H_
|
||||||
|
|
||||||
|
@@ -19,14 +19,12 @@
|
|||||||
#define PRO_CPU_NUM (0)
|
#define PRO_CPU_NUM (0)
|
||||||
#define APP_CPU_NUM (1)
|
#define APP_CPU_NUM (1)
|
||||||
|
|
||||||
|
|
||||||
#define SOC_MAX_CONTIGUOUS_RAM_SIZE 0x400000 ///< Largest span of contiguous memory (DRAM or IRAM) in the address space
|
#define SOC_MAX_CONTIGUOUS_RAM_SIZE 0x400000 ///< Largest span of contiguous memory (DRAM or IRAM) in the address space
|
||||||
|
|
||||||
//Registers Operation {{
|
//Registers Operation {{
|
||||||
#define ETS_UNCACHED_ADDR(addr) (addr)
|
#define ETS_UNCACHED_ADDR(addr) (addr)
|
||||||
#define ETS_CACHED_ADDR(addr) (addr)
|
#define ETS_CACHED_ADDR(addr) (addr)
|
||||||
|
|
||||||
|
|
||||||
#ifndef __ASSEMBLER__
|
#ifndef __ASSEMBLER__
|
||||||
|
|
||||||
#define IS_DPORT_REG(_r) (((_r) >= DR_REG_DPORT_BASE) && (_r) <= DR_REG_DPORT_END)
|
#define IS_DPORT_REG(_r) (((_r) >= DR_REG_DPORT_BASE) && (_r) <= DR_REG_DPORT_END)
|
||||||
|
@@ -318,7 +318,6 @@
|
|||||||
#define SOC_MEMSPI_SRC_FREQ_26M_SUPPORTED 1
|
#define SOC_MEMSPI_SRC_FREQ_26M_SUPPORTED 1
|
||||||
#define SOC_MEMSPI_SRC_FREQ_20M_SUPPORTED 1
|
#define SOC_MEMSPI_SRC_FREQ_20M_SUPPORTED 1
|
||||||
|
|
||||||
|
|
||||||
// Peripheral supports DIO, DOUT, QIO, or QOUT
|
// Peripheral supports DIO, DOUT, QIO, or QOUT
|
||||||
#define SOC_SPI_PERIPH_SUPPORT_MULTILINE_MODE(spi_host) ({(void)spi_host; 1;})
|
#define SOC_SPI_PERIPH_SUPPORT_MULTILINE_MODE(spi_host) ({(void)spi_host; 1;})
|
||||||
|
|
||||||
@@ -356,7 +355,6 @@
|
|||||||
#define SOC_UART_FIFO_LEN (128) /*!< The UART hardware FIFO length */
|
#define SOC_UART_FIFO_LEN (128) /*!< The UART hardware FIFO length */
|
||||||
#define SOC_UART_BITRATE_MAX (5000000) /*!< Max bit rate supported by UART */
|
#define SOC_UART_BITRATE_MAX (5000000) /*!< Max bit rate supported by UART */
|
||||||
|
|
||||||
|
|
||||||
/*-------------------------- SPIRAM CAPS -------------------------------------*/
|
/*-------------------------- SPIRAM CAPS -------------------------------------*/
|
||||||
#define SOC_SPIRAM_SUPPORTED 1
|
#define SOC_SPIRAM_SUPPORTED 1
|
||||||
|
|
||||||
@@ -383,7 +381,6 @@
|
|||||||
/*--------------------------- RSA CAPS ---------------------------------------*/
|
/*--------------------------- RSA CAPS ---------------------------------------*/
|
||||||
#define SOC_RSA_MAX_BIT_LEN (4096)
|
#define SOC_RSA_MAX_BIT_LEN (4096)
|
||||||
|
|
||||||
|
|
||||||
/*-------------------------- AES CAPS -----------------------------------------*/
|
/*-------------------------- AES CAPS -----------------------------------------*/
|
||||||
#define SOC_AES_SUPPORT_AES_128 (1)
|
#define SOC_AES_SUPPORT_AES_128 (1)
|
||||||
#define SOC_AES_SUPPORT_AES_192 (1)
|
#define SOC_AES_SUPPORT_AES_192 (1)
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2020 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2010-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
//
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Pin definition header file. The long term plan is to have a single soc_pins.h for all
|
* Pin definition header file. The long term plan is to have a single soc_pins.h for all
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2015-2021 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2015-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
//
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2010-2016 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2010-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
//
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2015-2019 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2015-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#include "soc/ledc_periph.h"
|
#include "soc/ledc_periph.h"
|
||||||
#include "soc/gpio_sig_map.h"
|
#include "soc/gpio_sig_map.h"
|
||||||
|
@@ -268,7 +268,6 @@ typedef enum {
|
|||||||
GLITCH_FILTER_CLK_SRC_DEFAULT = SOC_MOD_CLK_APB, /*!< Select APB clock as the default clock choice */
|
GLITCH_FILTER_CLK_SRC_DEFAULT = SOC_MOD_CLK_APB, /*!< Select APB clock as the default clock choice */
|
||||||
} soc_periph_glitch_filter_clk_src_t;
|
} soc_periph_glitch_filter_clk_src_t;
|
||||||
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////MWDT/////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////MWDT/////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -26,7 +26,6 @@ typedef enum clock_out_channel {
|
|||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
||||||
|
@@ -5,7 +5,6 @@
|
|||||||
*/
|
*/
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include "esp_bit_defs.h"
|
#include "esp_bit_defs.h"
|
||||||
|
|
||||||
@@ -21,7 +20,6 @@ extern "C" {
|
|||||||
#define SOC_MMU_PAGE_SIZE 0x10000
|
#define SOC_MMU_PAGE_SIZE 0x10000
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/*IRAM0 is connected with Cache IBUS0*/
|
/*IRAM0 is connected with Cache IBUS0*/
|
||||||
#define SOC_IRAM0_ADDRESS_LOW 0x4037C000
|
#define SOC_IRAM0_ADDRESS_LOW 0x4037C000
|
||||||
#define SOC_IRAM0_ADDRESS_HIGH 0x403C0000
|
#define SOC_IRAM0_ADDRESS_HIGH 0x403C0000
|
||||||
@@ -134,7 +132,6 @@ extern "C" {
|
|||||||
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ROM flash mmap driver needs below definitions
|
* ROM flash mmap driver needs below definitions
|
||||||
*/
|
*/
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "esp_bit_defs.h"
|
#include "esp_bit_defs.h"
|
||||||
@@ -22,7 +21,6 @@
|
|||||||
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
||||||
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
||||||
|
|
||||||
|
|
||||||
#define ANA_CONFIG2_REG 0x6004E848
|
#define ANA_CONFIG2_REG 0x6004E848
|
||||||
#define ANA_CONFIG2_M BIT(18)
|
#define ANA_CONFIG2_M BIT(18)
|
||||||
|
|
||||||
|
@@ -43,7 +43,6 @@ typedef enum {
|
|||||||
RESET_REASON_CPU0_JTAG = 0x18, // JTAG resets the CPU 0
|
RESET_REASON_CPU0_JTAG = 0x18, // JTAG resets the CPU 0
|
||||||
} soc_reset_reason_t;
|
} soc_reset_reason_t;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -23,7 +23,6 @@
|
|||||||
0 \
|
0 \
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
#define REG_UHCI_BASE(i) (DR_REG_UHCI0_BASE - (i) * 0x8000)
|
#define REG_UHCI_BASE(i) (DR_REG_UHCI0_BASE - (i) * 0x8000)
|
||||||
#define REG_UART_BASE(i) (DR_REG_UART_BASE + (i) * 0x10000)
|
#define REG_UART_BASE(i) (DR_REG_UART_BASE + (i) * 0x10000)
|
||||||
#define REG_UART_AHB_BASE(i) (0x60000000 + (i) * 0x10000)
|
#define REG_UART_AHB_BASE(i) (0x60000000 + (i) * 0x10000)
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2020 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2020-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#ifndef _SOC_BOOT_MODE_H_
|
#ifndef _SOC_BOOT_MODE_H_
|
||||||
#define _SOC_BOOT_MODE_H_
|
#define _SOC_BOOT_MODE_H_
|
||||||
@@ -47,8 +39,6 @@
|
|||||||
/*Diagnostic Mode+UART0 download Mode*/
|
/*Diagnostic Mode+UART0 download Mode*/
|
||||||
#define IS_0111(v) (((v)&0x0f)==0x07)
|
#define IS_0111(v) (((v)&0x0f)==0x07)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
||||||
|
|
||||||
/*do not include download mode*/
|
/*do not include download mode*/
|
||||||
|
@@ -340,7 +340,6 @@ typedef enum {
|
|||||||
ADC_DIGI_CLK_SRC_DEFAULT = SOC_MOD_CLK_APB, /*!< Select APB as the default clock choice */
|
ADC_DIGI_CLK_SRC_DEFAULT = SOC_MOD_CLK_APB, /*!< Select APB as the default clock choice */
|
||||||
} soc_periph_adc_digi_clk_src_t;
|
} soc_periph_adc_digi_clk_src_t;
|
||||||
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////MWDT/////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////MWDT/////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -26,7 +26,6 @@ typedef enum clock_out_channel {
|
|||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
||||||
|
@@ -102,7 +102,6 @@ extern "C" {
|
|||||||
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ROM flash mmap driver needs below definitions
|
* ROM flash mmap driver needs below definitions
|
||||||
*/
|
*/
|
||||||
|
@@ -10,7 +10,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief GPIO number
|
* @brief GPIO number
|
||||||
*/
|
*/
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@@ -20,7 +20,6 @@
|
|||||||
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
||||||
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
||||||
|
|
||||||
|
|
||||||
#define ANA_CONFIG2_REG 0x6000E048
|
#define ANA_CONFIG2_REG 0x6000E048
|
||||||
#define ANA_CONFIG2_M BIT(18)
|
#define ANA_CONFIG2_M BIT(18)
|
||||||
|
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2021 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2021-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
//
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
@@ -57,7 +49,6 @@ typedef enum {
|
|||||||
RESET_REASON_CORE_PWR_GLITCH = 0x17, // Glitch on power resets the digital core
|
RESET_REASON_CORE_PWR_GLITCH = 0x17, // Glitch on power resets the digital core
|
||||||
} soc_reset_reason_t;
|
} soc_reset_reason_t;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -1,16 +1,8 @@
|
|||||||
// Copyright 2020 Espressif Systems (Shanghai) PTE LTD
|
/*
|
||||||
//
|
* SPDX-FileCopyrightText: 2020-2024 Espressif Systems (Shanghai) CO LTD
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
*
|
||||||
// you may not use this file except in compliance with the License.
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
// You may obtain a copy of the License at
|
*/
|
||||||
//
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
// See the License for the specific language governing permissions and
|
|
||||||
// limitations under the License.
|
|
||||||
|
|
||||||
#include "soc/ledc_periph.h"
|
#include "soc/ledc_periph.h"
|
||||||
#include "soc/gpio_sig_map.h"
|
#include "soc/gpio_sig_map.h"
|
||||||
|
@@ -49,18 +49,22 @@ const gdma_signal_conn_t gdma_periph_signals = {
|
|||||||
static const uint32_t g0p0_regs_map0[4] = {0x4c801001, 0x604c0060, 0x0, 0x0};
|
static const uint32_t g0p0_regs_map0[4] = {0x4c801001, 0x604c0060, 0x0, 0x0};
|
||||||
static const uint32_t g0p0_regs_map1[4] = {0xc0000003, 0xfc900000, 0x0, 0x0};
|
static const uint32_t g0p0_regs_map1[4] = {0xc0000003, 0xfc900000, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P0_RETENTION_MAP_BASE_0, G0P0_RETENTION_MAP_BASE_0, \
|
G0P0_RETENTION_MAP_BASE_0, G0P0_RETENTION_MAP_BASE_0, \
|
||||||
G0P0_RETENTION_REGS_CNT_0, 0, 0, \
|
G0P0_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
g0p0_regs_map0[0], g0p0_regs_map0[1], \
|
g0p0_regs_map0[0], g0p0_regs_map0[1], \
|
||||||
g0p0_regs_map0[2], g0p0_regs_map0[3]), \
|
g0p0_regs_map0[2], g0p0_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY }, \
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
}, \
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
G0P0_RETENTION_MAP_BASE_1, G0P0_RETENTION_MAP_BASE_1, \
|
G0P0_RETENTION_MAP_BASE_1, G0P0_RETENTION_MAP_BASE_1, \
|
||||||
G0P0_RETENTION_REGS_CNT_1, 0, 0, \
|
G0P0_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
g0p0_regs_map1[0], g0p0_regs_map1[1], \
|
g0p0_regs_map1[0], g0p0_regs_map1[1], \
|
||||||
g0p0_regs_map1[2], g0p0_regs_map1[3]), \
|
g0p0_regs_map1[2], g0p0_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AHB_DMA Channel (Group0, Pair1) Registers Context
|
/* AHB_DMA Channel (Group0, Pair1) Registers Context
|
||||||
@@ -83,18 +87,22 @@ static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
|||||||
static const uint32_t g0p1_regs_map0[4] = {0x81001, 0x0, 0xc00604c0, 0x604};
|
static const uint32_t g0p1_regs_map0[4] = {0x81001, 0x0, 0xc00604c0, 0x604};
|
||||||
static const uint32_t g0p1_regs_map1[4] = {0xc0000003, 0x3f4800, 0x0, 0x0};
|
static const uint32_t g0p1_regs_map1[4] = {0xc0000003, 0x3f4800, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P1_RETENTION_MAP_BASE_0, G0P1_RETENTION_MAP_BASE_0, \
|
G0P1_RETENTION_MAP_BASE_0, G0P1_RETENTION_MAP_BASE_0, \
|
||||||
G0P1_RETENTION_REGS_CNT_0, 0, 0, \
|
G0P1_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
g0p1_regs_map0[0], g0p1_regs_map0[1], \
|
g0p1_regs_map0[0], g0p1_regs_map0[1], \
|
||||||
g0p1_regs_map0[2], g0p1_regs_map0[3]), \
|
g0p1_regs_map0[2], g0p1_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
G0P1_RETENTION_MAP_BASE_1, G0P1_RETENTION_MAP_BASE_1, \
|
G0P1_RETENTION_MAP_BASE_1, G0P1_RETENTION_MAP_BASE_1, \
|
||||||
G0P1_RETENTION_REGS_CNT_1, 0, 0, \
|
G0P1_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
g0p1_regs_map1[0], g0p1_regs_map1[1], \
|
g0p1_regs_map1[0], g0p1_regs_map1[1], \
|
||||||
g0p1_regs_map1[2], g0p1_regs_map1[3]), \
|
g0p1_regs_map1[2], g0p1_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AHB_DMA Channel (Group0, Pair2) Registers Context
|
/* AHB_DMA Channel (Group0, Pair2) Registers Context
|
||||||
@@ -118,18 +126,22 @@ static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
|||||||
static const uint32_t g0p2_regs_map0[4] = {0x9001, 0x0, 0x0, 0x0};
|
static const uint32_t g0p2_regs_map0[4] = {0x9001, 0x0, 0x0, 0x0};
|
||||||
static const uint32_t g0p2_regs_map1[4] = {0x13001813, 0x18, 0x18000, 0x7f26000};
|
static const uint32_t g0p2_regs_map1[4] = {0x13001813, 0x18, 0x18000, 0x7f26000};
|
||||||
static const regdma_entries_config_t gdma_g0p2_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p2_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P2_RETENTION_MAP_BASE_0, G0P2_RETENTION_MAP_BASE_0, \
|
G0P2_RETENTION_MAP_BASE_0, G0P2_RETENTION_MAP_BASE_0, \
|
||||||
G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
g0p2_regs_map0[0], g0p2_regs_map0[1], \
|
g0p2_regs_map0[0], g0p2_regs_map0[1], \
|
||||||
g0p2_regs_map0[2], g0p2_regs_map0[3]), \
|
g0p2_regs_map0[2], g0p2_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
G0P2_RETENTION_MAP_BASE_1, G0P2_RETENTION_MAP_BASE_1, \
|
G0P2_RETENTION_MAP_BASE_1, G0P2_RETENTION_MAP_BASE_1, \
|
||||||
G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
g0p2_regs_map1[0], g0p2_regs_map1[1], \
|
g0p2_regs_map1[0], g0p2_regs_map1[1], \
|
||||||
g0p2_regs_map1[2], g0p2_regs_map1[3]), \
|
g0p2_regs_map1[2], g0p2_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
||||||
|
@@ -10,8 +10,7 @@
|
|||||||
/*
|
/*
|
||||||
Bunch of constants for every I2C peripheral: GPIO signals, irqs, hw addr of registers etc
|
Bunch of constants for every I2C peripheral: GPIO signals, irqs, hw addr of registers etc
|
||||||
*/
|
*/
|
||||||
typedef enum
|
typedef enum {
|
||||||
{
|
|
||||||
LP_I2C_MUX_FUNC = 0,
|
LP_I2C_MUX_FUNC = 0,
|
||||||
LP_GPIO_MUX_FUNC = 1,
|
LP_GPIO_MUX_FUNC = 1,
|
||||||
LP_IO_MUX_FUNC_NUM = 2,
|
LP_IO_MUX_FUNC_NUM = 2,
|
||||||
@@ -54,16 +53,26 @@ const i2c_signal_conn_t i2c_periph_signal[SOC_I2C_NUM] = {
|
|||||||
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
||||||
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
||||||
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
||||||
[1] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[2] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
[1] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
||||||
[3] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[4] = {.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
[2] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[3] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[4] = {
|
||||||
|
.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
||||||
|
@@ -26,7 +26,6 @@ typedef enum clock_out_channel {
|
|||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
||||||
|
@@ -19,7 +19,6 @@ extern "C" {
|
|||||||
#define SOC_MMU_PAGE_SIZE 0x10000
|
#define SOC_MMU_PAGE_SIZE 0x10000
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
||||||
|
|
||||||
@@ -114,7 +113,6 @@ extern "C" {
|
|||||||
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ROM flash mmap driver needs below definitions
|
* ROM flash mmap driver needs below definitions
|
||||||
*/
|
*/
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include "soc/clic_reg.h"
|
#include "soc/clic_reg.h"
|
||||||
#include "soc/soc_caps.h"
|
#include "soc/soc_caps.h"
|
||||||
|
|
||||||
|
@@ -22,7 +22,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
||||||
* @note refer to TRM: <Reset and Clock> chapter
|
* @note refer to TRM: <Reset and Clock> chapter
|
||||||
@@ -50,7 +49,6 @@ typedef enum {
|
|||||||
RESET_REASON_CPU0_LOCKUP = 0x1A, // Triggered when the CPU enters lockup (exception inside the exception handler would cause this)
|
RESET_REASON_CPU0_LOCKUP = 0x1A, // Triggered when the CPU enters lockup (exception inside the exception handler would cause this)
|
||||||
} soc_reset_reason_t;
|
} soc_reset_reason_t;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -44,16 +44,20 @@ static const uint32_t ledc_common_regs_map[4] = {0x1c00001, 0x400, 0x0, 0x0};
|
|||||||
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
||||||
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
||||||
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
||||||
[0] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
||||||
LEDC_INT_ENA_REG, 0,
|
LEDC_INT_ENA_REG, 0,
|
||||||
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
||||||
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
||||||
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
||||||
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
||||||
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
||||||
|
@@ -103,19 +103,25 @@ static const uint32_t mcpwm_regs_map[4] = {0xefffeeef, 0x7efffbff, 0x1ff18, 0x0}
|
|||||||
static const regdma_entries_config_t mcpwm_regs_retention[] = {
|
static const regdma_entries_config_t mcpwm_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_MCPWM_LINK(0x00),
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_MCPWM_LINK(0x00),
|
||||||
MCPWM_RETENTION_REGS_BASE, MCPWM_RETENTION_REGS_BASE,
|
MCPWM_RETENTION_REGS_BASE, MCPWM_RETENTION_REGS_BASE,
|
||||||
MCPWM_RETENTION_REGS_CNT, 0, 0,
|
MCPWM_RETENTION_REGS_CNT, 0, 0,
|
||||||
mcpwm_regs_map[0], mcpwm_regs_map[1],
|
mcpwm_regs_map[0], mcpwm_regs_map[1],
|
||||||
mcpwm_regs_map[2], mcpwm_regs_map[3]),
|
mcpwm_regs_map[2], mcpwm_regs_map[3]),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
},
|
||||||
// restore stage: trigger a forced update of all active registers
|
// restore stage: trigger a forced update of all active registers
|
||||||
[1] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x01),
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x01),
|
||||||
MCPWM_UPDATE_CFG_REG(0), MCPWM_GLOBAL_FORCE_UP, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
MCPWM_UPDATE_CFG_REG(0), MCPWM_GLOBAL_FORCE_UP, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
[2] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x02),
|
},
|
||||||
|
[2] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x02),
|
||||||
MCPWM_UPDATE_CFG_REG(0), 0, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
MCPWM_UPDATE_CFG_REG(0), 0, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const mcpwm_reg_retention_info_t mcpwm_reg_retention_info[SOC_MCPWM_GROUPS] = {
|
const mcpwm_reg_retention_info_t mcpwm_reg_retention_info[SOC_MCPWM_GROUPS] = {
|
||||||
|
@@ -62,12 +62,14 @@ static const uint32_t parlio_regs_map[4] = {0x60457, 0x0, 0x0, 0x0};
|
|||||||
static const regdma_entries_config_t parlio_regs_retention[] = {
|
static const regdma_entries_config_t parlio_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PARLIO_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PARLIO_LINK(0x00), \
|
||||||
PARLIO_RETENTION_REGS_BASE, PARLIO_RETENTION_REGS_BASE, \
|
PARLIO_RETENTION_REGS_BASE, PARLIO_RETENTION_REGS_BASE, \
|
||||||
PARLIO_RETENTION_REGS_CNT, 0, 0, \
|
PARLIO_RETENTION_REGS_CNT, 0, 0, \
|
||||||
parlio_regs_map[0], parlio_regs_map[1], \
|
parlio_regs_map[0], parlio_regs_map[1], \
|
||||||
parlio_regs_map[2], parlio_regs_map[3]), \
|
parlio_regs_map[2], parlio_regs_map[3]), \
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
const parlio_reg_retention_info_t parlio_reg_retention_info[SOC_PARLIO_GROUPS] = {
|
const parlio_reg_retention_info_t parlio_reg_retention_info[SOC_PARLIO_GROUPS] = {
|
||||||
[0] = {
|
[0] = {
|
||||||
|
@@ -82,12 +82,14 @@ static const uint32_t pcnt_regs_map[4] = {0x1f040fff, 0x0, 0x0, 0x0};
|
|||||||
static const regdma_entries_config_t pcnt_regs_retention[] = {
|
static const regdma_entries_config_t pcnt_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PCNT_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PCNT_LINK(0x00), \
|
||||||
PCNT_RETENTION_REGS_BASE, PCNT_RETENTION_REGS_BASE, \
|
PCNT_RETENTION_REGS_BASE, PCNT_RETENTION_REGS_BASE, \
|
||||||
PCNT_RETENTION_REGS_CNT, 0, 0, \
|
PCNT_RETENTION_REGS_CNT, 0, 0, \
|
||||||
pcnt_regs_map[0], pcnt_regs_map[1], \
|
pcnt_regs_map[0], pcnt_regs_map[1], \
|
||||||
pcnt_regs_map[2], pcnt_regs_map[3]), \
|
pcnt_regs_map[2], pcnt_regs_map[3]), \
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const pcnt_reg_retention_info_t pcnt_reg_retention_info[SOC_PCNT_GROUPS] = {
|
const pcnt_reg_retention_info_t pcnt_reg_retention_info[SOC_PCNT_GROUPS] = {
|
||||||
|
@@ -25,7 +25,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} gpio_ext_clock_gate_reg_t;
|
} gpio_ext_clock_gate_reg_t;
|
||||||
|
|
||||||
|
|
||||||
/** Group: SDM Configure Registers */
|
/** Group: SDM Configure Registers */
|
||||||
/** Type of sigmadelta_misc register
|
/** Type of sigmadelta_misc register
|
||||||
* MISC Register
|
* MISC Register
|
||||||
@@ -61,7 +60,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} gpio_ext_sigmadeltan_reg_t;
|
} gpio_ext_sigmadeltan_reg_t;
|
||||||
|
|
||||||
|
|
||||||
/** Group: Configure Registers */
|
/** Group: Configure Registers */
|
||||||
/** Type of pad_comp_config_0 register
|
/** Type of pad_comp_config_0 register
|
||||||
* Configuration register for zero-crossing detection
|
* Configuration register for zero-crossing detection
|
||||||
@@ -135,7 +133,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} gpio_ext_pin_ctrl_reg_t;
|
} gpio_ext_pin_ctrl_reg_t;
|
||||||
|
|
||||||
|
|
||||||
/** Group: Glitch filter Configure Registers */
|
/** Group: Glitch filter Configure Registers */
|
||||||
/** Type of glitch_filter_chn register
|
/** Type of glitch_filter_chn register
|
||||||
* Glitch Filter Configure Register of Channeln
|
* Glitch Filter Configure Register of Channeln
|
||||||
@@ -176,7 +173,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} gpio_ext_glitch_filter_chn_reg_t;
|
} gpio_ext_glitch_filter_chn_reg_t;
|
||||||
|
|
||||||
|
|
||||||
/** Group: Etm Configure Registers */
|
/** Group: Etm Configure Registers */
|
||||||
/** Type of etm_event_chn_cfg register
|
/** Type of etm_event_chn_cfg register
|
||||||
* Etm Config register of Channeln
|
* Etm Config register of Channeln
|
||||||
@@ -335,8 +331,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} gpio_ext_etm_task_pn_cfg_reg_t;
|
} gpio_ext_etm_task_pn_cfg_reg_t;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/** Group: Interrupt Registers */
|
/** Group: Interrupt Registers */
|
||||||
/** Type of int_raw register
|
/** Type of int_raw register
|
||||||
* GPIO_EXT interrupt raw register
|
* GPIO_EXT interrupt raw register
|
||||||
@@ -426,7 +420,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} gpio_ext_int_clr_reg_t;
|
} gpio_ext_int_clr_reg_t;
|
||||||
|
|
||||||
|
|
||||||
/** Group: Version Register */
|
/** Group: Version Register */
|
||||||
/** Type of version register
|
/** Type of version register
|
||||||
* Version Control Register
|
* Version Control Register
|
@@ -63,8 +63,10 @@ const regdma_entries_config_t iomux_regs_retention[] = {
|
|||||||
[1] = { .config = REGDMA_LINK_CONTINUOUS_INIT(REGDMA_IOMUX_LINK(0x01), GPIO_FUNC0_OUT_SEL_CFG_REG, GPIO_FUNC0_OUT_SEL_CFG_REG, N_REGS_IOMUX_1(), 0, 0), .owner = ENTRY(0) | ENTRY(2) },
|
[1] = { .config = REGDMA_LINK_CONTINUOUS_INIT(REGDMA_IOMUX_LINK(0x01), GPIO_FUNC0_OUT_SEL_CFG_REG, GPIO_FUNC0_OUT_SEL_CFG_REG, N_REGS_IOMUX_1(), 0, 0), .owner = ENTRY(0) | ENTRY(2) },
|
||||||
[2] = { .config = REGDMA_LINK_CONTINUOUS_INIT(REGDMA_IOMUX_LINK(0x02), GPIO_FUNC0_IN_SEL_CFG_REG, GPIO_FUNC0_IN_SEL_CFG_REG, N_REGS_IOMUX_2(), 0, 0), .owner = ENTRY(0) | ENTRY(2) },
|
[2] = { .config = REGDMA_LINK_CONTINUOUS_INIT(REGDMA_IOMUX_LINK(0x02), GPIO_FUNC0_IN_SEL_CFG_REG, GPIO_FUNC0_IN_SEL_CFG_REG, N_REGS_IOMUX_2(), 0, 0), .owner = ENTRY(0) | ENTRY(2) },
|
||||||
[3] = { .config = REGDMA_LINK_CONTINUOUS_INIT(REGDMA_IOMUX_LINK(0x03), GPIO_PIN0_REG, GPIO_PIN0_REG, N_REGS_IOMUX_3(), 0, 0), .owner = ENTRY(0) | ENTRY(2) },
|
[3] = { .config = REGDMA_LINK_CONTINUOUS_INIT(REGDMA_IOMUX_LINK(0x03), GPIO_PIN0_REG, GPIO_PIN0_REG, N_REGS_IOMUX_3(), 0, 0), .owner = ENTRY(0) | ENTRY(2) },
|
||||||
[4] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_IOMUX_LINK(0x04), GPIO_RETENTION_MAP_BASE, GPIO_RETENTION_MAP_BASE, GPIO_RETENTION_REGS_CNT, 0, 0,
|
[4] = {
|
||||||
gpio_regs_map[0], gpio_regs_map[1], gpio_regs_map[2], gpio_regs_map[3]), .owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_IOMUX_LINK(0x04), GPIO_RETENTION_MAP_BASE, GPIO_RETENTION_MAP_BASE, GPIO_RETENTION_REGS_CNT, 0, 0,
|
||||||
|
gpio_regs_map[0], gpio_regs_map[1], gpio_regs_map[2], gpio_regs_map[3]), .owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
_Static_assert(ARRAY_SIZE(iomux_regs_retention) == IOMUX_RETENTION_LINK_LEN, "Inconsistent IOMUX retention link length definitions");
|
_Static_assert(ARRAY_SIZE(iomux_regs_retention) == IOMUX_RETENTION_LINK_LEN, "Inconsistent IOMUX retention link length definitions");
|
||||||
|
|
||||||
|
@@ -29,8 +29,10 @@ const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_S
|
|||||||
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE APB_SARADC_INT_ENA_REG
|
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE APB_SARADC_INT_ENA_REG
|
||||||
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
||||||
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
||||||
|
@@ -10,7 +10,8 @@
|
|||||||
Bunch of constants for every UART peripheral: GPIO signals, irqs, hw addr of registers etc
|
Bunch of constants for every UART peripheral: GPIO signals, irqs, hw addr of registers etc
|
||||||
*/
|
*/
|
||||||
const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
||||||
{ // HP UART0
|
{
|
||||||
|
// HP UART0
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = U0TXD_GPIO_NUM,
|
.default_gpio = U0TXD_GPIO_NUM,
|
||||||
@@ -43,7 +44,8 @@ const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
|||||||
.irq = ETS_UART0_INTR_SOURCE,
|
.irq = ETS_UART0_INTR_SOURCE,
|
||||||
},
|
},
|
||||||
|
|
||||||
{ // HP UART1
|
{
|
||||||
|
// HP UART1
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = U1TXD_GPIO_NUM,
|
.default_gpio = U1TXD_GPIO_NUM,
|
||||||
@@ -76,7 +78,8 @@ const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
|||||||
.irq = ETS_UART1_INTR_SOURCE,
|
.irq = ETS_UART1_INTR_SOURCE,
|
||||||
},
|
},
|
||||||
|
|
||||||
{ // LP UART0
|
{
|
||||||
|
// LP UART0
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = LP_U0TXD_GPIO_NUM,
|
.default_gpio = LP_U0TXD_GPIO_NUM,
|
||||||
|
@@ -39,12 +39,14 @@ const gdma_signal_conn_t gdma_periph_signals = {
|
|||||||
#define G0P0_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH0_REG
|
#define G0P0_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH0_REG
|
||||||
static const uint32_t g0p0_regs_map[4] = {0x4C801001, 0x604C0060, 0, 0};
|
static const uint32_t g0p0_regs_map[4] = {0x4C801001, 0x604C0060, 0, 0};
|
||||||
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P0_RETENTION_MAP_BASE, G0P0_RETENTION_MAP_BASE, \
|
G0P0_RETENTION_MAP_BASE, G0P0_RETENTION_MAP_BASE, \
|
||||||
G0P0_RETENTION_REGS_CNT, 0, 0, \
|
G0P0_RETENTION_REGS_CNT, 0, 0, \
|
||||||
g0p0_regs_map[0], g0p0_regs_map[1], \
|
g0p0_regs_map[0], g0p0_regs_map[1], \
|
||||||
g0p0_regs_map[2], g0p0_regs_map[3]), \
|
g0p0_regs_map[2], g0p0_regs_map[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* GDMA Channel (Group0, Pair1) Registers Context
|
/* GDMA Channel (Group0, Pair1) Registers Context
|
||||||
@@ -57,12 +59,14 @@ static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
|||||||
#define G0P1_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH1_REG
|
#define G0P1_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH1_REG
|
||||||
static const uint32_t g0p1_regs_map[4] = {0x81001, 0, 0xC00604C0, 0x604};
|
static const uint32_t g0p1_regs_map[4] = {0x81001, 0, 0xC00604C0, 0x604};
|
||||||
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P1_RETENTION_MAP_BASE, G0P1_RETENTION_MAP_BASE, \
|
G0P1_RETENTION_MAP_BASE, G0P1_RETENTION_MAP_BASE, \
|
||||||
G0P1_RETENTION_REGS_CNT, 0, 0, \
|
G0P1_RETENTION_REGS_CNT, 0, 0, \
|
||||||
g0p1_regs_map[0], g0p1_regs_map[1], \
|
g0p1_regs_map[0], g0p1_regs_map[1], \
|
||||||
g0p1_regs_map[2], g0p1_regs_map[3]), \
|
g0p1_regs_map[2], g0p1_regs_map[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* GDMA Channel (Group0, Pair2) Registers Context
|
/* GDMA Channel (Group0, Pair2) Registers Context
|
||||||
@@ -78,18 +82,22 @@ static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
|||||||
static const uint32_t g0p2_regs_map0[4] = {0x9001, 0, 0, 0x4C0000};
|
static const uint32_t g0p2_regs_map0[4] = {0x9001, 0, 0, 0x4C0000};
|
||||||
static const uint32_t g0p2_regs_map1[4] = {0x3026003, 0, 0, 0};
|
static const uint32_t g0p2_regs_map1[4] = {0x3026003, 0, 0, 0};
|
||||||
static const regdma_entries_config_t gdma_g0p2_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p2_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P2_RETENTION_MAP_BASE_0, G0P2_RETENTION_MAP_BASE_0, \
|
G0P2_RETENTION_MAP_BASE_0, G0P2_RETENTION_MAP_BASE_0, \
|
||||||
G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
g0p2_regs_map0[0], g0p2_regs_map0[1], \
|
g0p2_regs_map0[0], g0p2_regs_map0[1], \
|
||||||
g0p2_regs_map0[2], g0p2_regs_map0[3]), \
|
g0p2_regs_map0[2], g0p2_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
G0P2_RETENTION_MAP_BASE_1, G0P2_RETENTION_MAP_BASE_1, \
|
G0P2_RETENTION_MAP_BASE_1, G0P2_RETENTION_MAP_BASE_1, \
|
||||||
G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
g0p2_regs_map1[0], g0p2_regs_map1[1], \
|
g0p2_regs_map1[0], g0p2_regs_map1[1], \
|
||||||
g0p2_regs_map1[2], g0p2_regs_map1[3]), \
|
g0p2_regs_map1[2], g0p2_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
||||||
|
@@ -45,16 +45,26 @@ const i2c_signal_conn_t i2c_periph_signal[SOC_I2C_NUM] = {
|
|||||||
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
||||||
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
||||||
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
||||||
[1] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[2] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
[1] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
||||||
[3] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[4] = {.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
[2] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[3] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[4] = {
|
||||||
|
.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
||||||
|
@@ -151,7 +151,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} modem_lpcon_date_reg_t;
|
} modem_lpcon_date_reg_t;
|
||||||
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
volatile modem_lpcon_test_conf_reg_t test_conf;
|
volatile modem_lpcon_test_conf_reg_t test_conf;
|
||||||
volatile modem_lpcon_lp_timer_conf_reg_t lp_timer_conf;
|
volatile modem_lpcon_lp_timer_conf_reg_t lp_timer_conf;
|
||||||
|
@@ -180,7 +180,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} modem_syscon_date_reg_t;
|
} modem_syscon_date_reg_t;
|
||||||
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
volatile modem_syscon_test_conf_reg_t test_conf;
|
volatile modem_syscon_test_conf_reg_t test_conf;
|
||||||
volatile modem_syscon_clk_conf_reg_t clk_conf;
|
volatile modem_syscon_clk_conf_reg_t clk_conf;
|
||||||
|
@@ -39,8 +39,6 @@
|
|||||||
/*Diagnostic Mode+UART0 download Mode*/
|
/*Diagnostic Mode+UART0 download Mode*/
|
||||||
#define IS_0111(v) (((v)&0x0f)==0x07)
|
#define IS_0111(v) (((v)&0x0f)==0x07)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
||||||
|
|
||||||
/*do not include download mode*/
|
/*do not include download mode*/
|
||||||
|
@@ -26,7 +26,6 @@ typedef enum clock_out_channel {
|
|||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
||||||
|
@@ -19,7 +19,6 @@ extern "C" {
|
|||||||
#define SOC_MMU_PAGE_SIZE 0x10000
|
#define SOC_MMU_PAGE_SIZE 0x10000
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
||||||
|
|
||||||
@@ -127,7 +126,6 @@ extern "C" {
|
|||||||
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ROM flash mmap driver needs below definitions
|
* ROM flash mmap driver needs below definitions
|
||||||
*/
|
*/
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@@ -14,7 +14,6 @@
|
|||||||
#define I2C_MST_BBPLL_STOP_FORCE_LOW (BIT(3))
|
#define I2C_MST_BBPLL_STOP_FORCE_LOW (BIT(3))
|
||||||
#define I2C_MST_BBPLL_CAL_DONE (BIT(24))
|
#define I2C_MST_BBPLL_CAL_DONE (BIT(24))
|
||||||
|
|
||||||
|
|
||||||
#define ANA_CONFIG_REG 0x600AF81C
|
#define ANA_CONFIG_REG 0x600AF81C
|
||||||
#define ANA_CONFIG_S (8)
|
#define ANA_CONFIG_S (8)
|
||||||
#define ANA_CONFIG_M (0x3FF)
|
#define ANA_CONFIG_M (0x3FF)
|
||||||
@@ -22,7 +21,6 @@
|
|||||||
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
||||||
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
||||||
|
|
||||||
|
|
||||||
#define ANA_CONFIG2_REG 0x600AF820
|
#define ANA_CONFIG2_REG 0x600AF820
|
||||||
#define ANA_CONFIG2_M BIT(18)
|
#define ANA_CONFIG2_M BIT(18)
|
||||||
|
|
||||||
|
@@ -22,7 +22,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
||||||
* @note refer to TRM: <Reset and Clock> chapter
|
* @note refer to TRM: <Reset and Clock> chapter
|
||||||
@@ -49,7 +48,6 @@ typedef enum {
|
|||||||
RESET_REASON_CPU0_JTAG = 0x18, // JTAG resets the CPU 0
|
RESET_REASON_CPU0_JTAG = 0x18, // JTAG resets the CPU 0
|
||||||
} soc_reset_reason_t;
|
} soc_reset_reason_t;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -555,7 +555,6 @@
|
|||||||
/* macro redefine for pass esp_wifi headers md5sum check */
|
/* macro redefine for pass esp_wifi headers md5sum check */
|
||||||
#define MAC_SUPPORT_PMU_MODEM_STATE SOC_PM_SUPPORT_PMU_MODEM_STATE
|
#define MAC_SUPPORT_PMU_MODEM_STATE SOC_PM_SUPPORT_PMU_MODEM_STATE
|
||||||
|
|
||||||
|
|
||||||
#define SOC_PM_SUPPORT_DEEPSLEEP_CHECK_STUB_ONLY (1) /*!<Supports CRC only the stub code in RTC memory */
|
#define SOC_PM_SUPPORT_DEEPSLEEP_CHECK_STUB_ONLY (1) /*!<Supports CRC only the stub code in RTC memory */
|
||||||
|
|
||||||
#define SOC_PM_CPU_RETENTION_BY_SW (1)
|
#define SOC_PM_CPU_RETENTION_BY_SW (1)
|
||||||
@@ -625,7 +624,6 @@
|
|||||||
/*------------------------------------- No Reset CAPS -------------------------------------*/
|
/*------------------------------------- No Reset CAPS -------------------------------------*/
|
||||||
#define SOC_CAPS_NO_RESET_BY_ANA_BOD (1)
|
#define SOC_CAPS_NO_RESET_BY_ANA_BOD (1)
|
||||||
|
|
||||||
|
|
||||||
/*------------------------------------- ULP CAPS -------------------------------------*/
|
/*------------------------------------- ULP CAPS -------------------------------------*/
|
||||||
#define SOC_LP_CORE_SINGLE_INTERRUPT_VECTOR (1) /*!< LP Core interrupts all map to a single entry in vector table */
|
#define SOC_LP_CORE_SINGLE_INTERRUPT_VECTOR (1) /*!< LP Core interrupts all map to a single entry in vector table */
|
||||||
#define SOC_LP_CORE_SUPPORT_ETM (1) /*!< LP Core supports ETM */
|
#define SOC_LP_CORE_SUPPORT_ETM (1) /*!< LP Core supports ETM */
|
||||||
|
@@ -44,16 +44,20 @@ static const uint32_t ledc_common_regs_map[4] = {0x1, 0x1c00000, 0x400, 0x0};
|
|||||||
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
||||||
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
||||||
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
||||||
[0] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
||||||
LEDC_INT_ENA_REG, 0,
|
LEDC_INT_ENA_REG, 0,
|
||||||
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
||||||
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
||||||
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
||||||
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
||||||
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
||||||
|
@@ -103,19 +103,25 @@ static const uint32_t mcpwm_regs_map[4] = {0xefffeeef, 0x7efffbff, 0x318, 0x0};
|
|||||||
static const regdma_entries_config_t mcpwm_regs_retention[] = {
|
static const regdma_entries_config_t mcpwm_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_MCPWM_LINK(0x00),
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_MCPWM_LINK(0x00),
|
||||||
MCPWM_RETENTION_REGS_BASE, MCPWM_RETENTION_REGS_BASE,
|
MCPWM_RETENTION_REGS_BASE, MCPWM_RETENTION_REGS_BASE,
|
||||||
MCPWM_RETENTION_REGS_CNT, 0, 0,
|
MCPWM_RETENTION_REGS_CNT, 0, 0,
|
||||||
mcpwm_regs_map[0], mcpwm_regs_map[1],
|
mcpwm_regs_map[0], mcpwm_regs_map[1],
|
||||||
mcpwm_regs_map[2], mcpwm_regs_map[3]),
|
mcpwm_regs_map[2], mcpwm_regs_map[3]),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
},
|
||||||
// restore stage: trigger a forced update of all active registers
|
// restore stage: trigger a forced update of all active registers
|
||||||
[1] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x01),
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x01),
|
||||||
MCPWM_UPDATE_CFG_REG(0), MCPWM_GLOBAL_FORCE_UP, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
MCPWM_UPDATE_CFG_REG(0), MCPWM_GLOBAL_FORCE_UP, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
[2] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x02),
|
},
|
||||||
|
[2] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x02),
|
||||||
MCPWM_UPDATE_CFG_REG(0), 0, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
MCPWM_UPDATE_CFG_REG(0), 0, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const mcpwm_reg_retention_info_t mcpwm_reg_retention_info[SOC_MCPWM_GROUPS] = {
|
const mcpwm_reg_retention_info_t mcpwm_reg_retention_info[SOC_MCPWM_GROUPS] = {
|
||||||
|
@@ -76,12 +76,14 @@ static const uint32_t parlio_regs_map[4] = {0x2f, 0x0, 0x100, 0x0};
|
|||||||
static const regdma_entries_config_t parlio_regs_retention[] = {
|
static const regdma_entries_config_t parlio_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PARLIO_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PARLIO_LINK(0x00), \
|
||||||
PARLIO_RETENTION_REGS_BASE, PARLIO_RETENTION_REGS_BASE, \
|
PARLIO_RETENTION_REGS_BASE, PARLIO_RETENTION_REGS_BASE, \
|
||||||
PARLIO_RETENTION_REGS_CNT, 0, 0, \
|
PARLIO_RETENTION_REGS_CNT, 0, 0, \
|
||||||
parlio_regs_map[0], parlio_regs_map[1], \
|
parlio_regs_map[0], parlio_regs_map[1], \
|
||||||
parlio_regs_map[2], parlio_regs_map[3]), \
|
parlio_regs_map[2], parlio_regs_map[3]), \
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
const parlio_reg_retention_info_t parlio_reg_retention_info[SOC_PARLIO_GROUPS] = {
|
const parlio_reg_retention_info_t parlio_reg_retention_info[SOC_PARLIO_GROUPS] = {
|
||||||
[0] = {
|
[0] = {
|
||||||
|
@@ -77,12 +77,14 @@ static const uint32_t pcnt_regs_map[4] = {0x1040fff, 0x0, 0x0, 0x0};
|
|||||||
static const regdma_entries_config_t pcnt_regs_retention[] = {
|
static const regdma_entries_config_t pcnt_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PCNT_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PCNT_LINK(0x00), \
|
||||||
PCNT_RETENTION_REGS_BASE, PCNT_RETENTION_REGS_BASE, \
|
PCNT_RETENTION_REGS_BASE, PCNT_RETENTION_REGS_BASE, \
|
||||||
PCNT_RETENTION_REGS_CNT, 0, 0, \
|
PCNT_RETENTION_REGS_CNT, 0, 0, \
|
||||||
pcnt_regs_map[0], pcnt_regs_map[1], \
|
pcnt_regs_map[0], pcnt_regs_map[1], \
|
||||||
pcnt_regs_map[2], pcnt_regs_map[3]), \
|
pcnt_regs_map[2], pcnt_regs_map[3]), \
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const pcnt_reg_retention_info_t pcnt_reg_retention_info[SOC_PCNT_GROUPS] = {
|
const pcnt_reg_retention_info_t pcnt_reg_retention_info[SOC_PCNT_GROUPS] = {
|
||||||
|
@@ -39,7 +39,6 @@ const spi_signal_conn_t spi_periph_signal[SOC_SPI_PERIPH_NUM] = {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Backup registers in Light sleep: (total cnt 12)
|
* Backup registers in Light sleep: (total cnt 12)
|
||||||
*
|
*
|
||||||
|
@@ -29,8 +29,10 @@ const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_S
|
|||||||
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE APB_SARADC_INT_ENA_REG
|
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE APB_SARADC_INT_ENA_REG
|
||||||
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
||||||
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
||||||
|
@@ -11,7 +11,8 @@
|
|||||||
Bunch of constants for every UART peripheral: GPIO signals, irqs, hw addr of registers etc
|
Bunch of constants for every UART peripheral: GPIO signals, irqs, hw addr of registers etc
|
||||||
*/
|
*/
|
||||||
const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
||||||
{ // HP UART0
|
{
|
||||||
|
// HP UART0
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = U0TXD_GPIO_NUM,
|
.default_gpio = U0TXD_GPIO_NUM,
|
||||||
@@ -44,7 +45,8 @@ const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
|||||||
.irq = ETS_UART0_INTR_SOURCE,
|
.irq = ETS_UART0_INTR_SOURCE,
|
||||||
},
|
},
|
||||||
|
|
||||||
{ // HP UART1
|
{
|
||||||
|
// HP UART1
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = U1TXD_GPIO_NUM,
|
.default_gpio = U1TXD_GPIO_NUM,
|
||||||
@@ -77,7 +79,8 @@ const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
|||||||
.irq = ETS_UART1_INTR_SOURCE,
|
.irq = ETS_UART1_INTR_SOURCE,
|
||||||
},
|
},
|
||||||
|
|
||||||
{ // LP UART0
|
{
|
||||||
|
// LP UART0
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = LP_U0TXD_GPIO_NUM,
|
.default_gpio = LP_U0TXD_GPIO_NUM,
|
||||||
|
@@ -45,18 +45,22 @@ const gdma_signal_conn_t gdma_periph_signals = {
|
|||||||
static const uint32_t g0p0_regs_map0[4] = {0x4c801001, 0x604c0060, 0x0, 0x0};
|
static const uint32_t g0p0_regs_map0[4] = {0x4c801001, 0x604c0060, 0x0, 0x0};
|
||||||
static const uint32_t g0p0_regs_map1[4] = {0xc0000003, 0xfc900000, 0x0, 0x0};
|
static const uint32_t g0p0_regs_map1[4] = {0xc0000003, 0xfc900000, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P0_RETENTION_MAP_BASE_0, G0P0_RETENTION_MAP_BASE_0, \
|
G0P0_RETENTION_MAP_BASE_0, G0P0_RETENTION_MAP_BASE_0, \
|
||||||
G0P0_RETENTION_REGS_CNT_0, 0, 0, \
|
G0P0_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
g0p0_regs_map0[0], g0p0_regs_map0[1], \
|
g0p0_regs_map0[0], g0p0_regs_map0[1], \
|
||||||
g0p0_regs_map0[2], g0p0_regs_map0[3]), \
|
g0p0_regs_map0[2], g0p0_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY }, \
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
}, \
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
G0P0_RETENTION_MAP_BASE_1, G0P0_RETENTION_MAP_BASE_1, \
|
G0P0_RETENTION_MAP_BASE_1, G0P0_RETENTION_MAP_BASE_1, \
|
||||||
G0P0_RETENTION_REGS_CNT_1, 0, 0, \
|
G0P0_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
g0p0_regs_map1[0], g0p0_regs_map1[1], \
|
g0p0_regs_map1[0], g0p0_regs_map1[1], \
|
||||||
g0p0_regs_map1[2], g0p0_regs_map1[3]), \
|
g0p0_regs_map1[2], g0p0_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AHB_DMA Channel (Group0, Pair1) Registers Context
|
/* AHB_DMA Channel (Group0, Pair1) Registers Context
|
||||||
@@ -79,18 +83,22 @@ static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
|||||||
static const uint32_t g0p1_regs_map0[4] = {0x81001, 0x0, 0xc00604c0, 0x604};
|
static const uint32_t g0p1_regs_map0[4] = {0x81001, 0x0, 0xc00604c0, 0x604};
|
||||||
static const uint32_t g0p1_regs_map1[4] = {0xc0000003, 0x3f4800, 0x0, 0x0};
|
static const uint32_t g0p1_regs_map1[4] = {0xc0000003, 0x3f4800, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P1_RETENTION_MAP_BASE_0, G0P1_RETENTION_MAP_BASE_0, \
|
G0P1_RETENTION_MAP_BASE_0, G0P1_RETENTION_MAP_BASE_0, \
|
||||||
G0P1_RETENTION_REGS_CNT_0, 0, 0, \
|
G0P1_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
g0p1_regs_map0[0], g0p1_regs_map0[1], \
|
g0p1_regs_map0[0], g0p1_regs_map0[1], \
|
||||||
g0p1_regs_map0[2], g0p1_regs_map0[3]), \
|
g0p1_regs_map0[2], g0p1_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
G0P1_RETENTION_MAP_BASE_1, G0P1_RETENTION_MAP_BASE_1, \
|
G0P1_RETENTION_MAP_BASE_1, G0P1_RETENTION_MAP_BASE_1, \
|
||||||
G0P1_RETENTION_REGS_CNT_1, 0, 0, \
|
G0P1_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
g0p1_regs_map1[0], g0p1_regs_map1[1], \
|
g0p1_regs_map1[0], g0p1_regs_map1[1], \
|
||||||
g0p1_regs_map1[2], g0p1_regs_map1[3]), \
|
g0p1_regs_map1[2], g0p1_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
||||||
|
@@ -7,7 +7,6 @@
|
|||||||
#include "soc/i2c_periph.h"
|
#include "soc/i2c_periph.h"
|
||||||
#include "soc/gpio_sig_map.h"
|
#include "soc/gpio_sig_map.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Bunch of constants for every I2C peripheral: GPIO signals, irqs, hw addr of registers etc
|
Bunch of constants for every I2C peripheral: GPIO signals, irqs, hw addr of registers etc
|
||||||
*/
|
*/
|
||||||
@@ -35,16 +34,26 @@ const i2c_signal_conn_t i2c_periph_signal[SOC_I2C_NUM] = {
|
|||||||
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG
|
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG
|
||||||
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
||||||
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
||||||
[1] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG, I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[2] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG, 0x0, I2C_FSM_RST_M, 1, 0), \
|
[1] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG, I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
||||||
[3] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG, I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[4] = {.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG, 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
[2] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG, 0x0, I2C_FSM_RST_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[3] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG, I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[4] = {
|
||||||
|
.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG, 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
||||||
|
@@ -39,8 +39,6 @@
|
|||||||
/*Diagnostic Mode+UART0 download Mode*/
|
/*Diagnostic Mode+UART0 download Mode*/
|
||||||
#define IS_0111(v) (((v)&0x0f)==0x07)
|
#define IS_0111(v) (((v)&0x0f)==0x07)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
||||||
|
|
||||||
/*do not include download mode*/
|
/*do not include download mode*/
|
||||||
|
@@ -26,7 +26,6 @@ typedef enum clock_out_channel {
|
|||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
||||||
|
@@ -19,7 +19,6 @@ extern "C" {
|
|||||||
#define SOC_MMU_PAGE_SIZE 0x10000
|
#define SOC_MMU_PAGE_SIZE 0x10000
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
||||||
|
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@@ -51,7 +51,6 @@ typedef enum {
|
|||||||
#define PERIPH_MODEM_MODULE_NUM (PERIPH_MODEM_MODULE_MAX - PERIPH_MODEM_MODULE_MIN + 1)
|
#define PERIPH_MODEM_MODULE_NUM (PERIPH_MODEM_MODULE_MAX - PERIPH_MODEM_MODULE_MIN + 1)
|
||||||
#define IS_MODEM_MODULE(periph) ((periph>=PERIPH_MODEM_MODULE_MIN) && (periph<=PERIPH_MODEM_MODULE_MAX))
|
#define IS_MODEM_MODULE(periph) ((periph>=PERIPH_MODEM_MODULE_MIN) && (periph<=PERIPH_MODEM_MODULE_MAX))
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -18,8 +18,6 @@
|
|||||||
#define I2C_SAR_ADC 0X69
|
#define I2C_SAR_ADC 0X69
|
||||||
#define I2C_SAR_ADC_HOSTID 0
|
#define I2C_SAR_ADC_HOSTID 0
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define ADC_SAR1_INITIAL_CODE_LOW_ADDR 0x0
|
#define ADC_SAR1_INITIAL_CODE_LOW_ADDR 0x0
|
||||||
#define ADC_SAR1_INITIAL_CODE_LOW_ADDR_MSB 0x7
|
#define ADC_SAR1_INITIAL_CODE_LOW_ADDR_MSB 0x7
|
||||||
#define ADC_SAR1_INITIAL_CODE_LOW_ADDR_LSB 0x0
|
#define ADC_SAR1_INITIAL_CODE_LOW_ADDR_LSB 0x0
|
||||||
@@ -80,7 +78,6 @@
|
|||||||
#define ADC_SAR2_ENCAL_GND_ADDR_MSB 7
|
#define ADC_SAR2_ENCAL_GND_ADDR_MSB 7
|
||||||
#define ADC_SAR2_ENCAL_GND_ADDR_LSB 7
|
#define ADC_SAR2_ENCAL_GND_ADDR_LSB 7
|
||||||
|
|
||||||
|
|
||||||
#define POWER_GLITCH_DREF_VDET_PERIF 11
|
#define POWER_GLITCH_DREF_VDET_PERIF 11
|
||||||
#define POWER_GLITCH_DREF_VDET_PERIF_MSB 2
|
#define POWER_GLITCH_DREF_VDET_PERIF_MSB 2
|
||||||
#define POWER_GLITCH_DREF_VDET_PERIF_LSB 0
|
#define POWER_GLITCH_DREF_VDET_PERIF_LSB 0
|
||||||
|
@@ -22,7 +22,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
||||||
* @note refer to TRM: <Reset and Clock> chapter
|
* @note refer to TRM: <Reset and Clock> chapter
|
||||||
@@ -50,7 +49,6 @@ typedef enum {
|
|||||||
RESET_REASON_CPU_LOCKUP = 0x1A, // CPU lockup resets
|
RESET_REASON_CPU_LOCKUP = 0x1A, // CPU lockup resets
|
||||||
} soc_reset_reason_t;
|
} soc_reset_reason_t;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -44,16 +44,20 @@ static const uint32_t ledc_common_regs_map[4] = {0x1c00001, 0x400, 0x0, 0x0};
|
|||||||
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
||||||
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
||||||
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
||||||
[0] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
||||||
LEDC_INT_ENA_REG, 0,
|
LEDC_INT_ENA_REG, 0,
|
||||||
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
||||||
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
||||||
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
||||||
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
||||||
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
||||||
|
@@ -29,8 +29,10 @@ const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_S
|
|||||||
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE SARADC_INT_ENA_REG
|
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE SARADC_INT_ENA_REG
|
||||||
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
||||||
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
||||||
|
@@ -11,7 +11,8 @@
|
|||||||
Bunch of constants for every UART peripheral: GPIO signals, irqs, hw addr of registers etc
|
Bunch of constants for every UART peripheral: GPIO signals, irqs, hw addr of registers etc
|
||||||
*/
|
*/
|
||||||
const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
||||||
{ // HP UART0
|
{
|
||||||
|
// HP UART0
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = U0TXD_GPIO_NUM,
|
.default_gpio = U0TXD_GPIO_NUM,
|
||||||
@@ -44,7 +45,8 @@ const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
|||||||
.irq = ETS_UART0_INTR_SOURCE,
|
.irq = ETS_UART0_INTR_SOURCE,
|
||||||
},
|
},
|
||||||
|
|
||||||
{ // HP UART1
|
{
|
||||||
|
// HP UART1
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = U1TXD_GPIO_NUM,
|
.default_gpio = U1TXD_GPIO_NUM,
|
||||||
@@ -76,7 +78,8 @@ const uart_signal_conn_t uart_periph_signal[SOC_UART_NUM] = {
|
|||||||
},
|
},
|
||||||
.irq = ETS_UART1_INTR_SOURCE,
|
.irq = ETS_UART1_INTR_SOURCE,
|
||||||
},
|
},
|
||||||
{ // HP UART2
|
{
|
||||||
|
// HP UART2
|
||||||
.pins = {
|
.pins = {
|
||||||
[SOC_UART_TX_PIN_IDX] = {
|
[SOC_UART_TX_PIN_IDX] = {
|
||||||
.default_gpio = U2TXD_GPIO_NUM,
|
.default_gpio = U2TXD_GPIO_NUM,
|
||||||
|
@@ -39,12 +39,14 @@ const gdma_signal_conn_t gdma_periph_signals = {
|
|||||||
#define G0P0_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH0_REG
|
#define G0P0_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH0_REG
|
||||||
static const uint32_t g0p0_regs_map[4] = {0x4C801001, 0x604C0060, 0, 0};
|
static const uint32_t g0p0_regs_map[4] = {0x4C801001, 0x604C0060, 0, 0};
|
||||||
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P0_RETENTION_MAP_BASE, G0P0_RETENTION_MAP_BASE, \
|
G0P0_RETENTION_MAP_BASE, G0P0_RETENTION_MAP_BASE, \
|
||||||
G0P0_RETENTION_REGS_CNT, 0, 0, \
|
G0P0_RETENTION_REGS_CNT, 0, 0, \
|
||||||
g0p0_regs_map[0], g0p0_regs_map[1], \
|
g0p0_regs_map[0], g0p0_regs_map[1], \
|
||||||
g0p0_regs_map[2], g0p0_regs_map[3]), \
|
g0p0_regs_map[2], g0p0_regs_map[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* GDMA Channel (Group0, Pair1) Registers Context
|
/* GDMA Channel (Group0, Pair1) Registers Context
|
||||||
@@ -57,12 +59,14 @@ static const regdma_entries_config_t gdma_g0p0_regs_retention[] = {
|
|||||||
#define G0P1_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH1_REG
|
#define G0P1_RETENTION_MAP_BASE GDMA_IN_INT_ENA_CH1_REG
|
||||||
static const uint32_t g0p1_regs_map[4] = {0x81001, 0, 0xC00604C0, 0x604};
|
static const uint32_t g0p1_regs_map[4] = {0x81001, 0, 0xC00604C0, 0x604};
|
||||||
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P1_RETENTION_MAP_BASE, G0P1_RETENTION_MAP_BASE, \
|
G0P1_RETENTION_MAP_BASE, G0P1_RETENTION_MAP_BASE, \
|
||||||
G0P1_RETENTION_REGS_CNT, 0, 0, \
|
G0P1_RETENTION_REGS_CNT, 0, 0, \
|
||||||
g0p1_regs_map[0], g0p1_regs_map[1], \
|
g0p1_regs_map[0], g0p1_regs_map[1], \
|
||||||
g0p1_regs_map[2], g0p1_regs_map[3]), \
|
g0p1_regs_map[2], g0p1_regs_map[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* GDMA Channel (Group0, Pair2) Registers Context
|
/* GDMA Channel (Group0, Pair2) Registers Context
|
||||||
@@ -78,18 +82,22 @@ static const regdma_entries_config_t gdma_g0p1_regs_retention[] = {
|
|||||||
static const uint32_t g0p2_regs_map0[4] = {0x9001, 0, 0, 0x4C0000};
|
static const uint32_t g0p2_regs_map0[4] = {0x9001, 0, 0, 0x4C0000};
|
||||||
static const uint32_t g0p2_regs_map1[4] = {0x3026003, 0, 0, 0};
|
static const uint32_t g0p2_regs_map1[4] = {0x3026003, 0, 0, 0};
|
||||||
static const regdma_entries_config_t gdma_g0p2_regs_retention[] = {
|
static const regdma_entries_config_t gdma_g0p2_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
G0P2_RETENTION_MAP_BASE_0, G0P2_RETENTION_MAP_BASE_0, \
|
G0P2_RETENTION_MAP_BASE_0, G0P2_RETENTION_MAP_BASE_0, \
|
||||||
G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
g0p2_regs_map0[0], g0p2_regs_map0[1], \
|
g0p2_regs_map0[0], g0p2_regs_map0[1], \
|
||||||
g0p2_regs_map0[2], g0p2_regs_map0[3]), \
|
g0p2_regs_map0[2], g0p2_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
G0P2_RETENTION_MAP_BASE_1, G0P2_RETENTION_MAP_BASE_1, \
|
G0P2_RETENTION_MAP_BASE_1, G0P2_RETENTION_MAP_BASE_1, \
|
||||||
G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
g0p2_regs_map1[0], g0p2_regs_map1[1], \
|
g0p2_regs_map1[0], g0p2_regs_map1[1], \
|
||||||
g0p2_regs_map1[2], g0p2_regs_map1[3]), \
|
g0p2_regs_map1[2], g0p2_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
||||||
|
@@ -42,32 +42,52 @@ const i2c_signal_conn_t i2c_periph_signal[SOC_I2C_NUM] = {
|
|||||||
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
||||||
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
||||||
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
||||||
[1] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[2] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
[1] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
||||||
[3] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[4] = {.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
[2] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[3] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[4] = {
|
||||||
|
.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
#define I2C1_RETENTION_REGS_CNT 18
|
#define I2C1_RETENTION_REGS_CNT 18
|
||||||
#define I2C1_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(1)
|
#define I2C1_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(1)
|
||||||
static const uint32_t i2c1_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
static const uint32_t i2c1_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
||||||
static const regdma_entries_config_t i2c1_regs_retention[] = {
|
static const regdma_entries_config_t i2c1_regs_retention[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_REGS_CNT, 0, 0, i2c1_regs_map[0], i2c1_regs_map[1], i2c1_regs_map[2], i2c1_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_REGS_CNT, 0, 0, i2c1_regs_map[0], i2c1_regs_map[1], i2c1_regs_map[2], i2c1_regs_map[3]), \
|
||||||
[1] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(1), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[2] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(1), 0x0, I2C_FSM_RST_M, 1, 0), \
|
[1] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(1), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
||||||
[3] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(1), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
}, \
|
||||||
[4] = {.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(1), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
[2] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(1), 0x0, I2C_FSM_RST_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[3] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(1), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
|
[4] = {
|
||||||
|
.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(1), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
||||||
|
@@ -101,7 +101,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} modem_lpcon_date_reg_t;
|
} modem_lpcon_date_reg_t;
|
||||||
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
volatile modem_lpcon_test_conf_reg_t test_conf;
|
volatile modem_lpcon_test_conf_reg_t test_conf;
|
||||||
volatile modem_lpcon_coex_lp_clk_conf_reg_t coex_lp_clk_conf;
|
volatile modem_lpcon_coex_lp_clk_conf_reg_t coex_lp_clk_conf;
|
||||||
|
@@ -117,7 +117,6 @@ typedef union {
|
|||||||
uint32_t val;
|
uint32_t val;
|
||||||
} modem_syscon_date_reg_t;
|
} modem_syscon_date_reg_t;
|
||||||
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
volatile modem_syscon_test_conf_reg_t test_conf;
|
volatile modem_syscon_test_conf_reg_t test_conf;
|
||||||
volatile modem_syscon_clk_conf_reg_t clk_conf;
|
volatile modem_syscon_clk_conf_reg_t clk_conf;
|
||||||
|
@@ -39,8 +39,6 @@
|
|||||||
/*Diagnostic Mode+UART0 download Mode*/
|
/*Diagnostic Mode+UART0 download Mode*/
|
||||||
#define IS_0111(v) (((v)&0x0f)==0x07)
|
#define IS_0111(v) (((v)&0x0f)==0x07)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
||||||
|
|
||||||
/*do not include download mode*/
|
/*do not include download mode*/
|
||||||
|
@@ -26,7 +26,6 @@ typedef enum clock_out_channel {
|
|||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT_OUT2_IDX : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT_OUT3_IDX : SIG_GPIO_OUT_IDX)
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
#define CLKOUT_CHANNEL_MASK(channel) ((channel == CLKOUT_CHANNEL_1) ? CLK_OUT1 : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
(channel == CLKOUT_CHANNEL_2) ? CLK_OUT2 : \
|
||||||
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
(channel == CLKOUT_CHANNEL_3) ? CLK_OUT3 : 0)
|
||||||
|
@@ -19,7 +19,6 @@ extern "C" {
|
|||||||
#define SOC_MMU_PAGE_SIZE 0x10000
|
#define SOC_MMU_PAGE_SIZE 0x10000
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
#define SOC_IRAM0_CACHE_ADDRESS_LOW 0x42000000
|
||||||
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
#define SOC_IRAM0_CACHE_ADDRESS_HIGH (SOC_IRAM0_CACHE_ADDRESS_LOW + ((SOC_MMU_PAGE_SIZE) * SOC_MMU_ENTRY_NUM))
|
||||||
|
|
||||||
@@ -127,7 +126,6 @@ extern "C" {
|
|||||||
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
_Static_assert(SOC_MMU_IRAM0_LINEAR_ADDRESS_LOW == SOC_MMU_DRAM0_LINEAR_ADDRESS_LOW, "IRAM0 and DRAM0 linear address should be same");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ROM flash mmap driver needs below definitions
|
* ROM flash mmap driver needs below definitions
|
||||||
*/
|
*/
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@@ -21,7 +21,6 @@
|
|||||||
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
#define ANA_I2C_SAR_FORCE_PD BIT(18)
|
||||||
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
#define ANA_I2C_BBPLL_M BIT(17) /* Clear to enable BBPLL */
|
||||||
|
|
||||||
|
|
||||||
// I2C_MST_ANA_CONF2_REG
|
// I2C_MST_ANA_CONF2_REG
|
||||||
#define ANA_CONFIG2_M BIT(18)
|
#define ANA_CONFIG2_M BIT(18)
|
||||||
|
|
||||||
|
@@ -22,7 +22,6 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
* @brief Naming conventions: RESET_REASON_{reset level}_{reset reason}
|
||||||
* @note refer to TRM: <Reset and Clock> chapter
|
* @note refer to TRM: <Reset and Clock> chapter
|
||||||
@@ -49,7 +48,6 @@ typedef enum {
|
|||||||
RESET_REASON_CPU0_JTAG = 0x18, // JTAG resets the CPU 0
|
RESET_REASON_CPU0_JTAG = 0x18, // JTAG resets the CPU 0
|
||||||
} soc_reset_reason_t;
|
} soc_reset_reason_t;
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -44,16 +44,20 @@ static const uint32_t ledc_common_regs_map[4] = {0x1, 0x1c00000, 0x400, 0x0};
|
|||||||
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
static const regdma_entries_config_t ledc_common_regdma_entries[] = {
|
||||||
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
// If a fade is in process, the DUTY_CHNG_END_CHx intr bit is enabled, however, we don't want it to be restored after wake-up (no fade after wake-up).
|
||||||
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
// Therefore, we can set it to 0 before backup the LEDC_INT_ENA_REG.
|
||||||
[0] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_LEDC_LINK(0x00),
|
||||||
LEDC_INT_ENA_REG, 0,
|
LEDC_INT_ENA_REG, 0,
|
||||||
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
(LEDC_DUTY_CHNG_END_CH0_INT_ENA_M | LEDC_DUTY_CHNG_END_CH1_INT_ENA_M | LEDC_DUTY_CHNG_END_CH2_INT_ENA_M | LEDC_DUTY_CHNG_END_CH3_INT_ENA_M | LEDC_DUTY_CHNG_END_CH4_INT_ENA_M | LEDC_DUTY_CHNG_END_CH5_INT_ENA_M), 0, 1),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_LEDC_LINK(0x01),
|
||||||
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
LEDC_COMMON_RETENTION_REGS_BASE, LEDC_COMMON_RETENTION_REGS_BASE,
|
||||||
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
LEDC_COMMON_RETENTION_REGS_CNT, 0, 0,
|
||||||
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
ledc_common_regs_map[0], ledc_common_regs_map[1],
|
||||||
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
ledc_common_regs_map[2], ledc_common_regs_map[3]),
|
||||||
.owner = LEDC_RETENTION_ENTRY },
|
.owner = LEDC_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
#define LEDC_TIMER_RETENTION_ENTRIES(timer) { \
|
||||||
|
@@ -103,19 +103,25 @@ static const uint32_t mcpwm_regs_map[4] = {0xefffeeef, 0x7efffbff, 0x318, 0x0};
|
|||||||
static const regdma_entries_config_t mcpwm_regs_retention[] = {
|
static const regdma_entries_config_t mcpwm_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_MCPWM_LINK(0x00),
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_MCPWM_LINK(0x00),
|
||||||
MCPWM_RETENTION_REGS_BASE, MCPWM_RETENTION_REGS_BASE,
|
MCPWM_RETENTION_REGS_BASE, MCPWM_RETENTION_REGS_BASE,
|
||||||
MCPWM_RETENTION_REGS_CNT, 0, 0,
|
MCPWM_RETENTION_REGS_CNT, 0, 0,
|
||||||
mcpwm_regs_map[0], mcpwm_regs_map[1],
|
mcpwm_regs_map[0], mcpwm_regs_map[1],
|
||||||
mcpwm_regs_map[2], mcpwm_regs_map[3]),
|
mcpwm_regs_map[2], mcpwm_regs_map[3]),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
},
|
||||||
// restore stage: trigger a forced update of all active registers
|
// restore stage: trigger a forced update of all active registers
|
||||||
[1] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x01),
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x01),
|
||||||
MCPWM_UPDATE_CFG_REG, MCPWM_GLOBAL_FORCE_UP, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
MCPWM_UPDATE_CFG_REG, MCPWM_GLOBAL_FORCE_UP, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
[2] = { .config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x02),
|
},
|
||||||
|
[2] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_MCPWM_LINK(0x02),
|
||||||
MCPWM_UPDATE_CFG_REG, 0, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
MCPWM_UPDATE_CFG_REG, 0, MCPWM_GLOBAL_FORCE_UP_M, 1, 0),
|
||||||
.owner = ENTRY(0) | ENTRY(2) },
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const mcpwm_reg_retention_info_t mcpwm_reg_retention_info[SOC_MCPWM_GROUPS] = {
|
const mcpwm_reg_retention_info_t mcpwm_reg_retention_info[SOC_MCPWM_GROUPS] = {
|
||||||
|
@@ -62,12 +62,14 @@ static const uint32_t parlio_regs_map[4] = {0x60457, 0x0, 0x0, 0x0};
|
|||||||
static const regdma_entries_config_t parlio_regs_retention[] = {
|
static const regdma_entries_config_t parlio_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PARLIO_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PARLIO_LINK(0x00), \
|
||||||
PARLIO_RETENTION_REGS_BASE, PARLIO_RETENTION_REGS_BASE, \
|
PARLIO_RETENTION_REGS_BASE, PARLIO_RETENTION_REGS_BASE, \
|
||||||
PARLIO_RETENTION_REGS_CNT, 0, 0, \
|
PARLIO_RETENTION_REGS_CNT, 0, 0, \
|
||||||
parlio_regs_map[0], parlio_regs_map[1], \
|
parlio_regs_map[0], parlio_regs_map[1], \
|
||||||
parlio_regs_map[2], parlio_regs_map[3]), \
|
parlio_regs_map[2], parlio_regs_map[3]), \
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
const parlio_reg_retention_info_t parlio_reg_retention_info[SOC_PARLIO_GROUPS] = {
|
const parlio_reg_retention_info_t parlio_reg_retention_info[SOC_PARLIO_GROUPS] = {
|
||||||
[0] = {
|
[0] = {
|
||||||
|
@@ -77,12 +77,14 @@ static const uint32_t pcnt_regs_map[4] = {0x1040fff, 0x0, 0x0, 0x0};
|
|||||||
static const regdma_entries_config_t pcnt_regs_retention[] = {
|
static const regdma_entries_config_t pcnt_regs_retention[] = {
|
||||||
// backup stage: save configuration registers
|
// backup stage: save configuration registers
|
||||||
// restore stage: restore the configuration registers
|
// restore stage: restore the configuration registers
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PCNT_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_PCNT_LINK(0x00), \
|
||||||
PCNT_RETENTION_REGS_BASE, PCNT_RETENTION_REGS_BASE, \
|
PCNT_RETENTION_REGS_BASE, PCNT_RETENTION_REGS_BASE, \
|
||||||
PCNT_RETENTION_REGS_CNT, 0, 0, \
|
PCNT_RETENTION_REGS_CNT, 0, 0, \
|
||||||
pcnt_regs_map[0], pcnt_regs_map[1], \
|
pcnt_regs_map[0], pcnt_regs_map[1], \
|
||||||
pcnt_regs_map[2], pcnt_regs_map[3]), \
|
pcnt_regs_map[2], pcnt_regs_map[3]), \
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const pcnt_reg_retention_info_t pcnt_reg_retention_info[SOC_PCNT_GROUPS] = {
|
const pcnt_reg_retention_info_t pcnt_reg_retention_info[SOC_PCNT_GROUPS] = {
|
||||||
|
@@ -9,7 +9,6 @@
|
|||||||
#include "soc/temperature_sensor_periph.h"
|
#include "soc/temperature_sensor_periph.h"
|
||||||
#include "soc/apb_saradc_reg.h"
|
#include "soc/apb_saradc_reg.h"
|
||||||
|
|
||||||
|
|
||||||
const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = {
|
const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = {
|
||||||
/*Offset reg_val min max error */
|
/*Offset reg_val min max error */
|
||||||
{-2, 5, 50, 125, 3},
|
{-2, 5, 50, 125, 3},
|
||||||
@@ -30,8 +29,10 @@ const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_S
|
|||||||
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE APB_SARADC_INT_ENA_REG
|
#define TEMPERATURE_SENSOR_RETENTION_MAP_BASE APB_SARADC_INT_ENA_REG
|
||||||
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
static const uint32_t temperature_sensor_regs_map[4] = {0x6c1, 0, 0, 0};
|
||||||
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
static const regdma_entries_config_t temperature_sensor_regs_entries[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) | ENTRY(2) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_TSENS_LINK(0x00), TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_MAP_BASE, TEMPERATURE_SENSOR_RETENTION_REGS_CNT, 0, 0, temperature_sensor_regs_map[0], temperature_sensor_regs_map[1], temperature_sensor_regs_map[2], temperature_sensor_regs_map[3]), \
|
||||||
|
.owner = ENTRY(0) | ENTRY(2)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
const temperature_sensor_reg_ctx_link_t temperature_sensor_regs_retention = {
|
||||||
|
@@ -66,18 +66,22 @@ const gdma_signal_conn_t gdma_periph_signals = {
|
|||||||
static const uint32_t ahb_dma_g0p0_regs_map0[4] = {0x4c801001, 0x604c0060, 0x0, 0x0};
|
static const uint32_t ahb_dma_g0p0_regs_map0[4] = {0x4c801001, 0x604c0060, 0x0, 0x0};
|
||||||
static const uint32_t ahb_dma_g0p0_regs_map1[4] = {0xc0000003, 0xfc900000, 0x0, 0x0};
|
static const uint32_t ahb_dma_g0p0_regs_map1[4] = {0xc0000003, 0xfc900000, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t ahb_dma_g0p0_regs_retention[] = {
|
static const regdma_entries_config_t ahb_dma_g0p0_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
AHB_DMA_G0P0_RETENTION_MAP_BASE_0, AHB_DMA_G0P0_RETENTION_MAP_BASE_0, \
|
AHB_DMA_G0P0_RETENTION_MAP_BASE_0, AHB_DMA_G0P0_RETENTION_MAP_BASE_0, \
|
||||||
AHB_DMA_G0P0_RETENTION_REGS_CNT_0, 0, 0, \
|
AHB_DMA_G0P0_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
ahb_dma_g0p0_regs_map0[0], ahb_dma_g0p0_regs_map0[1], \
|
ahb_dma_g0p0_regs_map0[0], ahb_dma_g0p0_regs_map0[1], \
|
||||||
ahb_dma_g0p0_regs_map0[2], ahb_dma_g0p0_regs_map0[3]), \
|
ahb_dma_g0p0_regs_map0[2], ahb_dma_g0p0_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
AHB_DMA_G0P0_RETENTION_MAP_BASE_1, AHB_DMA_G0P0_RETENTION_MAP_BASE_1, \
|
AHB_DMA_G0P0_RETENTION_MAP_BASE_1, AHB_DMA_G0P0_RETENTION_MAP_BASE_1, \
|
||||||
AHB_DMA_G0P0_RETENTION_REGS_CNT_1, 0, 0, \
|
AHB_DMA_G0P0_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
ahb_dma_g0p0_regs_map1[0], ahb_dma_g0p0_regs_map1[1], \
|
ahb_dma_g0p0_regs_map1[0], ahb_dma_g0p0_regs_map1[1], \
|
||||||
ahb_dma_g0p0_regs_map1[2], ahb_dma_g0p0_regs_map1[3]), \
|
ahb_dma_g0p0_regs_map1[2], ahb_dma_g0p0_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AHB_DMA Channel (Group0, Pair1) Registers Context
|
/* AHB_DMA Channel (Group0, Pair1) Registers Context
|
||||||
@@ -99,18 +103,22 @@ static const regdma_entries_config_t ahb_dma_g0p0_regs_retention[] = {
|
|||||||
static const uint32_t ahb_dma_g0p1_regs_map0[4] = {0x81001, 0, 0xC00604C0, 0x604};
|
static const uint32_t ahb_dma_g0p1_regs_map0[4] = {0x81001, 0, 0xC00604C0, 0x604};
|
||||||
static const uint32_t ahb_dma_g0p1_regs_map1[4] = {0xc0000003, 0x3f4800, 0x0, 0x0};
|
static const uint32_t ahb_dma_g0p1_regs_map1[4] = {0xc0000003, 0x3f4800, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t ahb_dma_g0p1_regs_retention[] = {
|
static const regdma_entries_config_t ahb_dma_g0p1_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
AHB_DMA_G0P1_RETENTION_MAP_BASE_0, AHB_DMA_G0P1_RETENTION_MAP_BASE_0, \
|
AHB_DMA_G0P1_RETENTION_MAP_BASE_0, AHB_DMA_G0P1_RETENTION_MAP_BASE_0, \
|
||||||
AHB_DMA_G0P1_RETENTION_REGS_CNT_0, 0, 0, \
|
AHB_DMA_G0P1_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
ahb_dma_g0p1_regs_map0[0], ahb_dma_g0p1_regs_map0[1], \
|
ahb_dma_g0p1_regs_map0[0], ahb_dma_g0p1_regs_map0[1], \
|
||||||
ahb_dma_g0p1_regs_map0[2], ahb_dma_g0p1_regs_map0[3]), \
|
ahb_dma_g0p1_regs_map0[2], ahb_dma_g0p1_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
AHB_DMA_G0P1_RETENTION_MAP_BASE_1, AHB_DMA_G0P1_RETENTION_MAP_BASE_1, \
|
AHB_DMA_G0P1_RETENTION_MAP_BASE_1, AHB_DMA_G0P1_RETENTION_MAP_BASE_1, \
|
||||||
AHB_DMA_G0P1_RETENTION_REGS_CNT_1, 0, 0, \
|
AHB_DMA_G0P1_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
ahb_dma_g0p1_regs_map1[0], ahb_dma_g0p1_regs_map1[1], \
|
ahb_dma_g0p1_regs_map1[0], ahb_dma_g0p1_regs_map1[1], \
|
||||||
ahb_dma_g0p1_regs_map1[2], ahb_dma_g0p1_regs_map1[3]), \
|
ahb_dma_g0p1_regs_map1[2], ahb_dma_g0p1_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AHB_DMA Channel (Group0, Pair2) Registers Context
|
/* AHB_DMA Channel (Group0, Pair2) Registers Context
|
||||||
@@ -132,18 +140,22 @@ static const regdma_entries_config_t ahb_dma_g0p1_regs_retention[] = {
|
|||||||
static const uint32_t ahb_dma_g0p2_regs_map0[4] = {0x9001, 0, 0, 0x4C0000};
|
static const uint32_t ahb_dma_g0p2_regs_map0[4] = {0x9001, 0, 0, 0x4C0000};
|
||||||
static const uint32_t ahb_dma_g0p2_regs_map1[4] = {0x3026003, 0x0, 0x30, 0xfe4c};
|
static const uint32_t ahb_dma_g0p2_regs_map1[4] = {0x3026003, 0x0, 0x30, 0xfe4c};
|
||||||
static const regdma_entries_config_t ahb_dma_g0p2_regs_retention[] = {
|
static const regdma_entries_config_t ahb_dma_g0p2_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
AHB_DMA_G0P2_RETENTION_MAP_BASE_0, AHB_DMA_G0P2_RETENTION_MAP_BASE_0, \
|
AHB_DMA_G0P2_RETENTION_MAP_BASE_0, AHB_DMA_G0P2_RETENTION_MAP_BASE_0, \
|
||||||
AHB_DMA_G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
AHB_DMA_G0P2_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
ahb_dma_g0p2_regs_map0[0], ahb_dma_g0p2_regs_map0[1], \
|
ahb_dma_g0p2_regs_map0[0], ahb_dma_g0p2_regs_map0[1], \
|
||||||
ahb_dma_g0p2_regs_map0[2], ahb_dma_g0p2_regs_map0[3]), \
|
ahb_dma_g0p2_regs_map0[2], ahb_dma_g0p2_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
AHB_DMA_G0P2_RETENTION_MAP_BASE_1, AHB_DMA_G0P2_RETENTION_MAP_BASE_1, \
|
AHB_DMA_G0P2_RETENTION_MAP_BASE_1, AHB_DMA_G0P2_RETENTION_MAP_BASE_1, \
|
||||||
AHB_DMA_G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
AHB_DMA_G0P2_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
ahb_dma_g0p2_regs_map1[0], ahb_dma_g0p2_regs_map1[1], \
|
ahb_dma_g0p2_regs_map1[0], ahb_dma_g0p2_regs_map1[1], \
|
||||||
ahb_dma_g0p2_regs_map1[2], ahb_dma_g0p2_regs_map1[3]), \
|
ahb_dma_g0p2_regs_map1[2], ahb_dma_g0p2_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AXI_DMA Channel (Group1, Pair0) Registers Context
|
/* AXI_DMA Channel (Group1, Pair0) Registers Context
|
||||||
@@ -164,18 +176,22 @@ static const regdma_entries_config_t ahb_dma_g0p2_regs_retention[] = {
|
|||||||
static const uint32_t axi_dma_g1p0_regs_map0[4] = {0xc0cd, 0x0, 0x30334000, 0x0};
|
static const uint32_t axi_dma_g1p0_regs_map0[4] = {0xc0cd, 0x0, 0x30334000, 0x0};
|
||||||
static const uint32_t axi_dma_g1p0_regs_map1[4] = {0x407f, 0x0, 0x0, 0x0};
|
static const uint32_t axi_dma_g1p0_regs_map1[4] = {0x407f, 0x0, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t axi_dma_g1p0_regs_retention[] = {
|
static const regdma_entries_config_t axi_dma_g1p0_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
AXI_DMA_G1P0_RETENTION_MAP_BASE_0, AXI_DMA_G1P0_RETENTION_MAP_BASE_0, \
|
AXI_DMA_G1P0_RETENTION_MAP_BASE_0, AXI_DMA_G1P0_RETENTION_MAP_BASE_0, \
|
||||||
AXI_DMA_G1P0_RETENTION_REGS_CNT_0, 0, 0, \
|
AXI_DMA_G1P0_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
axi_dma_g1p0_regs_map0[0], axi_dma_g1p0_regs_map0[1], \
|
axi_dma_g1p0_regs_map0[0], axi_dma_g1p0_regs_map0[1], \
|
||||||
axi_dma_g1p0_regs_map0[2], axi_dma_g1p0_regs_map0[3]), \
|
axi_dma_g1p0_regs_map0[2], axi_dma_g1p0_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
AXI_DMA_G1P0_RETENTION_MAP_BASE_1, AXI_DMA_G1P0_RETENTION_MAP_BASE_1, \
|
AXI_DMA_G1P0_RETENTION_MAP_BASE_1, AXI_DMA_G1P0_RETENTION_MAP_BASE_1, \
|
||||||
AXI_DMA_G1P0_RETENTION_REGS_CNT_1, 0, 0, \
|
AXI_DMA_G1P0_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
axi_dma_g1p0_regs_map1[0], axi_dma_g1p0_regs_map1[1], \
|
axi_dma_g1p0_regs_map1[0], axi_dma_g1p0_regs_map1[1], \
|
||||||
axi_dma_g1p0_regs_map1[2], axi_dma_g1p0_regs_map1[3]), \
|
axi_dma_g1p0_regs_map1[2], axi_dma_g1p0_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY},
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AXI_DMA Channel (Group1, Pair1) Registers Context
|
/* AXI_DMA Channel (Group1, Pair1) Registers Context
|
||||||
@@ -196,18 +212,22 @@ static const regdma_entries_config_t axi_dma_g1p0_regs_retention[] = {
|
|||||||
static const uint32_t axi_dma_g1p1_regs_map0[4] = {0xc0cd, 0x0, 0x30334000, 0x0};
|
static const uint32_t axi_dma_g1p1_regs_map0[4] = {0xc0cd, 0x0, 0x30334000, 0x0};
|
||||||
static const uint32_t axi_dma_g1p1_regs_map1[4] = {0x407f, 0x0, 0x0, 0x0};
|
static const uint32_t axi_dma_g1p1_regs_map1[4] = {0x407f, 0x0, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t axi_dma_g1p1_regs_retention[] = {
|
static const regdma_entries_config_t axi_dma_g1p1_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
AXI_DMA_G1P1_RETENTION_MAP_BASE_0, AXI_DMA_G1P1_RETENTION_MAP_BASE_0, \
|
AXI_DMA_G1P1_RETENTION_MAP_BASE_0, AXI_DMA_G1P1_RETENTION_MAP_BASE_0, \
|
||||||
AXI_DMA_G1P1_RETENTION_REGS_CNT_0, 0, 0, \
|
AXI_DMA_G1P1_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
axi_dma_g1p1_regs_map0[0], axi_dma_g1p1_regs_map0[1], \
|
axi_dma_g1p1_regs_map0[0], axi_dma_g1p1_regs_map0[1], \
|
||||||
axi_dma_g1p1_regs_map0[2], axi_dma_g1p1_regs_map0[3]), \
|
axi_dma_g1p1_regs_map0[2], axi_dma_g1p1_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
AXI_DMA_G1P1_RETENTION_MAP_BASE_1, AXI_DMA_G1P1_RETENTION_MAP_BASE_1, \
|
AXI_DMA_G1P1_RETENTION_MAP_BASE_1, AXI_DMA_G1P1_RETENTION_MAP_BASE_1, \
|
||||||
AXI_DMA_G1P1_RETENTION_REGS_CNT_1, 0, 0, \
|
AXI_DMA_G1P1_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
axi_dma_g1p1_regs_map1[0], axi_dma_g1p1_regs_map1[1], \
|
axi_dma_g1p1_regs_map1[0], axi_dma_g1p1_regs_map1[1], \
|
||||||
axi_dma_g1p1_regs_map1[2], axi_dma_g1p1_regs_map1[3]), \
|
axi_dma_g1p1_regs_map1[2], axi_dma_g1p1_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/* AXI_DMA Channel (Group1, Pair2) Registers Context
|
/* AXI_DMA Channel (Group1, Pair2) Registers Context
|
||||||
@@ -228,18 +248,22 @@ static const regdma_entries_config_t axi_dma_g1p1_regs_retention[] = {
|
|||||||
static const uint32_t axi_dma_g1p2_regs_map0[4] = {0xc0cd, 0x0, 0x30334000, 0x0};
|
static const uint32_t axi_dma_g1p2_regs_map0[4] = {0xc0cd, 0x0, 0x30334000, 0x0};
|
||||||
static const uint32_t axi_dma_g1p2_regs_map1[4] = {0x407f, 0x0, 0x0, 0x0};
|
static const uint32_t axi_dma_g1p2_regs_map1[4] = {0x407f, 0x0, 0x0, 0x0};
|
||||||
static const regdma_entries_config_t axi_dma_g1p2_regs_retention[] = {
|
static const regdma_entries_config_t axi_dma_g1p2_regs_retention[] = {
|
||||||
[0] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
[0] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x00), \
|
||||||
AXI_DMA_G1P2_RETENTION_MAP_BASE_0, AXI_DMA_G1P2_RETENTION_MAP_BASE_0, \
|
AXI_DMA_G1P2_RETENTION_MAP_BASE_0, AXI_DMA_G1P2_RETENTION_MAP_BASE_0, \
|
||||||
AXI_DMA_G1P2_RETENTION_REGS_CNT_0, 0, 0, \
|
AXI_DMA_G1P2_RETENTION_REGS_CNT_0, 0, 0, \
|
||||||
axi_dma_g1p2_regs_map0[0], axi_dma_g1p2_regs_map0[1], \
|
axi_dma_g1p2_regs_map0[0], axi_dma_g1p2_regs_map0[1], \
|
||||||
axi_dma_g1p2_regs_map0[2], axi_dma_g1p2_regs_map0[3]), \
|
axi_dma_g1p2_regs_map0[2], axi_dma_g1p2_regs_map0[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
[1] = { .config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
},
|
||||||
|
[1] = {
|
||||||
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_GDMA_LINK(0x01), \
|
||||||
AXI_DMA_G1P2_RETENTION_MAP_BASE_1, AXI_DMA_G1P2_RETENTION_MAP_BASE_1, \
|
AXI_DMA_G1P2_RETENTION_MAP_BASE_1, AXI_DMA_G1P2_RETENTION_MAP_BASE_1, \
|
||||||
AXI_DMA_G1P2_RETENTION_REGS_CNT_1, 0, 0, \
|
AXI_DMA_G1P2_RETENTION_REGS_CNT_1, 0, 0, \
|
||||||
axi_dma_g1p2_regs_map1[0], axi_dma_g1p2_regs_map1[1], \
|
axi_dma_g1p2_regs_map1[0], axi_dma_g1p2_regs_map1[1], \
|
||||||
axi_dma_g1p2_regs_map1[2], axi_dma_g1p2_regs_map1[3]), \
|
axi_dma_g1p2_regs_map1[2], axi_dma_g1p2_regs_map1[3]), \
|
||||||
.owner = GDMA_RETENTION_ENTRY },
|
.owner = GDMA_RETENTION_ENTRY
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
const gdma_chx_reg_ctx_link_t gdma_chx_regs_retention[SOC_GDMA_NUM_GROUPS_MAX][SOC_GDMA_PAIRS_PER_GROUP_MAX] = {
|
||||||
|
@@ -48,32 +48,52 @@ const i2c_signal_conn_t i2c_periph_signal[SOC_I2C_NUM] = {
|
|||||||
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
#define I2C0_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(0)
|
||||||
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
static const uint32_t i2c0_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
||||||
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
static const regdma_entries_config_t i2c0_regs_retention[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_MAP_BASE, I2C0_RETENTION_REGS_CNT, 0, 0, i2c0_regs_map[0], i2c0_regs_map[1], i2c0_regs_map[2], i2c0_regs_map[3]), \
|
||||||
[1] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
.owner = ENTRY(0)
|
||||||
.owner = ENTRY(0) }, \
|
}, \
|
||||||
[2] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
[1] = {
|
||||||
.owner = ENTRY(0) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(0), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
||||||
[3] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
.owner = ENTRY(0)
|
||||||
.owner = ENTRY(0) }, \
|
}, \
|
||||||
[4] = {.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
[2] = {
|
||||||
.owner = ENTRY(0) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(0), 0x0, I2C_FSM_RST_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0)
|
||||||
|
}, \
|
||||||
|
[3] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(0), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0)
|
||||||
|
}, \
|
||||||
|
[4] = {
|
||||||
|
.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(0), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
#define I2C1_RETENTION_REGS_CNT 18
|
#define I2C1_RETENTION_REGS_CNT 18
|
||||||
#define I2C1_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(1)
|
#define I2C1_RETENTION_MAP_BASE I2C_SCL_LOW_PERIOD_REG(1)
|
||||||
static const uint32_t i2c1_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
static const uint32_t i2c1_regs_map[4] = {0xc03f345b, 0x3, 0, 0};
|
||||||
static const regdma_entries_config_t i2c1_regs_retention[] = {
|
static const regdma_entries_config_t i2c1_regs_retention[] = {
|
||||||
[0] = {.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_REGS_CNT, 0, 0, i2c1_regs_map[0], i2c1_regs_map[1], i2c1_regs_map[2], i2c1_regs_map[3]), \
|
[0] = {
|
||||||
.owner = ENTRY(0) }, \
|
.config = REGDMA_LINK_ADDR_MAP_INIT(REGDMA_I2C_LINK(0x00), I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_MAP_BASE, I2C1_RETENTION_REGS_CNT, 0, 0, i2c1_regs_map[0], i2c1_regs_map[1], i2c1_regs_map[2], i2c1_regs_map[3]), \
|
||||||
[1] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(1), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
.owner = ENTRY(0)
|
||||||
.owner = ENTRY(0) }, \
|
}, \
|
||||||
[2] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(1), 0x0, I2C_FSM_RST_M, 1, 0), \
|
[1] = {
|
||||||
.owner = ENTRY(0) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x01), I2C_CTR_REG(1), I2C_FSM_RST, I2C_FSM_RST_M, 1, 0), \
|
||||||
[3] = {.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(1), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
.owner = ENTRY(0)
|
||||||
.owner = ENTRY(0) }, \
|
}, \
|
||||||
[4] = {.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(1), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
[2] = {
|
||||||
.owner = ENTRY(0) }, \
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x02), I2C_CTR_REG(1), 0x0, I2C_FSM_RST_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0)
|
||||||
|
}, \
|
||||||
|
[3] = {
|
||||||
|
.config = REGDMA_LINK_WRITE_INIT(REGDMA_I2C_LINK(0x03), I2C_CTR_REG(1), I2C_CONF_UPGATE, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0)
|
||||||
|
}, \
|
||||||
|
[4] = {
|
||||||
|
.config = REGDMA_LINK_WAIT_INIT(REGDMA_I2C_LINK(0x04), I2C_CTR_REG(1), 0x0, I2C_CONF_UPGATE_M, 1, 0), \
|
||||||
|
.owner = ENTRY(0)
|
||||||
|
}, \
|
||||||
};
|
};
|
||||||
|
|
||||||
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
const i2c_reg_ctx_link_t i2c_regs_retention[SOC_HP_I2C_NUM] = {
|
||||||
|
@@ -39,8 +39,6 @@
|
|||||||
/*Diagnostic Mode+UART0 download Mode*/
|
/*Diagnostic Mode+UART0 download Mode*/
|
||||||
#define IS_0111(v) (((v)&0x0f)==0x07)
|
#define IS_0111(v) (((v)&0x0f)==0x07)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
#define BOOT_MODE_GET() (GPIO_REG_READ(GPIO_STRAP_REG))
|
||||||
|
|
||||||
/*do not include download mode*/
|
/*do not include download mode*/
|
||||||
|
@@ -21,7 +21,6 @@ typedef enum clock_out_channel {
|
|||||||
CLKOUT_CHANNEL_MAX,
|
CLKOUT_CHANNEL_MAX,
|
||||||
} clock_out_channel_t;
|
} clock_out_channel_t;
|
||||||
|
|
||||||
|
|
||||||
#define CLKOUT_CHANNEL_TO_GPIO_SIG_ID(channel) ((channel == CLKOUT_CHANNEL_1) ? DBG_CH0_CLK_IDX : \
|
#define CLKOUT_CHANNEL_TO_GPIO_SIG_ID(channel) ((channel == CLKOUT_CHANNEL_1) ? DBG_CH0_CLK_IDX : \
|
||||||
(channel == CLKOUT_CHANNEL_2) ? DBG_CH1_CLK_IDX : SIG_GPIO_OUT_IDX)
|
(channel == CLKOUT_CHANNEL_2) ? DBG_CH1_CLK_IDX : SIG_GPIO_OUT_IDX)
|
||||||
|
|
||||||
|
@@ -54,7 +54,6 @@ extern "C" {
|
|||||||
#define SOC_ADDRESS_IN_DRAM_FLASH(vaddr) SOC_ADDRESS_IN_BUS(SOC_DRAM_FLASH, vaddr)
|
#define SOC_ADDRESS_IN_DRAM_FLASH(vaddr) SOC_ADDRESS_IN_BUS(SOC_DRAM_FLASH, vaddr)
|
||||||
#define SOC_ADDRESS_IN_DRAM_PSRAM(vaddr) SOC_ADDRESS_IN_BUS(SOC_DRAM_PSRAM, vaddr)
|
#define SOC_ADDRESS_IN_DRAM_PSRAM(vaddr) SOC_ADDRESS_IN_BUS(SOC_DRAM_PSRAM, vaddr)
|
||||||
|
|
||||||
|
|
||||||
#define SOC_MMU_FLASH_VALID BIT(12)
|
#define SOC_MMU_FLASH_VALID BIT(12)
|
||||||
#define SOC_MMU_FLASH_INVALID 0
|
#define SOC_MMU_FLASH_INVALID 0
|
||||||
#define SOC_MMU_PSRAM_VALID BIT(11)
|
#define SOC_MMU_PSRAM_VALID BIT(11)
|
||||||
@@ -126,7 +125,6 @@ extern "C" {
|
|||||||
#define SOC_MMU_PSRAM_LINEAR_ADDRESS_HIGH (SOC_MMU_LINEAR_ADDR_MASK + 1)
|
#define SOC_MMU_PSRAM_LINEAR_ADDRESS_HIGH (SOC_MMU_LINEAR_ADDR_MASK + 1)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
@@ -25,7 +25,6 @@ extern "C" {
|
|||||||
#define INTERRUPT_CORE0_CPU_INT_THRESH_REG (rv_utils_get_core_id() == 0 ? INTERRUPT_CURRENT_CORE_INT_THRESH_REG : INTERRUPT_OTHER_CORE_INT_THRESH_REG)
|
#define INTERRUPT_CORE0_CPU_INT_THRESH_REG (rv_utils_get_core_id() == 0 ? INTERRUPT_CURRENT_CORE_INT_THRESH_REG : INTERRUPT_OTHER_CORE_INT_THRESH_REG)
|
||||||
#define INTERRUPT_CORE1_CPU_INT_THRESH_REG (rv_utils_get_core_id() == 1 ? INTERRUPT_CURRENT_CORE_INT_THRESH_REG : INTERRUPT_OTHER_CORE_INT_THRESH_REG)
|
#define INTERRUPT_CORE1_CPU_INT_THRESH_REG (rv_utils_get_core_id() == 1 ? INTERRUPT_CURRENT_CORE_INT_THRESH_REG : INTERRUPT_OTHER_CORE_INT_THRESH_REG)
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@@ -4,7 +4,6 @@
|
|||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user