mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 1/4] platform/x86: gigabyte: constify pointers to hwmon_channel_info
@ 2023-04-07 15:03 Krzysztof Kozlowski
  2023-04-07 15:03 ` [PATCH 2/4] platform/x86: hp: " Krzysztof Kozlowski
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Krzysztof Kozlowski @ 2023-04-07 15:03 UTC (permalink / raw)
  To: Thomas Weißschuh, Hans de Goede, Mark Gross, Jeremy Soller,
	System76 Product Development, Azael Avalos, platform-driver-x86,
	linux-kernel
  Cc: Krzysztof Kozlowski, Jean Delvare, Guenter Roeck, linux-hwmon

Statically allocated array of pointed to hwmon_channel_info can be made
const for safety.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

---

This depends on hwmon core patch:
https://lore.kernel.org/all/20230406203103.3011503-2-krzysztof.kozlowski@linaro.org/

Therefore I propose this should also go via hwmon tree.

Cc: Jean Delvare <jdelvare@suse.com>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: linux-hwmon@vger.kernel.org
---
 drivers/platform/x86/gigabyte-wmi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/platform/x86/gigabyte-wmi.c b/drivers/platform/x86/gigabyte-wmi.c
index 5e5b17c50eb6..7cc969fb1beb 100644
--- a/drivers/platform/x86/gigabyte-wmi.c
+++ b/drivers/platform/x86/gigabyte-wmi.c
@@ -99,7 +99,7 @@ static umode_t gigabyte_wmi_hwmon_is_visible(const void *data, enum hwmon_sensor
 	return usable_sensors_mask & BIT(channel) ? 0444  : 0;
 }
 
-static const struct hwmon_channel_info *gigabyte_wmi_hwmon_info[] = {
+static const struct hwmon_channel_info * const gigabyte_wmi_hwmon_info[] = {
 	HWMON_CHANNEL_INFO(temp,
 			   HWMON_T_INPUT,
 			   HWMON_T_INPUT,
-- 
2.34.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-04-11  8:32 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-07 15:03 [PATCH 1/4] platform/x86: gigabyte: constify pointers to hwmon_channel_info Krzysztof Kozlowski
2023-04-07 15:03 ` [PATCH 2/4] platform/x86: hp: " Krzysztof Kozlowski
2023-04-07 15:03 ` [PATCH 3/4] platform/x86: system76: " Krzysztof Kozlowski
2023-04-07 15:03 ` [PATCH 4/4] platform/x86: toshiba: " Krzysztof Kozlowski
2023-04-11  8:31 ` [PATCH 1/4] platform/x86: gigabyte: " Hans de Goede

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®