diff options
author | Alan Cox <alan@linux.intel.com> | 2010-11-11 10:27:29 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2010-11-30 18:56:23 -0500 |
commit | 5b275ce27077d6463ca28c9671dce7c2c1f622e2 (patch) | |
tree | 70e166c62f016b02068485b2e177e7b8e2c4ea6d /include/linux | |
parent | e8a7e48bb248a1196484d3f8afa53bded2b24e71 (diff) |
thermal: make ops constant
And while touching that function definition do something about the disaster
of formatting there.
Signed-off-by: Alan Cox <alan@linux.intel.com>
Acked-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/thermal.h | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/include/linux/thermal.h b/include/linux/thermal.h index 1de8b9eb841b..06626904daa0 100644 --- a/include/linux/thermal.h +++ b/include/linux/thermal.h | |||
@@ -77,7 +77,7 @@ struct thermal_cooling_device { | |||
77 | char type[THERMAL_NAME_LENGTH]; | 77 | char type[THERMAL_NAME_LENGTH]; |
78 | struct device device; | 78 | struct device device; |
79 | void *devdata; | 79 | void *devdata; |
80 | struct thermal_cooling_device_ops *ops; | 80 | const struct thermal_cooling_device_ops *ops; |
81 | struct list_head node; | 81 | struct list_head node; |
82 | }; | 82 | }; |
83 | 83 | ||
@@ -114,7 +114,7 @@ struct thermal_zone_device { | |||
114 | int last_temperature; | 114 | int last_temperature; |
115 | bool passive; | 115 | bool passive; |
116 | unsigned int forced_passive; | 116 | unsigned int forced_passive; |
117 | struct thermal_zone_device_ops *ops; | 117 | const struct thermal_zone_device_ops *ops; |
118 | struct list_head cooling_devices; | 118 | struct list_head cooling_devices; |
119 | struct idr idr; | 119 | struct idr idr; |
120 | struct mutex lock; /* protect cooling devices list */ | 120 | struct mutex lock; /* protect cooling devices list */ |
@@ -129,11 +129,8 @@ struct thermal_zone_device { | |||
129 | }; | 129 | }; |
130 | 130 | ||
131 | struct thermal_zone_device *thermal_zone_device_register(char *, int, void *, | 131 | struct thermal_zone_device *thermal_zone_device_register(char *, int, void *, |
132 | struct | 132 | const struct thermal_zone_device_ops *, int tc1, int tc2, |
133 | thermal_zone_device_ops | 133 | int passive_freq, int polling_freq); |
134 | *, int tc1, int tc2, | ||
135 | int passive_freq, | ||
136 | int polling_freq); | ||
137 | void thermal_zone_device_unregister(struct thermal_zone_device *); | 134 | void thermal_zone_device_unregister(struct thermal_zone_device *); |
138 | 135 | ||
139 | int thermal_zone_bind_cooling_device(struct thermal_zone_device *, int, | 136 | int thermal_zone_bind_cooling_device(struct thermal_zone_device *, int, |
@@ -142,9 +139,7 @@ int thermal_zone_unbind_cooling_device(struct thermal_zone_device *, int, | |||
142 | struct thermal_cooling_device *); | 139 | struct thermal_cooling_device *); |
143 | void thermal_zone_device_update(struct thermal_zone_device *); | 140 | void thermal_zone_device_update(struct thermal_zone_device *); |
144 | struct thermal_cooling_device *thermal_cooling_device_register(char *, void *, | 141 | struct thermal_cooling_device *thermal_cooling_device_register(char *, void *, |
145 | struct | 142 | const struct thermal_cooling_device_ops *); |
146 | thermal_cooling_device_ops | ||
147 | *); | ||
148 | void thermal_cooling_device_unregister(struct thermal_cooling_device *); | 143 | void thermal_cooling_device_unregister(struct thermal_cooling_device *); |
149 | 144 | ||
150 | #endif /* __THERMAL_H__ */ | 145 | #endif /* __THERMAL_H__ */ |