From 64a7efb04af5ab6b975361c3b5946d185d94385c Mon Sep 17 00:00:00 2001 From: Andrey Gusakov Date: Sat, 28 Oct 2023 00:56:00 +0300 Subject: [PATCH] testhal: AT32: ADC: fixes for backport --- testhal/AT32/AT32F4xx/ADC/chconf.h | 87 +---------------------------- testhal/AT32/AT32F4xx/ADC/mcuconf.h | 1 + 2 files changed, 3 insertions(+), 85 deletions(-) diff --git a/testhal/AT32/AT32F4xx/ADC/chconf.h b/testhal/AT32/AT32F4xx/ADC/chconf.h index e0261697f..2a768bbd7 100644 --- a/testhal/AT32/AT32F4xx/ADC/chconf.h +++ b/testhal/AT32/AT32F4xx/ADC/chconf.h @@ -34,27 +34,6 @@ #define ON_LOCK_HOOK {} #define ON_UNLOCK_HOOK {} -/*===========================================================================*/ -/** - * @name System settings - * @{ - */ -/*===========================================================================*/ - -/** - * @brief Handling of instances. - * @note If enabled then threads assigned to various instances can - * interact each other using the same synchronization objects. - * If disabled then each OS instance is a separate world, no - * direct interactions are handled by the OS. - */ -#if !defined(CH_CFG_SMP_MODE) -#define CH_CFG_SMP_MODE FALSE -#endif - -/** @} */ - - /*===========================================================================*/ /** * @name System timers settings @@ -143,18 +122,6 @@ #define CH_CFG_NO_IDLE_THREAD FALSE #endif -/** - * @brief Kernel hardening level. - * @details This option is the level of functional-safety checks enabled - * in the kerkel. The meaning is: - * - 0: No checks, maximum performance. - * - 1: Reasonable checks. - * - 2: All checks. - * . - */ -#if !defined(CH_CFG_HARDENING_LEVEL) -#define CH_CFG_HARDENING_LEVEL 0 -#endif /** @} */ /*===========================================================================*/ @@ -196,16 +163,6 @@ #define CH_CFG_USE_TM TRUE #endif -/** - * @brief Time Stamps APIs. - * @details If enabled then the time stamps APIs are included in the kernel. - * - * @note The default is @p TRUE. - */ -#if !defined(CH_CFG_USE_TIMESTAMP) -#define CH_CFG_USE_TIMESTAMP TRUE -#endif - /** * @brief Threads registry APIs. * @details If enabled then the registry APIs are included in the kernel. @@ -376,16 +333,6 @@ #define CH_CFG_USE_MAILBOXES TRUE #endif -/** - * @brief Memory checks APIs. - * @details If enabled then the memory checks APIs are included in the kernel. - * - * @note The default is @p TRUE. - */ -#if !defined(CH_CFG_USE_MEMCHECKS) -#define CH_CFG_USE_MEMCHECKS TRUE -#endif - /** * @brief Core Memory Manager APIs. * @details If enabled then the core memory manager APIs are included @@ -687,7 +634,7 @@ * @details User fields added to the end of the @p ch_system_t structure. */ #define CH_CFG_SYSTEM_EXTRA_FIELDS \ - /* Add system custom fields here.*/ + /* Add threads custom fields here.*/ /** * @brief System initialization hook. @@ -695,24 +642,8 @@ * just before interrupts are enabled globally. */ #define CH_CFG_SYSTEM_INIT_HOOK() { \ - /* Add system initialization code here.*/ \ + /* Add threads initialization code here.*/ \ } -/** - * @brief OS instance structure extension. - * @details User fields added to the end of the @p os_instance_t structure. - */ -#define CH_CFG_OS_INSTANCE_EXTRA_FIELDS \ - /* Add OS instance custom fields here.*/ - -/** - * @brief OS instance initialization hook. - * - * @param[in] oip pointer to the @p os_instance_t structure - */ -#define CH_CFG_OS_INSTANCE_INIT_HOOK(oip) { \ - /* Add OS instance initialization code here.*/ \ -} - /** * @brief Threads descriptor structure extension. @@ -727,8 +658,6 @@ * * @note It is invoked from within @p _thread_init() and implicitly from all * the threads creation APIs. - * - * @param[in] tp pointer to the @p thread_t structure */ #define CH_CFG_THREAD_INIT_HOOK(tp) { \ /* Add threads initialization code here.*/ \ @@ -737,8 +666,6 @@ /** * @brief Threads finalization hook. * @details User finalization code added to the @p chThdExit() API. - * - * @param[in] tp pointer to the @p thread_t structure */ #define CH_CFG_THREAD_EXIT_HOOK(tp) { \ /* Add threads finalization code here.*/ \ @@ -747,9 +674,6 @@ /** * @brief Context switch hook. * @details This hook is invoked just before switching between threads. - * - * @param[in] ntp thread being switched in - * @param[in] otp thread being switched out */ #define CH_CFG_CONTEXT_SWITCH_HOOK(ntp, otp) { \ /* Context switch code here.*/ \ @@ -824,13 +748,6 @@ /* Trace code here.*/ \ } -/** - * @brief Runtime Faults Collection Unit hook. - * @details This hook is invoked each time new faults are collected and stored. - */ -#define CH_CFG_RUNTIME_FAULTS_HOOK(mask) { \ - /* Faults handling code here.*/ \ -} /** @} */ /*===========================================================================*/ diff --git a/testhal/AT32/AT32F4xx/ADC/mcuconf.h b/testhal/AT32/AT32F4xx/ADC/mcuconf.h index 867ef2902..ffc4a131c 100644 --- a/testhal/AT32/AT32F4xx/ADC/mcuconf.h +++ b/testhal/AT32/AT32F4xx/ADC/mcuconf.h @@ -276,6 +276,7 @@ /* * PWM driver system settings. */ +#define STM32_PWM_USE_ADVANCED FALSE #define STM32_PWM_USE_TIM1 FALSE #define STM32_PWM_USE_TIM2 FALSE #define STM32_PWM_USE_TIM3 FALSE