aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/ui/util.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2011-03-01perf tui: Make ui__warning modalArnaldo Carvalho de Melo1-2/+5
By taking the ui__lock so that no other screen updates take place while waiting for the user. That was happening when handling an invalid --vmlinux parameter in 'perf top --tui', with the screen refresh routine repainting the screen and removing the warning window. Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Tom Zanussi <tzanussi@gmail.com> LKML-Reference: <new-submission> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2010-11-27perf tools: Fix lost and unknown events handlingArnaldo Carvalho de Melo1-1/+15
Fix it by explaining what can be happening and giving the number of processed and lost events. Also holler if unknown events were found, that can be due to processing a perf.data file collected using a newer tool where newer events got added on reporting using an older perf tool, that or a bug, so ask for a report to be made. Works on both --tui and --stdio. Suggested-by: Thomas Gleixner <tglx@linutronix.de> Cc: Frédéric Weisbecker <fweisbec@gmail.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Paul Mackerras <paulus@samba.org> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> LKML-Reference: <new-submission> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2010-11-10perf, ui: Eliminate stack-smashing protection compiler complaintCyrill Gorcunov1-2/+3
The gcc complains about small auto-var strings being allocated from stack space. Make them const to avoid this: | CC util/ui/util.o | cc1: warnings being treated as errors | util/ui/util.c: In function ‘ui__dialog_yesno’: | util/ui/util.c:108: error: not protecting function: no buffer at least 8 bytes long | make: *** [util/ui/util.o] Error 1 The real bug is in the newtWinChoice() ABI - but that's an externality we cannot fix here, so we use this workaround. Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org> Acked-by: Frédéric Weisbecker <fweisbec@gmail.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> LKML-Reference: <20101106084724.GA5956@lenovo> Signed-off-by: Ingo Molnar <mingo@elte.hu>
2010-08-19perf ui browser: Add routines to compactly specify exit keysArnaldo Carvalho de Melo1-3/+1
This makes the usual idiom for specifying a series of key codes to exit ui_browser__run() for specialized processing (search, annotate, etc) or plain exiting the browser more compact. It also abstracts away some more libnewt operations. At some point we'll also replace NEWT_KEY_foo with something that can be mapped to NEWT or, say, gtk. Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> LKML-Reference: <new-submission> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2010-08-10perf ui: Complete the breakdown of util/newt.cArnaldo Carvalho de Melo1-0/+114
LKML-Reference: <new-submission> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>