aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/devfreq
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/devfreq')
-rw-r--r--drivers/devfreq/devfreq.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c
index a42f69b34eb2..79a7343c28a6 100644
--- a/drivers/devfreq/devfreq.c
+++ b/drivers/devfreq/devfreq.c
@@ -496,12 +496,11 @@ static ssize_t store_polling_interval(struct device *dev,
496 496
497 ret = sscanf(buf, "%u", &value); 497 ret = sscanf(buf, "%u", &value);
498 if (ret != 1) 498 if (ret != 1)
499 goto out; 499 return -EINVAL;
500 500
501 df->governor->event_handler(df, DEVFREQ_GOV_INTERVAL, &value); 501 df->governor->event_handler(df, DEVFREQ_GOV_INTERVAL, &value);
502 ret = count; 502 ret = count;
503 503
504out:
505 return ret; 504 return ret;
506} 505}
507 506
@@ -515,7 +514,7 @@ static ssize_t store_min_freq(struct device *dev, struct device_attribute *attr,
515 514
516 ret = sscanf(buf, "%lu", &value); 515 ret = sscanf(buf, "%lu", &value);
517 if (ret != 1) 516 if (ret != 1)
518 goto out; 517 return -EINVAL;
519 518
520 mutex_lock(&df->lock); 519 mutex_lock(&df->lock);
521 max = df->max_freq; 520 max = df->max_freq;
@@ -529,7 +528,6 @@ static ssize_t store_min_freq(struct device *dev, struct device_attribute *attr,
529 ret = count; 528 ret = count;
530unlock: 529unlock:
531 mutex_unlock(&df->lock); 530 mutex_unlock(&df->lock);
532out:
533 return ret; 531 return ret;
534} 532}
535 533
@@ -549,7 +547,7 @@ static ssize_t store_max_freq(struct device *dev, struct device_attribute *attr,
549 547
550 ret = sscanf(buf, "%lu", &value); 548 ret = sscanf(buf, "%lu", &value);
551 if (ret != 1) 549 if (ret != 1)
552 goto out; 550 return -EINVAL;
553 551
554 mutex_lock(&df->lock); 552 mutex_lock(&df->lock);
555 min = df->min_freq; 553 min = df->min_freq;
@@ -563,7 +561,6 @@ static ssize_t store_max_freq(struct device *dev, struct device_attribute *attr,
563 ret = count; 561 ret = count;
564unlock: 562unlock:
565 mutex_unlock(&df->lock); 563 mutex_unlock(&df->lock);
566out:
567 return ret; 564 return ret;
568} 565}
569 566