aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/cpuidle/sysfs.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-03-08 13:17:20 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2010-03-08 13:17:20 -0500
commite10154189f001b6428a83f58b03a27954f0f8022 (patch)
tree30b4ac5760c5d310e9cc2cbf8fc4b9c6f9d0e369 /drivers/cpuidle/sysfs.c
parentd4bab1b091be4a91a7363118c9ede3cc9a7fefd4 (diff)
parent410c17651998944630a95fbb286a50362de2dbb0 (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6: (62 commits) msi-laptop: depends on RFKILL msi-laptop: Detect 3G device exists by standard ec command msi-laptop: Add resume method for set the SCM load again msi-laptop: Support some MSI 3G netbook that is need load SCM msi-laptop: Add threeg sysfs file for support query 3G state by standard 66/62 ec command msi-laptop: Support standard ec 66/62 command on MSI notebook and nebook Driver core: create lock/unlock functions for struct device sysfs: fix for thinko with sysfs_bin_attr_init() sysfs: Kill unused sysfs_sb variable. sysfs: Pass super_block to sysfs_get_inode driver core: Use sysfs_rename_link in device_rename sysfs: Implement sysfs_rename_link sysfs: Pack sysfs_dirent more tightly. sysfs: Serialize updates to the vfs inode sysfs: windfarm: init sysfs attributes sysfs: Use sysfs_attr_init and sysfs_bin_attr_init on module dynamic attributes sysfs: Document sysfs_attr_init and sysfs_bin_attr_init sysfs: Use sysfs_attr_init and sysfs_bin_attr_init on dynamic attributes sysfs: Use one lockdep class per sysfs attribute. sysfs: Only take active references on attributes. ...
Diffstat (limited to 'drivers/cpuidle/sysfs.c')
-rw-r--r--drivers/cpuidle/sysfs.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/cpuidle/sysfs.c b/drivers/cpuidle/sysfs.c
index 97b003839fb6..8719b36e1a4d 100644
--- a/drivers/cpuidle/sysfs.c
+++ b/drivers/cpuidle/sysfs.c
@@ -22,6 +22,7 @@ static int __init cpuidle_sysfs_setup(char *unused)
22__setup("cpuidle_sysfs_switch", cpuidle_sysfs_setup); 22__setup("cpuidle_sysfs_switch", cpuidle_sysfs_setup);
23 23
24static ssize_t show_available_governors(struct sysdev_class *class, 24static ssize_t show_available_governors(struct sysdev_class *class,
25 struct sysdev_class_attribute *attr,
25 char *buf) 26 char *buf)
26{ 27{
27 ssize_t i = 0; 28 ssize_t i = 0;
@@ -41,6 +42,7 @@ out:
41} 42}
42 43
43static ssize_t show_current_driver(struct sysdev_class *class, 44static ssize_t show_current_driver(struct sysdev_class *class,
45 struct sysdev_class_attribute *attr,
44 char *buf) 46 char *buf)
45{ 47{
46 ssize_t ret; 48 ssize_t ret;
@@ -56,6 +58,7 @@ static ssize_t show_current_driver(struct sysdev_class *class,
56} 58}
57 59
58static ssize_t show_current_governor(struct sysdev_class *class, 60static ssize_t show_current_governor(struct sysdev_class *class,
61 struct sysdev_class_attribute *attr,
59 char *buf) 62 char *buf)
60{ 63{
61 ssize_t ret; 64 ssize_t ret;
@@ -71,6 +74,7 @@ static ssize_t show_current_governor(struct sysdev_class *class,
71} 74}
72 75
73static ssize_t store_current_governor(struct sysdev_class *class, 76static ssize_t store_current_governor(struct sysdev_class *class,
77 struct sysdev_class_attribute *attr,
74 const char *buf, size_t count) 78 const char *buf, size_t count)
75{ 79{
76 char gov_name[CPUIDLE_NAME_LEN]; 80 char gov_name[CPUIDLE_NAME_LEN];
@@ -191,7 +195,7 @@ static ssize_t cpuidle_store(struct kobject * kobj, struct attribute * attr,
191 return ret; 195 return ret;
192} 196}
193 197
194static struct sysfs_ops cpuidle_sysfs_ops = { 198static const struct sysfs_ops cpuidle_sysfs_ops = {
195 .show = cpuidle_show, 199 .show = cpuidle_show,
196 .store = cpuidle_store, 200 .store = cpuidle_store,
197}; 201};
@@ -277,7 +281,7 @@ static ssize_t cpuidle_state_show(struct kobject * kobj,
277 return ret; 281 return ret;
278} 282}
279 283
280static struct sysfs_ops cpuidle_state_sysfs_ops = { 284static const struct sysfs_ops cpuidle_state_sysfs_ops = {
281 .show = cpuidle_state_show, 285 .show = cpuidle_state_show,
282}; 286};
283 287