From 3168ad10e79646e9d3422c36175aad5c6d60fff8 Mon Sep 17 00:00:00 2001 From: Jeroen Domburg Date: Sun, 15 Jan 2017 11:11:58 +0800 Subject: [PATCH] Core timer 2 is unusable for FreeRTOS ticks because it triggers a high-level interrupt. This commit deletes the option to select it. --- components/esp32/intr_alloc.c | 8 +------- components/freertos/Kconfig | 5 ----- components/freertos/include/freertos/FreeRTOSConfig.h | 4 ---- 3 files changed, 1 insertion(+), 16 deletions(-) diff --git a/components/esp32/intr_alloc.c b/components/esp32/intr_alloc.c index 1cb2fba5d9..bfd6c51206 100644 --- a/components/esp32/intr_alloc.c +++ b/components/esp32/intr_alloc.c @@ -89,12 +89,6 @@ typedef struct { #define INT15RES INTDESC_SPECIAL #endif -#if CONFIG_FREERTOS_CORETIMER_2 -#define INT16RES INTDESC_RESVD -#else -#define INT16RES INTDESC_SPECIAL -#endif - //This is basically a software-readable version of the interrupt usage table in include/soc/soc.h const static int_desc_t int_desc[32]={ { 1, INTTP_LEVEL, {INTDESC_RESVD, INTDESC_RESVD } }, //0 @@ -113,7 +107,7 @@ const static int_desc_t int_desc[32]={ { 1, INTTP_LEVEL, {INTDESC_NORMAL, INTDESC_NORMAL} }, //13 { 7, INTTP_LEVEL, {INTDESC_RESVD, INTDESC_RESVD } }, //14, NMI { 3, INTTP_NA, {INT15RES, INT15RES } }, //15 - { 5, INTTP_NA, {INT16RES, INT16RES } }, //16 + { 5, INTTP_NA, {INTDESC_SPECIAL,INTDESC_SPECIAL} }, //16 { 1, INTTP_LEVEL, {INTDESC_NORMAL, INTDESC_NORMAL} }, //17 { 1, INTTP_LEVEL, {INTDESC_NORMAL, INTDESC_NORMAL} }, //18 { 2, INTTP_LEVEL, {INTDESC_NORMAL, INTDESC_NORMAL} }, //19 diff --git a/components/freertos/Kconfig b/components/freertos/Kconfig index 15178539b4..ee2b289ef8 100644 --- a/components/freertos/Kconfig +++ b/components/freertos/Kconfig @@ -30,11 +30,6 @@ config FREERTOS_CORETIMER_1 help Select this to use timer 1 -config FREERTOS_CORETIMER_2 - bool "Timer 2 (int 16, level 5)" - help - Select this to use timer 2 - endchoice config FREERTOS_HZ diff --git a/components/freertos/include/freertos/FreeRTOSConfig.h b/components/freertos/include/freertos/FreeRTOSConfig.h index b2fc077bc3..9deb9f4b5e 100644 --- a/components/freertos/include/freertos/FreeRTOSConfig.h +++ b/components/freertos/include/freertos/FreeRTOSConfig.h @@ -90,10 +90,6 @@ #define XT_TIMER_INDEX 0 #elif CONFIG_FREERTOS_CORETIMER_1 #define XT_TIMER_INDEX 1 -#elif CONFIG_FREERTOS_CORETIMER_2 -#define XT_TIMER_INDEX 2 -#elif CONFIG_FREERTOS_CORETIMER_3 -#define XT_TIMER_INDEX 3 #endif #define configNUM_THREAD_LOCAL_STORAGE_POINTERS CONFIG_FREERTOS_THREAD_LOCAL_STORAGE_POINTERS -- 2.40.0