Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 108246
b: refs/heads/master
c: 66198f3
h: refs/heads/master
v: v3
  • Loading branch information
Rabin Vincent authored and Linus Torvalds committed Aug 12, 2008
1 parent 1c2e849 commit a6fd265
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 15 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 001e979d8f0c8fa04b5f01e829805dcd49d9416b
refs/heads/master: 66198f36aac21533245a77aac4a8f7c8c509d8bd
29 changes: 15 additions & 14 deletions trunk/drivers/cpuidle/sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ static int __init cpuidle_sysfs_setup(char *unused)
}
__setup("cpuidle_sysfs_switch", cpuidle_sysfs_setup);

static ssize_t show_available_governors(struct sys_device *dev,
struct sysdev_attribute *attr, char *buf)
static ssize_t show_available_governors(struct sysdev_class *class,
char *buf)
{
ssize_t i = 0;
struct cpuidle_governor *tmp;
Expand All @@ -40,8 +40,8 @@ static ssize_t show_available_governors(struct sys_device *dev,
return i;
}

static ssize_t show_current_driver(struct sys_device *dev,
struct sysdev_attribute *attr, char *buf)
static ssize_t show_current_driver(struct sysdev_class *class,
char *buf)
{
ssize_t ret;

Expand All @@ -55,8 +55,8 @@ static ssize_t show_current_driver(struct sys_device *dev,
return ret;
}

static ssize_t show_current_governor(struct sys_device *dev,
struct sysdev_attribute *attr, char *buf)
static ssize_t show_current_governor(struct sysdev_class *class,
char *buf)
{
ssize_t ret;

Expand All @@ -70,9 +70,8 @@ static ssize_t show_current_governor(struct sys_device *dev,
return ret;
}

static ssize_t store_current_governor(struct sys_device *dev,
struct sysdev_attribute *attr,
const char *buf, size_t count)
static ssize_t store_current_governor(struct sysdev_class *class,
const char *buf, size_t count)
{
char gov_name[CPUIDLE_NAME_LEN];
int ret = -EINVAL;
Expand Down Expand Up @@ -104,18 +103,20 @@ static ssize_t store_current_governor(struct sys_device *dev,
return count;
}

static SYSDEV_ATTR(current_driver, 0444, show_current_driver, NULL);
static SYSDEV_ATTR(current_governor_ro, 0444, show_current_governor, NULL);
static SYSDEV_CLASS_ATTR(current_driver, 0444, show_current_driver, NULL);
static SYSDEV_CLASS_ATTR(current_governor_ro, 0444, show_current_governor,
NULL);

static struct attribute *cpuclass_default_attrs[] = {
&attr_current_driver.attr,
&attr_current_governor_ro.attr,
NULL
};

static SYSDEV_ATTR(available_governors, 0444, show_available_governors, NULL);
static SYSDEV_ATTR(current_governor, 0644, show_current_governor,
store_current_governor);
static SYSDEV_CLASS_ATTR(available_governors, 0444, show_available_governors,
NULL);
static SYSDEV_CLASS_ATTR(current_governor, 0644, show_current_governor,
store_current_governor);

static struct attribute *cpuclass_switch_attrs[] = {
&attr_available_governors.attr,
Expand Down

0 comments on commit a6fd265

Please sign in to comment.