OSDN Git Service
(root)
/
tomoyo
/
tomoyo-test1.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
832dc51
)
hwmon: as370: constify pointers to hwmon_channel_info
author
Krzysztof Kozlowski
<krzysztof.kozlowski@linaro.org>
Thu, 6 Apr 2023 20:30:04 +0000
(22:30 +0200)
committer
Guenter Roeck
<linux@roeck-us.net>
Wed, 19 Apr 2023 14:08:34 +0000
(07:08 -0700)
Statically allocated array of pointed to hwmon_channel_info can be made
const for safety.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/as370-hwmon.c
patch
|
blob
|
history
diff --git
a/drivers/hwmon/as370-hwmon.c
b/drivers/hwmon/as370-hwmon.c
index
63b5b2d
..
fffbf38
100644
(file)
--- a/
drivers/hwmon/as370-hwmon.c
+++ b/
drivers/hwmon/as370-hwmon.c
@@
-76,7
+76,7
@@
as370_hwmon_is_visible(const void *data, enum hwmon_sensor_types type,
}
}
-static const struct hwmon_channel_info *as370_hwmon_info[] = {
+static const struct hwmon_channel_info *
const
as370_hwmon_info[] = {
HWMON_CHANNEL_INFO(temp, HWMON_T_INPUT),
NULL
};