aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/perf_counter/builtin-stat.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-05-27 03:10:38 -0400
committerIngo Molnar <mingo@elte.hu>2009-05-27 02:10:35 -0400
commit16f762a2ac5ecf8a11f6f0332e46cc3459220da5 (patch)
treea54f013d037637a91ceac237b2b0455b29cf45d4 /Documentation/perf_counter/builtin-stat.c
parent815e777f913ed54ddb449d2854015c65b4ecbfe3 (diff)
perf_counter tools: Introduce stricter C code checking
Tighten up our C code requirements: - disallow warnings - disallow declarations-mixed-with-statements - require proper prototypes - require C99 (with gcc extensions) Fix up a ton of problems these measures unearth: - unused functions - needlessly global functions - missing prototypes - code mixed with declarations Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com> Cc: Marcelo Tosatti <mtosatti@redhat.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: John Kacur <jkacur@redhat.com> Cc: Steven Rostedt <rostedt@goodmis.org> LKML-Reference: <20090526222155.GJ4424@ghostprotocols.net> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'Documentation/perf_counter/builtin-stat.c')
-rw-r--r--Documentation/perf_counter/builtin-stat.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Documentation/perf_counter/builtin-stat.c b/Documentation/perf_counter/builtin-stat.c
index e7cb9412212b..ce661e2fa8dd 100644
--- a/Documentation/perf_counter/builtin-stat.c
+++ b/Documentation/perf_counter/builtin-stat.c
@@ -30,6 +30,7 @@
30 */ 30 */
31 31
32#include "perf.h" 32#include "perf.h"
33#include "builtin.h"
33#include "util/util.h" 34#include "util/util.h"
34#include "util/parse-options.h" 35#include "util/parse-options.h"
35#include "util/parse-events.h" 36#include "util/parse-events.h"
@@ -108,7 +109,7 @@ static void create_perfstat_counter(int counter)
108 } 109 }
109} 110}
110 111
111int do_perfstat(int argc, const char **argv) 112static int do_perfstat(int argc, const char **argv)
112{ 113{
113 unsigned long long t0, t1; 114 unsigned long long t0, t1;
114 int counter; 115 int counter;