aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorAndi Kleen <andi@firstfloor.org>2008-07-30 01:33:52 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-07-30 12:41:47 -0400
commitf718cd4add5aea9d379faff92f162571e356cc5f (patch)
tree17ee7b9ed94c819985e4805436dc20b22e587f5f /kernel
parent5cdc98b8f51310f7cca05ad780f18f80dd9571de (diff)
sched: make scheduler sysfs attributes sysdev class devices
They are really class devices, but were incorrectly declared. This leads to crashes with the recent changes that makes non normal sysdevs use a different prototype. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Andi Kleen <ak@linux.intel.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Pierre Ossman <drzeus-list@drzeus.cx> Cc: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/sched.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/kernel/sched.c b/kernel/sched.c
index 0236958addcb..21f7da94662e 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -7671,34 +7671,34 @@ static ssize_t sched_power_savings_store(const char *buf, size_t count, int smt)
7671} 7671}
7672 7672
7673#ifdef CONFIG_SCHED_MC 7673#ifdef CONFIG_SCHED_MC
7674static ssize_t sched_mc_power_savings_show(struct sys_device *dev, 7674static ssize_t sched_mc_power_savings_show(struct sysdev_class *class,
7675 struct sysdev_attribute *attr, char *page) 7675 char *page)
7676{ 7676{
7677 return sprintf(page, "%u\n", sched_mc_power_savings); 7677 return sprintf(page, "%u\n", sched_mc_power_savings);
7678} 7678}
7679static ssize_t sched_mc_power_savings_store(struct sys_device *dev, 7679static ssize_t sched_mc_power_savings_store(struct sysdev_class *class,
7680 struct sysdev_attribute *attr,
7681 const char *buf, size_t count) 7680 const char *buf, size_t count)
7682{ 7681{
7683 return sched_power_savings_store(buf, count, 0); 7682 return sched_power_savings_store(buf, count, 0);
7684} 7683}
7685static SYSDEV_ATTR(sched_mc_power_savings, 0644, sched_mc_power_savings_show, 7684static SYSDEV_CLASS_ATTR(sched_mc_power_savings, 0644,
7686 sched_mc_power_savings_store); 7685 sched_mc_power_savings_show,
7686 sched_mc_power_savings_store);
7687#endif 7687#endif
7688 7688
7689#ifdef CONFIG_SCHED_SMT 7689#ifdef CONFIG_SCHED_SMT
7690static ssize_t sched_smt_power_savings_show(struct sys_device *dev, 7690static ssize_t sched_smt_power_savings_show(struct sysdev_class *dev,
7691 struct sysdev_attribute *attr, char *page) 7691 char *page)
7692{ 7692{
7693 return sprintf(page, "%u\n", sched_smt_power_savings); 7693 return sprintf(page, "%u\n", sched_smt_power_savings);
7694} 7694}
7695static ssize_t sched_smt_power_savings_store(struct sys_device *dev, 7695static ssize_t sched_smt_power_savings_store(struct sysdev_class *dev,
7696 struct sysdev_attribute *attr,
7697 const char *buf, size_t count) 7696 const char *buf, size_t count)
7698{ 7697{
7699 return sched_power_savings_store(buf, count, 1); 7698 return sched_power_savings_store(buf, count, 1);
7700} 7699}
7701static SYSDEV_ATTR(sched_smt_power_savings, 0644, sched_smt_power_savings_show, 7700static SYSDEV_CLASS_ATTR(sched_smt_power_savings, 0644,
7701 sched_smt_power_savings_show,
7702 sched_smt_power_savings_store); 7702 sched_smt_power_savings_store);
7703#endif 7703#endif
7704 7704