From bd19d4b9305cdf4046b763233cf18acf74baa441 Mon Sep 17 00:00:00 2001 From: Li Shuai Date: Tue, 7 Jan 2025 18:30:11 +0800 Subject: [PATCH] change(soc): fix idf_size error caused by ldgen to run success for ci pipeline --- components/esp_hw_support/linker.lf | 2 -- components/soc/esp32c2/temperature_sensor_periph.c | 3 ++- components/soc/esp32c3/temperature_sensor_periph.c | 3 ++- components/soc/esp32c5/temperature_sensor_periph.c | 3 ++- components/soc/esp32c6/temperature_sensor_periph.c | 3 ++- components/soc/esp32c61/temperature_sensor_periph.c | 3 ++- components/soc/esp32h2/temperature_sensor_periph.c | 3 ++- components/soc/esp32p4/temperature_sensor_periph.c | 2 +- components/soc/esp32s2/temperature_sensor_periph.c | 3 ++- components/soc/esp32s3/temperature_sensor_periph.c | 3 ++- components/soc/include/soc/temperature_sensor_periph.h | 2 +- 11 files changed, 18 insertions(+), 12 deletions(-) diff --git a/components/esp_hw_support/linker.lf b/components/esp_hw_support/linker.lf index 314559a665..0b7ffe7990 100644 --- a/components/esp_hw_support/linker.lf +++ b/components/esp_hw_support/linker.lf @@ -48,5 +48,3 @@ archive: libsoc.a entries: if PM_POWER_DOWN_PERIPHERAL_IN_LIGHT_SLEEP && ESP_SLEEP_FLASH_LEAKAGE_WORKAROUND: gpio_periph: GPIO_HOLD_MASK (noflash) - if PM_SLP_IRAM_OPT = y && SOC_TEMP_SENSOR_SUPPORTED = y: - temperature_sensor_periph:temperature_sensor_attributes (noflash) diff --git a/components/soc/esp32c2/temperature_sensor_periph.c b/components/soc/esp32c2/temperature_sensor_periph.c index e75c60b317..165403570f 100644 --- a/components/soc/esp32c2/temperature_sensor_periph.c +++ b/components/soc/esp32c2/temperature_sensor_periph.c @@ -5,8 +5,9 @@ */ #include "soc/temperature_sensor_periph.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32c3/temperature_sensor_periph.c b/components/soc/esp32c3/temperature_sensor_periph.c index e75c60b317..165403570f 100644 --- a/components/soc/esp32c3/temperature_sensor_periph.c +++ b/components/soc/esp32c3/temperature_sensor_periph.c @@ -5,8 +5,9 @@ */ #include "soc/temperature_sensor_periph.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32c5/temperature_sensor_periph.c b/components/soc/esp32c5/temperature_sensor_periph.c index 37e0e7e501..e44488fb1c 100644 --- a/components/soc/esp32c5/temperature_sensor_periph.c +++ b/components/soc/esp32c5/temperature_sensor_periph.c @@ -8,8 +8,9 @@ #include "soc/regdma.h" #include "soc/temperature_sensor_periph.h" #include "soc/apb_saradc_reg.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32c6/temperature_sensor_periph.c b/components/soc/esp32c6/temperature_sensor_periph.c index 291327d2bf..c0f47c1534 100644 --- a/components/soc/esp32c6/temperature_sensor_periph.c +++ b/components/soc/esp32c6/temperature_sensor_periph.c @@ -8,8 +8,9 @@ #include "soc/regdma.h" #include "soc/temperature_sensor_periph.h" #include "soc/apb_saradc_reg.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32c61/temperature_sensor_periph.c b/components/soc/esp32c61/temperature_sensor_periph.c index dc94673872..2b107dc91e 100644 --- a/components/soc/esp32c61/temperature_sensor_periph.c +++ b/components/soc/esp32c61/temperature_sensor_periph.c @@ -8,8 +8,9 @@ #include "soc/regdma.h" #include "soc/temperature_sensor_periph.h" #include "soc/apb_saradc_reg.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32h2/temperature_sensor_periph.c b/components/soc/esp32h2/temperature_sensor_periph.c index a4cc33aa6f..46f079333d 100644 --- a/components/soc/esp32h2/temperature_sensor_periph.c +++ b/components/soc/esp32h2/temperature_sensor_periph.c @@ -8,8 +8,9 @@ #include "soc/regdma.h" #include "soc/temperature_sensor_periph.h" #include "soc/apb_saradc_reg.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32p4/temperature_sensor_periph.c b/components/soc/esp32p4/temperature_sensor_periph.c index a681a41e3b..2b831ba45c 100644 --- a/components/soc/esp32p4/temperature_sensor_periph.c +++ b/components/soc/esp32p4/temperature_sensor_periph.c @@ -6,7 +6,7 @@ #include "soc/temperature_sensor_periph.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32s2/temperature_sensor_periph.c b/components/soc/esp32s2/temperature_sensor_periph.c index e75c60b317..165403570f 100644 --- a/components/soc/esp32s2/temperature_sensor_periph.c +++ b/components/soc/esp32s2/temperature_sensor_periph.c @@ -5,8 +5,9 @@ */ #include "soc/temperature_sensor_periph.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/esp32s3/temperature_sensor_periph.c b/components/soc/esp32s3/temperature_sensor_periph.c index e75c60b317..165403570f 100644 --- a/components/soc/esp32s3/temperature_sensor_periph.c +++ b/components/soc/esp32s3/temperature_sensor_periph.c @@ -5,8 +5,9 @@ */ #include "soc/temperature_sensor_periph.h" +#include "esp_attr.h" -const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { +DRAM_ATTR temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM] = { /*Offset reg_val min max error */ {-2, 5, 50, 125, 3}, {-1, 7, 20, 100, 2}, diff --git a/components/soc/include/soc/temperature_sensor_periph.h b/components/soc/include/soc/temperature_sensor_periph.h index d527392554..e82ff3f7be 100644 --- a/components/soc/include/soc/temperature_sensor_periph.h +++ b/components/soc/include/soc/temperature_sensor_periph.h @@ -25,7 +25,7 @@ typedef struct { int error_max; } temperature_sensor_attribute_t; -extern const temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM]; +extern temperature_sensor_attribute_t temperature_sensor_attributes[TEMPERATURE_SENSOR_ATTR_RANGE_NUM]; #if SOC_TEMPERATURE_SENSOR_SUPPORT_SLEEP_RETENTION typedef struct {