diff options
| author | Michal Marek <mmarek@suse.cz> | 2010-10-27 18:15:57 -0400 |
|---|---|---|
| committer | Michal Marek <mmarek@suse.cz> | 2010-10-27 18:15:57 -0400 |
| commit | b74b953b998bcc2db91b694446f3a2619ec32de6 (patch) | |
| tree | 6ce24caabd730f6ae9287ed0676ec32e6ff31e9d /include/linux/cpufreq.h | |
| parent | abb438526201c6a79949ad45375c051b6681c253 (diff) | |
| parent | f6f94e2ab1b33f0082ac22d71f66385a60d8157f (diff) | |
Merge commit 'v2.6.36' into kbuild/misc
Update to be able to fix a recent change to scripts/basic/docproc.c
(commit eda603f).
Diffstat (limited to 'include/linux/cpufreq.h')
| -rw-r--r-- | include/linux/cpufreq.h | 35 |
1 files changed, 30 insertions, 5 deletions
diff --git a/include/linux/cpufreq.h b/include/linux/cpufreq.h index 4de02b10007f..c3e9de8321c6 100644 --- a/include/linux/cpufreq.h +++ b/include/linux/cpufreq.h | |||
| @@ -196,11 +196,6 @@ extern int __cpufreq_driver_getavg(struct cpufreq_policy *policy, | |||
| 196 | int cpufreq_register_governor(struct cpufreq_governor *governor); | 196 | int cpufreq_register_governor(struct cpufreq_governor *governor); |
| 197 | void cpufreq_unregister_governor(struct cpufreq_governor *governor); | 197 | void cpufreq_unregister_governor(struct cpufreq_governor *governor); |
| 198 | 198 | ||
| 199 | int lock_policy_rwsem_read(int cpu); | ||
| 200 | int lock_policy_rwsem_write(int cpu); | ||
| 201 | void unlock_policy_rwsem_read(int cpu); | ||
| 202 | void unlock_policy_rwsem_write(int cpu); | ||
| 203 | |||
| 204 | 199 | ||
| 205 | /********************************************************************* | 200 | /********************************************************************* |
| 206 | * CPUFREQ DRIVER INTERFACE * | 201 | * CPUFREQ DRIVER INTERFACE * |
| @@ -278,6 +273,27 @@ struct freq_attr { | |||
| 278 | ssize_t (*store)(struct cpufreq_policy *, const char *, size_t count); | 273 | ssize_t (*store)(struct cpufreq_policy *, const char *, size_t count); |
| 279 | }; | 274 | }; |
| 280 | 275 | ||
| 276 | #define cpufreq_freq_attr_ro(_name) \ | ||
| 277 | static struct freq_attr _name = \ | ||
| 278 | __ATTR(_name, 0444, show_##_name, NULL) | ||
| 279 | |||
| 280 | #define cpufreq_freq_attr_ro_perm(_name, _perm) \ | ||
| 281 | static struct freq_attr _name = \ | ||
| 282 | __ATTR(_name, _perm, show_##_name, NULL) | ||
| 283 | |||
| 284 | #define cpufreq_freq_attr_ro_old(_name) \ | ||
| 285 | static struct freq_attr _name##_old = \ | ||
| 286 | __ATTR(_name, 0444, show_##_name##_old, NULL) | ||
| 287 | |||
| 288 | #define cpufreq_freq_attr_rw(_name) \ | ||
| 289 | static struct freq_attr _name = \ | ||
| 290 | __ATTR(_name, 0644, show_##_name, store_##_name) | ||
| 291 | |||
| 292 | #define cpufreq_freq_attr_rw_old(_name) \ | ||
| 293 | static struct freq_attr _name##_old = \ | ||
| 294 | __ATTR(_name, 0644, show_##_name##_old, store_##_name##_old) | ||
| 295 | |||
| 296 | |||
| 281 | struct global_attr { | 297 | struct global_attr { |
| 282 | struct attribute attr; | 298 | struct attribute attr; |
| 283 | ssize_t (*show)(struct kobject *kobj, | 299 | ssize_t (*show)(struct kobject *kobj, |
| @@ -286,6 +302,15 @@ struct global_attr { | |||
| 286 | const char *c, size_t count); | 302 | const char *c, size_t count); |
| 287 | }; | 303 | }; |
| 288 | 304 | ||
| 305 | #define define_one_global_ro(_name) \ | ||
| 306 | static struct global_attr _name = \ | ||
| 307 | __ATTR(_name, 0444, show_##_name, NULL) | ||
| 308 | |||
| 309 | #define define_one_global_rw(_name) \ | ||
| 310 | static struct global_attr _name = \ | ||
| 311 | __ATTR(_name, 0644, show_##_name, store_##_name) | ||
| 312 | |||
| 313 | |||
| 289 | /********************************************************************* | 314 | /********************************************************************* |
| 290 | * CPUFREQ 2.6. INTERFACE * | 315 | * CPUFREQ 2.6. INTERFACE * |
| 291 | *********************************************************************/ | 316 | *********************************************************************/ |
