From: Frederic Weisbecker Date: Sat, 4 Oct 2008 19:35:48 +0000 (+0200) Subject: tracing/fastboot: fix initcalls disposition in bootgraph.pl X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=07d1890420cce95c577736e4d67f70cbd39845fe;p=linux-beck.git tracing/fastboot: fix initcalls disposition in bootgraph.pl When bootgraph.pl parses a file, it gives one row for each initcall's pid. But only few of them will be displayed => the longest. This patch corrects it by giving only a rows for pids which have initcalls that will be displayed. Signed-off-by: Frederic Weisbecker Acked-by: Arjan van de Ven Signed-off-by: Ingo Molnar --- diff --git a/scripts/bootgraph.pl b/scripts/bootgraph.pl index 479fb4ea8914..5e7316e5aa39 100644 --- a/scripts/bootgraph.pl +++ b/scripts/bootgraph.pl @@ -110,6 +110,12 @@ while (($key,$value) = each %start) { if ($duration >= $threshold) { my $s, $s2, $e, $y; + $pid = $pids{$key}; + + if (!defined($rows{$pid})) { + $rows{$pid} = $rowscount; + $rowscount = $rowscount + 1; + } $s = ($value - $firsttime) * $mult; $s2 = $s + 6; $e = ($end{$key} - $firsttime) * $mult;