diff options
| author | Yangtao Li <tiny.windzz@gmail.com> | 2019-02-16 11:15:01 -0500 |
|---|---|---|
| committer | Viresh Kumar <viresh.kumar@linaro.org> | 2019-02-17 23:57:38 -0500 |
| commit | d6c8e086e9d98a591a6b515078cb0e05fb538b5c (patch) | |
| tree | b13e357ce2fa0f15baa2406f640150a11c04939d | |
| parent | 5ae06c237fd05a1e9acf6f35891cfd85de792521 (diff) | |
cpufreq: speedstep: convert BUG() to BUG_ON()
To fix coccinelle WARNING.
WARNING: Use BUG_ON instead of if condition followed by BUG.
Signed-off-by: Yangtao Li <tiny.windzz@gmail.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
| -rw-r--r-- | drivers/cpufreq/speedstep-ich.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/cpufreq/speedstep-ich.c b/drivers/cpufreq/speedstep-ich.c index fbbcb88db061..5d8a09b82efb 100644 --- a/drivers/cpufreq/speedstep-ich.c +++ b/drivers/cpufreq/speedstep-ich.c | |||
| @@ -243,8 +243,7 @@ static unsigned int speedstep_get(unsigned int cpu) | |||
| 243 | unsigned int speed; | 243 | unsigned int speed; |
| 244 | 244 | ||
| 245 | /* You're supposed to ensure CPU is online. */ | 245 | /* You're supposed to ensure CPU is online. */ |
| 246 | if (smp_call_function_single(cpu, get_freq_data, &speed, 1) != 0) | 246 | BUG_ON(smp_call_function_single(cpu, get_freq_data, &speed, 1)); |
| 247 | BUG(); | ||
| 248 | 247 | ||
| 249 | pr_debug("detected %u kHz as current frequency\n", speed); | 248 | pr_debug("detected %u kHz as current frequency\n", speed); |
| 250 | return speed; | 249 | return speed; |
