summaryrefslogtreecommitdiffstats
path: root/drivers/rtc/rtc-ds3232.c
diff options
context:
space:
mode:
authorKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>2023-05-11 19:56:07 +0200
committerAlexandre Belloni <alexandre.belloni@bootlin.com>2023-06-06 23:24:54 +0200
commitd00caa55cecd3e833c21c9372fc558cb9f40a07f (patch)
treef9a30770e39949b033b76a8a2e9c46f044b7f429 /drivers/rtc/rtc-ds3232.c
parentrtc: ab-eoz9: constify pointers to hwmon_channel_info (diff)
downloadlinux-d00caa55cecd3e833c21c9372fc558cb9f40a07f.tar.xz
linux-d00caa55cecd3e833c21c9372fc558cb9f40a07f.zip
rtc: ds3232: constify pointers to hwmon_channel_info
Statically allocated array of pointers to hwmon_channel_info can be made const for safety. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20230511175609.282191-2-krzysztof.kozlowski@linaro.org Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to '')
-rw-r--r--drivers/rtc/rtc-ds3232.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-ds3232.c b/drivers/rtc/rtc-ds3232.c
index dd31a60c1fc6..ce46016c9fd8 100644
--- a/drivers/rtc/rtc-ds3232.c
+++ b/drivers/rtc/rtc-ds3232.c
@@ -359,7 +359,7 @@ static const struct hwmon_channel_info ds3232_hwmon_temp = {
.config = ds3232_hwmon_temp_config,
};
-static const struct hwmon_channel_info *ds3232_hwmon_info[] = {
+static const struct hwmon_channel_info * const ds3232_hwmon_info[] = {
&ds3232_hwmon_chip,
&ds3232_hwmon_temp,
NULL