perf top: Fix percent output when no samples collected
authorNamhyung Kim <namhyung.kim@lge.com>
Tue, 14 May 2013 02:09:00 +0000 (11:09 +0900)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 28 May 2013 13:23:59 +0000 (16:23 +0300)
commit6f29097f45f6c375f2f6a76c589577575c7feb52
tree9eb90631bc8f0f5b36fdc1aa10ee99fdd41ed9f7
parent933cbb1c6c617a6ae167538c2fa503efc9c4a832
perf top: Fix percent output when no samples collected

If there's no sample, kernel and exact percent output at the header
looked like "-nan%".

Tested-by: Jiri Olsa <jolsa@redhat.com>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1368497347-9628-3-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/top.c