Commit a9c2d07b authored by Randy Dunlap's avatar Randy Dunlap Committed by Linus Torvalds

[PATCH] janitor: use -Evalues in cpufreq/speedstep

From: Maximilian Attems <janitor@sternwelten.at>
parent 462335fa
...@@ -230,12 +230,12 @@ unsigned int speedstep_get_freqs(unsigned int processor, ...@@ -230,12 +230,12 @@ unsigned int speedstep_get_freqs(unsigned int processor,
unsigned long flags; unsigned long flags;
if ((!processor) || (!low_speed) || (!high_speed) || (!set_state)) if ((!processor) || (!low_speed) || (!high_speed) || (!set_state))
return EINVAL; return -EINVAL;
/* get current speed */ /* get current speed */
prev_speed = speedstep_get_processor_frequency(processor); prev_speed = speedstep_get_processor_frequency(processor);
if (!prev_speed) if (!prev_speed)
return EIO; return -EIO;
local_irq_save(flags); local_irq_save(flags);
...@@ -243,7 +243,7 @@ unsigned int speedstep_get_freqs(unsigned int processor, ...@@ -243,7 +243,7 @@ unsigned int speedstep_get_freqs(unsigned int processor,
set_state(SPEEDSTEP_LOW, 0); set_state(SPEEDSTEP_LOW, 0);
*low_speed = speedstep_get_processor_frequency(processor); *low_speed = speedstep_get_processor_frequency(processor);
if (!*low_speed) { if (!*low_speed) {
ret = EIO; ret = -EIO;
goto out; goto out;
} }
...@@ -251,12 +251,12 @@ unsigned int speedstep_get_freqs(unsigned int processor, ...@@ -251,12 +251,12 @@ unsigned int speedstep_get_freqs(unsigned int processor,
set_state(SPEEDSTEP_HIGH, 0); set_state(SPEEDSTEP_HIGH, 0);
*high_speed = speedstep_get_processor_frequency(processor); *high_speed = speedstep_get_processor_frequency(processor);
if (!*high_speed) { if (!*high_speed) {
ret = EIO; ret = -EIO;
goto out; goto out;
} }
if (*low_speed == *high_speed) { if (*low_speed == *high_speed) {
ret = ENODEV; ret = -ENODEV;
goto out; goto out;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment