driver: adc: use SOC_ADC_PERIPH_NUM for array size

ADC_UNIT_MAX is no longer equal to the number of ADC units.
This makes the static s_adc_cali_param arrays larger than necessary.
This commit is contained in:
Ivan Grokhotkov
2021-11-04 13:03:11 +01:00
parent e697e7ff0f
commit dbd3aa5bfc
3 changed files with 3 additions and 3 deletions

View File

@@ -666,7 +666,7 @@ esp_err_t adc_digi_monitor_enable(adc_digi_monitor_idx_t idx, bool enable)
RTC controller setting
---------------------------------------------------------------*/
static uint16_t s_adc_cali_param[ADC_UNIT_MAX][ADC_ATTEN_MAX] = {};
static uint16_t s_adc_cali_param[SOC_ADC_PERIPH_NUM][ADC_ATTEN_MAX] = {};
//NOTE: according to calibration version, different types of lock may be taken during the process:
// 1. Semaphore when reading efuse