diff options
author | Stephen Hemminger <shemminger@vyatta.com> | 2008-11-13 11:33:00 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-11-13 13:58:22 -0500 |
commit | d1aaf8cf8afe70a8c2235a565885291fe290c57c (patch) | |
tree | 027bbef67998a8f7e3a519d66a62a45a6526b354 /scripts/bootgraph.pl | |
parent | 24de38620dd3504782c90c0892eef888d0c351e9 (diff) |
tracing/fastboot: put error message on stderr
Since this scripts output is usually redirected, put error messages
on standard error and exit with error code if no data is found.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'scripts/bootgraph.pl')
-rw-r--r-- | scripts/bootgraph.pl | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/scripts/bootgraph.pl b/scripts/bootgraph.pl index a8635a10fef..f0af9aa9b24 100644 --- a/scripts/bootgraph.pl +++ b/scripts/bootgraph.pl | |||
@@ -78,11 +78,13 @@ while (<>) { | |||
78 | } | 78 | } |
79 | 79 | ||
80 | if ($count == 0) { | 80 | if ($count == 0) { |
81 | print "No data found in the dmesg. Make sure that 'printk.time=1' and\n"; | 81 | print STDERR <<END; |
82 | print "'initcall_debug' are passed on the kernel command line.\n\n"; | 82 | No data found in the dmesg. Make sure that 'printk.time=1' and |
83 | print "Usage: \n"; | 83 | 'initcall_debug' are passed on the kernel command line. |
84 | print " dmesg | perl scripts/bootgraph.pl > output.svg\n\n"; | 84 | Usage: |
85 | exit; | 85 | dmesg | perl scripts/bootgraph.pl > output.svg |
86 | END | ||
87 | exit 1; | ||
86 | } | 88 | } |
87 | 89 | ||
88 | print "<?xml version=\"1.0\" standalone=\"no\"?> \n"; | 90 | print "<?xml version=\"1.0\" standalone=\"no\"?> \n"; |