]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
rtc: stm32: Constify static 'pinctrl_desc'
authorKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Wed, 11 Jun 2025 06:13:49 +0000 (08:13 +0200)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 18 Jun 2025 11:26:37 +0000 (13:26 +0200)
The local static 'struct pinctrl_desc' is not modified, so can be made
const for code safety.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Acked-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/20250611-pinctrl-const-desc-v2-17-b11c1d650384@linaro.org
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/rtc/rtc-stm32.c

index ef8fb88aab48a0edad19ae5872421815aa04fe46..d4ebf3eb54aa9e91c8e9f8254f571c53794192fd 100644 (file)
@@ -393,7 +393,7 @@ static const struct pinmux_ops stm32_rtc_pinmux_ops = {
        .strict                 = true,
 };
 
-static struct pinctrl_desc stm32_rtc_pdesc = {
+static const struct pinctrl_desc stm32_rtc_pdesc = {
        .name = DRIVER_NAME,
        .pins = stm32_rtc_pinctrl_pins,
        .npins = ARRAY_SIZE(stm32_rtc_pinctrl_pins),