This simply fixes some missing declarations and linux_syscall_number.h
cleanup related compiler warnings.

This is ok for commit to HEAD.

Signed-off-by: Garrett Cooper <[email protected]>

Index: testcases/kernel/performance_counters/performance_counter01.c
===================================================================
RCS file: 
/cvsroot/ltp/ltp/testcases/kernel/performance_counters/performance_counter01.c,v
retrieving revision 1.2
diff -u -r1.2 performance_counter01.c
--- testcases/kernel/performance_counters/performance_counter01.c       23
Jun 2009 14:21:32 -0000 1.2
+++ testcases/kernel/performance_counters/performance_counter01.c       3
Aug 2009 02:19:38 -0000
@@ -50,7 +50,7 @@
 char *TCID     = "performance_counter01"; /* test program identifier.
         */
 int  TST_TOTAL = 1;

-#define cleanup tst_exit /* for now... */
+static void cleanup(void) { /* Stub function. */ }

 int perf_counter_open(int              hw_event_type,
                       unsigned int     hw_event_period,
@@ -71,7 +71,8 @@
        PERF_COUNT_BRANCH_MISSES,
 };

-int main(void) {
+int
+main(void) {
        unsigned long long count1, count2;
        int fd1, fd2, ret;
        fd1 = perf_counter_open(PERF_COUNT_INSTRUCTIONS, 0, 0, 0, -1);
Index: testcases/kernel/performance_counters/performance_counter02.c
===================================================================
RCS file: 
/cvsroot/ltp/ltp/testcases/kernel/performance_counters/performance_counter02.c,v
retrieving revision 1.2
diff -u -r1.2 performance_counter02.c
--- testcases/kernel/performance_counters/performance_counter02.c       23
Jun 2009 14:21:32 -0000 1.2
+++ testcases/kernel/performance_counters/performance_counter02.c       3
Aug 2009 02:19:38 -0000
@@ -62,6 +62,8 @@
 #include <poll.h>
 #include <unistd.h>
 #include <errno.h>
+#include "config.h"
+#include <sys/prctl.h>
 #include <sys/types.h>
 #include <linux/types.h>
 #include <syscall.h>
@@ -82,7 +84,7 @@
 char *TCID     = "performance_counter02"; /* test program identifier.
         */
 int  TST_TOTAL = 1;                  /* total number of tests in this
file.   */

-#define cleanup tst_exit /* for now... */
+static void cleanup(void) { /* Stub function. */ }

 typedef unsigned int u32;
 typedef unsigned long long u64;
@@ -141,6 +143,7 @@
                asm volatile("" : : "g" (i));
 }

+int
 main(int ac, char **av)
 {
        int tsk0;
@@ -238,5 +241,5 @@
        }

        fprintf(stderr, "test passed\n");
-       exit(0);
+       tst_exit();
 }

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to