diff options
author | Joe Perches <joe@perches.com> | 2014-07-14 09:16:15 -0400 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-09-07 19:24:47 -0400 |
commit | eea203fea3484598280a07fe503e025e886297fb (patch) | |
tree | 7456a2d44438ebbb4badad2d1a3818008c85c1d4 /kernel/torture.c | |
parent | 188c1e896c0c28ac98809d11b6f29523805b34ef (diff) |
rcu: Use pr_alert/pr_cont for printing logs
User pr_alert/pr_cont for printing the logs from rcutorture module directly
instead of writing it to a buffer and then printing it. This allows us from not
having to allocate such buffers. Also remove a resulting empty function.
I tested this using the parse-torture.sh script as follows:
$ dmesg | grep torture > log.txt
$ bash parse-torture.sh log.txt test
$
There were no warnings which means that parsing went fine.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Pranith Kumar <bobby.prani@gmail.com>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Diffstat (limited to 'kernel/torture.c')
-rw-r--r-- | kernel/torture.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/kernel/torture.c b/kernel/torture.c index d600af21f022..ede8b25ec1ae 100644 --- a/kernel/torture.c +++ b/kernel/torture.c | |||
@@ -211,18 +211,16 @@ EXPORT_SYMBOL_GPL(torture_onoff_cleanup); | |||
211 | /* | 211 | /* |
212 | * Print online/offline testing statistics. | 212 | * Print online/offline testing statistics. |
213 | */ | 213 | */ |
214 | char *torture_onoff_stats(char *page) | 214 | void torture_onoff_stats(void) |
215 | { | 215 | { |
216 | #ifdef CONFIG_HOTPLUG_CPU | 216 | #ifdef CONFIG_HOTPLUG_CPU |
217 | page += sprintf(page, | 217 | pr_cont("onoff: %ld/%ld:%ld/%ld %d,%d:%d,%d %lu:%lu (HZ=%d) ", |
218 | "onoff: %ld/%ld:%ld/%ld %d,%d:%d,%d %lu:%lu (HZ=%d) ", | 218 | n_online_successes, n_online_attempts, |
219 | n_online_successes, n_online_attempts, | 219 | n_offline_successes, n_offline_attempts, |
220 | n_offline_successes, n_offline_attempts, | 220 | min_online, max_online, |
221 | min_online, max_online, | 221 | min_offline, max_offline, |
222 | min_offline, max_offline, | 222 | sum_online, sum_offline, HZ); |
223 | sum_online, sum_offline, HZ); | ||
224 | #endif /* #ifdef CONFIG_HOTPLUG_CPU */ | 223 | #endif /* #ifdef CONFIG_HOTPLUG_CPU */ |
225 | return page; | ||
226 | } | 224 | } |
227 | EXPORT_SYMBOL_GPL(torture_onoff_stats); | 225 | EXPORT_SYMBOL_GPL(torture_onoff_stats); |
228 | 226 | ||