From 8baae3ee09aedd5ab4d6e9cdb787e731bc698116 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Mon, 18 Aug 2025 03:03:16 +0200 Subject: [PATCH] bsps/arm: Fix discarded qualifiers warning Move volatile qualifier to the register block structure. Close #5320. --- bsps/arm/include/bsp/imx-gpio.h | 2 +- bsps/arm/shared/pins/imx-gpio.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bsps/arm/include/bsp/imx-gpio.h b/bsps/arm/include/bsp/imx-gpio.h index 99d339408f..abbd330d14 100644 --- a/bsps/arm/include/bsp/imx-gpio.h +++ b/bsps/arm/include/bsp/imx-gpio.h @@ -58,7 +58,7 @@ enum imx_gpio_mode { */ struct imx_gpio_pin { /** Management structure for the GPIO. Get with @ref imx_gpio_get_by_index. */ - volatile struct imx_gpio* gpio; + struct imx_gpio* gpio; /** * Select the pins you want to handle with this mask. The mask is not * influenced by the @a shift field. diff --git a/bsps/arm/shared/pins/imx-gpio.c b/bsps/arm/shared/pins/imx-gpio.c index aec65edfa8..07f053c1e6 100644 --- a/bsps/arm/shared/pins/imx-gpio.c +++ b/bsps/arm/shared/pins/imx-gpio.c @@ -68,7 +68,7 @@ struct imx_gpio_regs { struct imx_gpio { char name[sizeof(IMX_GPIO_ALIAS_NAME)]; - struct imx_gpio_regs *regs; + volatile struct imx_gpio_regs *regs; rtems_interrupt_lock lock; };