Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mcu/stm32xx: HAL Timer interrupt cleanup #3131

Merged
merged 1 commit into from
Feb 1, 2024

Conversation

kasjer
Copy link
Contributor

@kasjer kasjer commented Jan 25, 2024

Interrupts for used for timers differ from MCU to MCU. hal_timer.c had a lot of preprocessor conditions to select correct interrupt number name to be used for HAL timer. With each new MCU conditions were modified.

Now MCU specific mcu/stm32_hal.h defines interrupts name that deviate from common practice while stm32_common/stm23_hal.h provides defaults that are most frequently found.
Unified defines STM32_HAL_TIMER_TIMx_IRQ are used in hal_timer.c simplifying preprocess conditions.

@kasjer kasjer requested review from utzig and sjanc January 25, 2024 09:51
@kasjer kasjer force-pushed the kasjer/stm32-hal_timer-interrupts branch 4 times, most recently from 0179d35 to 3e93553 Compare January 25, 2024 11:34
Interrupts for used for timers differ from MCU to MCU.
hal_timer.c had a lot of preprocessor conditions to
select correct interrupt number name to be used for HAL timer.
With each new MCU conditions were modified.

Now MCU specific mcu/stm32_hal.h defines interrupts name that deviate
from common practice while stm32_common/stm23_hal.h provides defaults
that are most frequently found.
Unified defines STM32_HAL_TIMER_TIMx_IRQ are used in hal_timer.c simplifying
preprocess conditions.

Signed-off-by: Jerzy Kasenberg <[email protected]>
@kasjer kasjer force-pushed the kasjer/stm32-hal_timer-interrupts branch from 3e93553 to f0c6594 Compare January 25, 2024 12:15
@kasjer kasjer merged commit 0ab1958 into apache:master Feb 1, 2024
16 checks passed
@kasjer kasjer deleted the kasjer/stm32-hal_timer-interrupts branch February 1, 2024 06:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants