All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] thermal: devfreq_cooling: add const to struct thermal_cooling_device_ops
@ 2018-04-09  2:52 srplinux2008
  2018-04-09  5:13   ` kbuild test robot
  0 siblings, 1 reply; 3+ messages in thread
From: srplinux2008 @ 2018-04-09  2:52 UTC (permalink / raw)
  To: orjan.eide, rui.zhang, edubezval; +Cc: linux-kernel, linux-pm, srplinux2008

From: srp linux <srplinux2008@gmail.com>

Add the typecast constant to structure thermal_cooling_device_ops. This
is the last argument to the function thermal_of_cooling_device_register
and this argument is of type const. So, declare this structure
thermal_cooling_device_ops as constant.

Signed-off-by: srp linux <srplinux2008@gmail.com>
---
 drivers/thermal/devfreq_cooling.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/thermal/devfreq_cooling.c b/drivers/thermal/devfreq_cooling.c
index ef59256..80efc4e 100644
--- a/drivers/thermal/devfreq_cooling.c
+++ b/drivers/thermal/devfreq_cooling.c
@@ -392,7 +392,7 @@ static int devfreq_cooling_power2state(struct thermal_cooling_device *cdev,
 	return 0;
 }
 
-static struct thermal_cooling_device_ops devfreq_cooling_ops = {
+static const struct thermal_cooling_device_ops devfreq_cooling_ops = {
 	.get_max_state = devfreq_cooling_get_max_state,
 	.get_cur_state = devfreq_cooling_get_cur_state,
 	.set_cur_state = devfreq_cooling_set_cur_state,
-- 
2.7.4

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

end of thread, other threads:[~2018-04-09  5:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-09  2:52 [PATCH] thermal: devfreq_cooling: add const to struct thermal_cooling_device_ops srplinux2008
2018-04-09  5:13 ` kbuild test robot
2018-04-09  5:13   ` kbuild test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.