Included new function to check feature versus kernel version
Signed-off-by: poornima nayak <[email protected]>
diff -uprN ltp_orig/testcases/kernel/power_management/check_kv_arch.c
ltp/testcases/kernel/power_management/check_kv_arch.c
--- ltp_orig/testcases/kernel/power_management/check_kv_arch.c 2009-08-28
10:54:59.000000000 +0530
+++ ltp/testcases/kernel/power_management/check_kv_arch.c 2009-08-28
12:36:07.000000000 +0530
@@ -23,6 +23,12 @@ int kernel_is_too_old(void) {
return 0;
}
+int check_timer_migr_supp(void) {
+ if (tst_kvercmp(2,6,31) < 0)
+ return 1;
+ return 0;
+}
+
/*
* yeah, to make the makefile coding easier, do_check returns
* 1 if unshare is not supported, 0 if it is
@@ -35,7 +41,17 @@ int do_check(void) { return kernel_is_to
int do_check(void) { return 1; }
#endif
-int main() {
- return do_check();
+int main(int argc, char *argv[]) {
+ char feature[20];
+ if (argc == 1)
+ return do_check();
+ else
+ {
+ printf("argument is %s", argv[1]);
+ if (strcmp(argv[1], "timer_migration")==0)
+ if (check_timer_migr_supp() == 0)
+ return 0;
+ else
+ return 1;
+ }
}
-
------------------------------------------------------------------------------
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