diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2017-03-27 13:31:06 +0200 |
---|---|---|
committer | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2017-03-27 13:31:06 +0200 |
commit | ae25669e4fa804667db38c044ce9b3f34da94250 (patch) | |
tree | 43bf2a379118f8266dffd3c0c266f89c58086838 /drivers/cpufreq | |
parent | da84368695d6d20543e2a66203aded81ff31756d (diff) | |
parent | 2a486264b736de1c1d938c9c781efbadbf9fd794 (diff) | |
download | linux-rt-ae25669e4fa804667db38c044ce9b3f34da94250.tar.gz |
Merge tag 'v4.9.18' into linux-4.9.y-rt
This is the 4.9.18 stable release
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Diffstat (limited to 'drivers/cpufreq')
-rw-r--r-- | drivers/cpufreq/cpufreq.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c index 6e6c1fb60fbc..272608f102fb 100644 --- a/drivers/cpufreq/cpufreq.c +++ b/drivers/cpufreq/cpufreq.c @@ -680,9 +680,11 @@ static ssize_t show_cpuinfo_cur_freq(struct cpufreq_policy *policy, char *buf) { unsigned int cur_freq = __cpufreq_get(policy); - if (!cur_freq) - return sprintf(buf, "<unknown>"); - return sprintf(buf, "%u\n", cur_freq); + + if (cur_freq) + return sprintf(buf, "%u\n", cur_freq); + + return sprintf(buf, "<unknown>\n"); } /** |