This is an automated email from the ASF dual-hosted git repository.

xiaoxiang781216 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit c980dc3dc0b6c4a48ea3d25778b2fd8a1754e988
Author: raiden00pl <[email protected]>
AuthorDate: Mon Nov 9 08:32:28 2026 +0100

    arch/arm/stm32: Define the GPIO ports I to K only where they exist.
    
    On STM32N6 the port numbers 8 to 10 belong to N to P, so GPIO_PORTI to
    GPIO_PORTK silently addressed those ports.
    
    Assisted-by: Claude:claude-fable-5-1
    Signed-off-by: raiden00pl <[email protected]>
---
 arch/arm/src/common/stm32/stm32_gpio_m33m55_v1.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/arm/src/common/stm32/stm32_gpio_m33m55_v1.h 
b/arch/arm/src/common/stm32/stm32_gpio_m33m55_v1.h
index 03f616cfba6..1163cc8e013 100644
--- a/arch/arm/src/common/stm32/stm32_gpio_m33m55_v1.h
+++ b/arch/arm/src/common/stm32/stm32_gpio_m33m55_v1.h
@@ -191,9 +191,15 @@
 #  define GPIO_PORTF                  (5 << GPIO_PORT_SHIFT)     /*   GPIOF */
 #  define GPIO_PORTG                  (6 << GPIO_PORT_SHIFT)     /*   GPIOG */
 #  define GPIO_PORTH                  (7 << GPIO_PORT_SHIFT)     /*   GPIOH */
+#ifdef STM32_GPIOI_BASE
 #  define GPIO_PORTI                  (8 << GPIO_PORT_SHIFT)     /*   GPIOI */
+#endif
+#ifdef STM32_GPIOJ_BASE
 #  define GPIO_PORTJ                  (9 << GPIO_PORT_SHIFT)     /*   GPIOJ */
+#endif
+#ifdef STM32_GPIOK_BASE
 #  define GPIO_PORTK                  (10 << GPIO_PORT_SHIFT)    /*   GPIOK */
+#endif
 
 /* STM32N6 names the ports above H as N, O, P and Q */
 

Reply via email to