public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [Git] ltp updated.
@ 2010-03-10  4:30 Rishi kesh K Rajak
  2010-03-10  5:18 ` Shi Weihua
  0 siblings, 1 reply; 10+ messages in thread
From: Rishi kesh K Rajak @ 2010-03-10  4:30 UTC (permalink / raw)
  To: ltp-list

The branch, master, has been updated
       via  48c52fcd4e7668bc36bbe080f53462d410712b69 (commit)
      from  c962f51674b971496e14ac4be0cc75da98b75fca (commit)


- Log -----------------------------------------------------------------
commit 48c52fcd4e7668bc36bbe080f53462d410712b69
Author: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>
Date:   Wed Mar 10 10:00:22 2010 +0530

    Instead of LIBS, it should be LDLIBS in container/Makefile
    
    Signed-off-by: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>

-----------------------------------------------------------------------

Summary of changes:
 testcases/kernel/containers/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
 
diff --git a/testcases/kernel/containers/Makefile b/testcases/kernel/containers/Makefile
index 26f1856..29394c3 100644
--- a/testcases/kernel/containers/Makefile
+++ b/testcases/kernel/containers/Makefile
@@ -26,7 +26,7 @@ FILTER_OUT_DIRS		:= $(LIBDIR)
 
 LIB			:= $(LIBDIR)/libclone.a
 
-LIB			:= -ld
+LDLIB			:= -ldl
 
 INSTALL_TARGETS		:= *.sh 
 


hooks/post-receive
-- 
ltp

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 10+ messages in thread
* [LTP] [Git] ltp updated.
@ 2010-03-10  5:36 Rishi kesh K Rajak
  0 siblings, 0 replies; 10+ messages in thread
From: Rishi kesh K Rajak @ 2010-03-10  5:36 UTC (permalink / raw)
  To: ltp-list

The branch, pu, has been updated
       via  615e1e37de053855b6bd56bae8b00d8a17133f8a (commit)
       via  1a5506c97dcfda0bd16f83ca855bb633c47eea4c (commit)
       via  48c52fcd4e7668bc36bbe080f53462d410712b69 (commit)
       via  c962f51674b971496e14ac4be0cc75da98b75fca (commit)
       via  17905ceabf2dc20e978dfa4ea3682197ad01bf9a (commit)
       via  bdfe0b2a9dd720c3013225cc4aa1628e77888b24 (commit)
       via  716d29883b11107c32313b1836bea447fecbaf1e (commit)
       via  58854395050b8a3bb2fa4e5e4401546925f6aad8 (commit)
       via  886918830ae73a7f4b5cc2d9bf8554ee9f393ed8 (commit)
       via  039e4bbd522168a5145d236faa4e13f402037390 (commit)
      from  63f0a8f554d28b28b207f41e42182e1b789333b6 (commit)


- Log -----------------------------------------------------------------
commit 615e1e37de053855b6bd56bae8b00d8a17133f8a
Author: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>
Date:   Wed Mar 10 11:05:40 2010 +0530

    Merge branches 'master' and 'pu' into pu

-----------------------------------------------------------------------

Summary of changes:
 TODO                                               |    2 +-
 testcases/kernel/containers/Makefile               |    2 +
 .../check_netns_enabled.c => check_for_unshare.c}  |   60 +++++++++++---------
 .../kernel/controllers/freezer/run_freezer.sh      |    3 +-
 testcases/kernel/syscalls/libevent/Makefile.in     |    3 +-
 5 files changed, 40 insertions(+), 30 deletions(-)
 copy testcases/kernel/containers/{netns/check_netns_enabled.c => check_for_unshare.c} (52%)
 
diff --git a/TODO b/TODO
index 9eec828..1756168 100644
--- a/TODO
+++ b/TODO
@@ -1,4 +1,4 @@
-The following things need to be rewritten // fixed:
+The following things need to be rewritten // fixed
 
 get_mempolicy01 // mbind01: They're using numa v1 calls which means that all
 versions of Linux / numa as of a few years ago aren't compatible with the API
diff --git a/testcases/kernel/containers/Makefile b/testcases/kernel/containers/Makefile
index 6a7810e..75eda63 100644
--- a/testcases/kernel/containers/Makefile
+++ b/testcases/kernel/containers/Makefile
@@ -26,6 +26,8 @@ FILTER_OUT_DIRS		:= $(LIBDIR)
 
 LIB			:= $(LIBDIR)/libclone.a
 
+LDLIBS			:= -ldl
+
 INSTALL_TARGETS		:= *.sh 
 
 $(LIBDIR):
diff --git a/testcases/kernel/containers/netns/check_netns_enabled.c b/testcases/kernel/containers/check_for_unshare.c
similarity index 52%
copy from testcases/kernel/containers/netns/check_netns_enabled.c
copy to testcases/kernel/containers/check_for_unshare.c
index f6add06..06bdfd7 100644
--- a/testcases/kernel/containers/netns/check_netns_enabled.c
+++ b/testcases/kernel/containers/check_for_unshare.c
@@ -13,37 +13,43 @@
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 *
-* Author: Veerendra C <vechandr@in.ibm.com>
+**************************************************************************/
+/*
+* Description:
+* This program verifies the kernel version to be no later than 2.6.16
+* And checks if the unshare() system call is defined using dlsym(),
+* in the Dynamically Linked Libraries.
 *
-* Net namespaces were introduced around 2.6.25.  Kernels before that,
-* assume they are not enabled.  Kernels after that, check for -EINVAL
-* when trying to use CLONE_NEWNET and CLONE_NEWNS.
-***************************************************************************/
-#include <stdio.h>
-#include <sched.h>
-#include "config.h"
-#include "libclone.h"
-#include "linux_syscall_numbers.h"
-#include "test.h"
+* Date : 26-11-2008
+* Author : Veerendra C <vechandr@in.ibm.com>
+*/
 
-char *TCID = "check_netns_enabled";
-int TST_COUNT = 1;
-int TST_TOTAL = 1; 
+#include <stdio.h>
+#include <stdlib.h>
+#include <dlfcn.h>
+#include <linux/version.h>
 
-#ifndef CLONE_NEWNET
-#define CLONE_NEWNET -1
-#endif
+int main(int argc, char **argv)
+{
+	void *handle;
+	void *ret;
+	char *error;
+	if (LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 16))
+	return 1;
 
-#ifndef CLONE_NEWNS
-#define CLONE_NEWNS -1
-#endif
+	handle = dlopen(NULL, RTLD_LAZY);
+	if (!handle) {
+		fprintf(stderr, "%s\n", dlerror());
+		exit(1);
+	}
 
-int
-main()
-{
-	/* Checking if the kernel supports unshare with netns capabilities. */
-        if (syscall(__NR_unshare, CLONE_NEWNET | CLONE_NEWNS) < 0) {
-		tst_resm (TFAIL | TERRNO, "unshare syscall smoke test failed");
+	dlerror();    /* Clear any existing error */
+	ret = dlsym(handle, "unshare");
+	if ((error = dlerror()) != NULL)  {
+		fprintf(stderr, "Error: %s\n", error);
+		exit(1);
 	}
-	tst_exit();
+
+	dlclose(handle);
+	return 0;
 }
diff --git a/testcases/kernel/controllers/freezer/run_freezer.sh b/testcases/kernel/controllers/freezer/run_freezer.sh
index 3baf968..f66e321 100755
--- a/testcases/kernel/controllers/freezer/run_freezer.sh
+++ b/testcases/kernel/controllers/freezer/run_freezer.sh
@@ -69,7 +69,8 @@ function test_setup()
 	export LTPBIN PATH TCID TST_COUNT TST_TOTAL CGROUPS_TESTROOT
 	tst_resm TINFO "Preparing to run: ${P} $@"
 
-	make all
+	# this is not require here
+	#make all
 }
 
 function test_prereqs()
diff --git a/testcases/kernel/syscalls/libevent/Makefile.in b/testcases/kernel/syscalls/libevent/Makefile.in
index d1d9af7..dd0138d 100644
--- a/testcases/kernel/syscalls/libevent/Makefile.in
+++ b/testcases/kernel/syscalls/libevent/Makefile.in
@@ -99,6 +99,7 @@ LIBS = @LIBS@
 libevent_a_DEPENDENCIES =  @LIBOBJS@
 libevent_a_OBJECTS =  event.o buffer.o evbuffer.o
 AR = ar
+AR_FLAGS = cr
 COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
 CCLD = $(CC)
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS) -o $@
@@ -219,7 +220,7 @@ maintainer-clean-compile:
 
 libevent.a: $(libevent_a_OBJECTS) $(libevent_a_DEPENDENCIES)
 	-rm -f libevent.a
-	$(AR) cru libevent.a $(libevent_a_OBJECTS) $(libevent_a_LIBADD)
+	$(AR) $(AR_FLAGS) libevent.a $(libevent_a_OBJECTS) $(libevent_a_LIBADD)
 	$(RANLIB) libevent.a
 
 install-man3:


hooks/post-receive
-- 
ltp

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 10+ messages in thread
* [LTP] [Git] ltp updated.
@ 2010-03-10  5:35 Rishi kesh K Rajak
  0 siblings, 0 replies; 10+ messages in thread
From: Rishi kesh K Rajak @ 2010-03-10  5:35 UTC (permalink / raw)
  To: ltp-list

The branch, next, has been updated
       via  ce944320bea9e3d7044a36c64ef2e1719312370d (commit)
       via  1a5506c97dcfda0bd16f83ca855bb633c47eea4c (commit)
       via  48c52fcd4e7668bc36bbe080f53462d410712b69 (commit)
       via  c962f51674b971496e14ac4be0cc75da98b75fca (commit)
       via  17905ceabf2dc20e978dfa4ea3682197ad01bf9a (commit)
      from  bdfe0b2a9dd720c3013225cc4aa1628e77888b24 (commit)


- Log -----------------------------------------------------------------
commit ce944320bea9e3d7044a36c64ef2e1719312370d
Author: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>
Date:   Wed Mar 10 11:03:42 2010 +0530

    Merge branches 'master' and 'next' into next

-----------------------------------------------------------------------

Summary of changes:
 TODO                                 |    2 +-
 testcases/kernel/containers/Makefile |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
 
diff --git a/TODO b/TODO
index 9eec828..1756168 100644
--- a/TODO
+++ b/TODO
@@ -1,4 +1,4 @@
-The following things need to be rewritten // fixed:
+The following things need to be rewritten // fixed
 
 get_mempolicy01 // mbind01: They're using numa v1 calls which means that all
 versions of Linux / numa as of a few years ago aren't compatible with the API
diff --git a/testcases/kernel/containers/Makefile b/testcases/kernel/containers/Makefile
index 26f1856..75eda63 100644
--- a/testcases/kernel/containers/Makefile
+++ b/testcases/kernel/containers/Makefile
@@ -26,7 +26,7 @@ FILTER_OUT_DIRS		:= $(LIBDIR)
 
 LIB			:= $(LIBDIR)/libclone.a
 
-LIB			:= -ld
+LDLIBS			:= -ldl
 
 INSTALL_TARGETS		:= *.sh 
 


hooks/post-receive
-- 
ltp

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 10+ messages in thread
* [LTP] [Git] ltp updated.
@ 2010-03-10  5:34 Rishi kesh K Rajak
  0 siblings, 0 replies; 10+ messages in thread
From: Rishi kesh K Rajak @ 2010-03-10  5:34 UTC (permalink / raw)
  To: ltp-list

The branch, maint, has been updated
       via  b8ed5460176838d9b714dddbc17685983b4a8b9b (commit)
       via  1a5506c97dcfda0bd16f83ca855bb633c47eea4c (commit)
       via  48c52fcd4e7668bc36bbe080f53462d410712b69 (commit)
       via  c962f51674b971496e14ac4be0cc75da98b75fca (commit)
       via  17905ceabf2dc20e978dfa4ea3682197ad01bf9a (commit)
       via  bdfe0b2a9dd720c3013225cc4aa1628e77888b24 (commit)
       via  716d29883b11107c32313b1836bea447fecbaf1e (commit)
       via  58854395050b8a3bb2fa4e5e4401546925f6aad8 (commit)
       via  886918830ae73a7f4b5cc2d9bf8554ee9f393ed8 (commit)
       via  039e4bbd522168a5145d236faa4e13f402037390 (commit)
      from  e8e3c7598b82b54a7770c48a2422d5d6fa127045 (commit)


- Log -----------------------------------------------------------------
commit b8ed5460176838d9b714dddbc17685983b4a8b9b
Merge: e8e3c7598b82b54a7770c48a2422d5d6fa127045 1a5506c97dcfda0bd16f83ca855bb633c47eea4c
Author: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>
Date:   Wed Mar 10 11:03:55 2010 +0530

    Merge branches 'master' and 'maint' into maint

-----------------------------------------------------------------------

Summary of changes:
 TODO                                               |    2 +-
 testcases/kernel/containers/Makefile               |    2 +
 .../check_netns_enabled.c => check_for_unshare.c}  |   60 +++++++++++---------
 .../kernel/controllers/freezer/run_freezer.sh      |    3 +-
 testcases/kernel/syscalls/libevent/Makefile.in     |    3 +-
 5 files changed, 40 insertions(+), 30 deletions(-)
 copy testcases/kernel/containers/{netns/check_netns_enabled.c => check_for_unshare.c} (52%)
 
diff --git a/TODO b/TODO
index 9eec828..1756168 100644
--- a/TODO
+++ b/TODO
@@ -1,4 +1,4 @@
-The following things need to be rewritten // fixed:
+The following things need to be rewritten // fixed
 
 get_mempolicy01 // mbind01: They're using numa v1 calls which means that all
 versions of Linux / numa as of a few years ago aren't compatible with the API
diff --git a/testcases/kernel/containers/Makefile b/testcases/kernel/containers/Makefile
index 6a7810e..75eda63 100644
--- a/testcases/kernel/containers/Makefile
+++ b/testcases/kernel/containers/Makefile
@@ -26,6 +26,8 @@ FILTER_OUT_DIRS		:= $(LIBDIR)
 
 LIB			:= $(LIBDIR)/libclone.a
 
+LDLIBS			:= -ldl
+
 INSTALL_TARGETS		:= *.sh 
 
 $(LIBDIR):
diff --git a/testcases/kernel/containers/netns/check_netns_enabled.c b/testcases/kernel/containers/check_for_unshare.c
similarity index 52%
copy from testcases/kernel/containers/netns/check_netns_enabled.c
copy to testcases/kernel/containers/check_for_unshare.c
index f6add06..06bdfd7 100644
--- a/testcases/kernel/containers/netns/check_netns_enabled.c
+++ b/testcases/kernel/containers/check_for_unshare.c
@@ -13,37 +13,43 @@
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 *
-* Author: Veerendra C <vechandr@in.ibm.com>
+**************************************************************************/
+/*
+* Description:
+* This program verifies the kernel version to be no later than 2.6.16
+* And checks if the unshare() system call is defined using dlsym(),
+* in the Dynamically Linked Libraries.
 *
-* Net namespaces were introduced around 2.6.25.  Kernels before that,
-* assume they are not enabled.  Kernels after that, check for -EINVAL
-* when trying to use CLONE_NEWNET and CLONE_NEWNS.
-***************************************************************************/
-#include <stdio.h>
-#include <sched.h>
-#include "config.h"
-#include "libclone.h"
-#include "linux_syscall_numbers.h"
-#include "test.h"
+* Date : 26-11-2008
+* Author : Veerendra C <vechandr@in.ibm.com>
+*/
 
-char *TCID = "check_netns_enabled";
-int TST_COUNT = 1;
-int TST_TOTAL = 1; 
+#include <stdio.h>
+#include <stdlib.h>
+#include <dlfcn.h>
+#include <linux/version.h>
 
-#ifndef CLONE_NEWNET
-#define CLONE_NEWNET -1
-#endif
+int main(int argc, char **argv)
+{
+	void *handle;
+	void *ret;
+	char *error;
+	if (LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 16))
+	return 1;
 
-#ifndef CLONE_NEWNS
-#define CLONE_NEWNS -1
-#endif
+	handle = dlopen(NULL, RTLD_LAZY);
+	if (!handle) {
+		fprintf(stderr, "%s\n", dlerror());
+		exit(1);
+	}
 
-int
-main()
-{
-	/* Checking if the kernel supports unshare with netns capabilities. */
-        if (syscall(__NR_unshare, CLONE_NEWNET | CLONE_NEWNS) < 0) {
-		tst_resm (TFAIL | TERRNO, "unshare syscall smoke test failed");
+	dlerror();    /* Clear any existing error */
+	ret = dlsym(handle, "unshare");
+	if ((error = dlerror()) != NULL)  {
+		fprintf(stderr, "Error: %s\n", error);
+		exit(1);
 	}
-	tst_exit();
+
+	dlclose(handle);
+	return 0;
 }
diff --git a/testcases/kernel/controllers/freezer/run_freezer.sh b/testcases/kernel/controllers/freezer/run_freezer.sh
index 3baf968..f66e321 100755
--- a/testcases/kernel/controllers/freezer/run_freezer.sh
+++ b/testcases/kernel/controllers/freezer/run_freezer.sh
@@ -69,7 +69,8 @@ function test_setup()
 	export LTPBIN PATH TCID TST_COUNT TST_TOTAL CGROUPS_TESTROOT
 	tst_resm TINFO "Preparing to run: ${P} $@"
 
-	make all
+	# this is not require here
+	#make all
 }
 
 function test_prereqs()
diff --git a/testcases/kernel/syscalls/libevent/Makefile.in b/testcases/kernel/syscalls/libevent/Makefile.in
index d1d9af7..dd0138d 100644
--- a/testcases/kernel/syscalls/libevent/Makefile.in
+++ b/testcases/kernel/syscalls/libevent/Makefile.in
@@ -99,6 +99,7 @@ LIBS = @LIBS@
 libevent_a_DEPENDENCIES =  @LIBOBJS@
 libevent_a_OBJECTS =  event.o buffer.o evbuffer.o
 AR = ar
+AR_FLAGS = cr
 COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
 CCLD = $(CC)
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS) -o $@
@@ -219,7 +220,7 @@ maintainer-clean-compile:
 
 libevent.a: $(libevent_a_OBJECTS) $(libevent_a_DEPENDENCIES)
 	-rm -f libevent.a
-	$(AR) cru libevent.a $(libevent_a_OBJECTS) $(libevent_a_LIBADD)
+	$(AR) $(AR_FLAGS) libevent.a $(libevent_a_OBJECTS) $(libevent_a_LIBADD)
 	$(RANLIB) libevent.a
 
 install-man3:


hooks/post-receive
-- 
ltp

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 10+ messages in thread
* [LTP] [Git] ltp updated.
@ 2010-03-10  5:32 Rishi kesh K Rajak
  0 siblings, 0 replies; 10+ messages in thread
From: Rishi kesh K Rajak @ 2010-03-10  5:32 UTC (permalink / raw)
  To: ltp-list

The branch, master, has been updated
       via  1a5506c97dcfda0bd16f83ca855bb633c47eea4c (commit)
      from  48c52fcd4e7668bc36bbe080f53462d410712b69 (commit)


- Log -----------------------------------------------------------------
commit 1a5506c97dcfda0bd16f83ca855bb633c47eea4c
Author: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>
Date:   Wed Mar 10 11:01:47 2010 +0530

    Fix make filed,, reported by Shi Weihua <shiwh@cn.fujitsu.com>
    It was my bad :( .
    
    Signed-off-by: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>

-----------------------------------------------------------------------

Summary of changes:
 testcases/kernel/containers/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
 
diff --git a/testcases/kernel/containers/Makefile b/testcases/kernel/containers/Makefile
index 29394c3..75eda63 100644
--- a/testcases/kernel/containers/Makefile
+++ b/testcases/kernel/containers/Makefile
@@ -26,7 +26,7 @@ FILTER_OUT_DIRS		:= $(LIBDIR)
 
 LIB			:= $(LIBDIR)/libclone.a
 
-LDLIB			:= -ldl
+LDLIBS			:= -ldl
 
 INSTALL_TARGETS		:= *.sh 
 


hooks/post-receive
-- 
ltp

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 10+ messages in thread
* [LTP] [Git] ltp updated.
@ 2010-03-09 16:23 Rishi kesh K Rajak
  2010-03-09 20:47 ` Garrett Cooper
  0 siblings, 1 reply; 10+ messages in thread
From: Rishi kesh K Rajak @ 2010-03-09 16:23 UTC (permalink / raw)
  To: ltp-list

The branch, master, has been updated
       via  c962f51674b971496e14ac4be0cc75da98b75fca (commit)
       via  17905ceabf2dc20e978dfa4ea3682197ad01bf9a (commit)
       via  bdfe0b2a9dd720c3013225cc4aa1628e77888b24 (commit)
       via  716d29883b11107c32313b1836bea447fecbaf1e (commit)
       via  58854395050b8a3bb2fa4e5e4401546925f6aad8 (commit)
       via  886918830ae73a7f4b5cc2d9bf8554ee9f393ed8 (commit)
       via  039e4bbd522168a5145d236faa4e13f402037390 (commit)
      from  63f0a8f554d28b28b207f41e42182e1b789333b6 (commit)


- Log -----------------------------------------------------------------
commit c962f51674b971496e14ac4be0cc75da98b75fca
Author: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>
Date:   Tue Mar 9 21:53:25 2010 +0530

    Testing for post-receive-email
    
    Signed-off-by: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>

commit 17905ceabf2dc20e978dfa4ea3682197ad01bf9a
Author: Rishikesh K Rajak <risrajak@linux.vnet.ibm.com>
Date:   Tue Mar 9 14:11:41 2010 +0530

    Merge branches 'next' and 'master'

-----------------------------------------------------------------------

Summary of changes:
 TODO                                               |    2 +-
 testcases/kernel/containers/Makefile               |    2 +
 .../check_netns_enabled.c => check_for_unshare.c}  |   60 +++++++++++---------
 .../kernel/controllers/freezer/run_freezer.sh      |    3 +-
 testcases/kernel/syscalls/libevent/Makefile.in     |    3 +-
 5 files changed, 40 insertions(+), 30 deletions(-)
 copy testcases/kernel/containers/{netns/check_netns_enabled.c => check_for_unshare.c} (52%)
 
diff --git a/TODO b/TODO
index 9eec828..1756168 100644
--- a/TODO
+++ b/TODO
@@ -1,4 +1,4 @@
-The following things need to be rewritten // fixed:
+The following things need to be rewritten // fixed
 
 get_mempolicy01 // mbind01: They're using numa v1 calls which means that all
 versions of Linux / numa as of a few years ago aren't compatible with the API
diff --git a/testcases/kernel/containers/Makefile b/testcases/kernel/containers/Makefile
index 6a7810e..26f1856 100644
--- a/testcases/kernel/containers/Makefile
+++ b/testcases/kernel/containers/Makefile
@@ -26,6 +26,8 @@ FILTER_OUT_DIRS		:= $(LIBDIR)
 
 LIB			:= $(LIBDIR)/libclone.a
 
+LIB			:= -ld
+
 INSTALL_TARGETS		:= *.sh 
 
 $(LIBDIR):
diff --git a/testcases/kernel/containers/netns/check_netns_enabled.c b/testcases/kernel/containers/check_for_unshare.c
similarity index 52%
copy from testcases/kernel/containers/netns/check_netns_enabled.c
copy to testcases/kernel/containers/check_for_unshare.c
index f6add06..06bdfd7 100644
--- a/testcases/kernel/containers/netns/check_netns_enabled.c
+++ b/testcases/kernel/containers/check_for_unshare.c
@@ -13,37 +13,43 @@
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 *
-* Author: Veerendra C <vechandr@in.ibm.com>
+**************************************************************************/
+/*
+* Description:
+* This program verifies the kernel version to be no later than 2.6.16
+* And checks if the unshare() system call is defined using dlsym(),
+* in the Dynamically Linked Libraries.
 *
-* Net namespaces were introduced around 2.6.25.  Kernels before that,
-* assume they are not enabled.  Kernels after that, check for -EINVAL
-* when trying to use CLONE_NEWNET and CLONE_NEWNS.
-***************************************************************************/
-#include <stdio.h>
-#include <sched.h>
-#include "config.h"
-#include "libclone.h"
-#include "linux_syscall_numbers.h"
-#include "test.h"
+* Date : 26-11-2008
+* Author : Veerendra C <vechandr@in.ibm.com>
+*/
 
-char *TCID = "check_netns_enabled";
-int TST_COUNT = 1;
-int TST_TOTAL = 1; 
+#include <stdio.h>
+#include <stdlib.h>
+#include <dlfcn.h>
+#include <linux/version.h>
 
-#ifndef CLONE_NEWNET
-#define CLONE_NEWNET -1
-#endif
+int main(int argc, char **argv)
+{
+	void *handle;
+	void *ret;
+	char *error;
+	if (LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 16))
+	return 1;
 
-#ifndef CLONE_NEWNS
-#define CLONE_NEWNS -1
-#endif
+	handle = dlopen(NULL, RTLD_LAZY);
+	if (!handle) {
+		fprintf(stderr, "%s\n", dlerror());
+		exit(1);
+	}
 
-int
-main()
-{
-	/* Checking if the kernel supports unshare with netns capabilities. */
-        if (syscall(__NR_unshare, CLONE_NEWNET | CLONE_NEWNS) < 0) {
-		tst_resm (TFAIL | TERRNO, "unshare syscall smoke test failed");
+	dlerror();    /* Clear any existing error */
+	ret = dlsym(handle, "unshare");
+	if ((error = dlerror()) != NULL)  {
+		fprintf(stderr, "Error: %s\n", error);
+		exit(1);
 	}
-	tst_exit();
+
+	dlclose(handle);
+	return 0;
 }
diff --git a/testcases/kernel/controllers/freezer/run_freezer.sh b/testcases/kernel/controllers/freezer/run_freezer.sh
index 3baf968..f66e321 100755
--- a/testcases/kernel/controllers/freezer/run_freezer.sh
+++ b/testcases/kernel/controllers/freezer/run_freezer.sh
@@ -69,7 +69,8 @@ function test_setup()
 	export LTPBIN PATH TCID TST_COUNT TST_TOTAL CGROUPS_TESTROOT
 	tst_resm TINFO "Preparing to run: ${P} $@"
 
-	make all
+	# this is not require here
+	#make all
 }
 
 function test_prereqs()
diff --git a/testcases/kernel/syscalls/libevent/Makefile.in b/testcases/kernel/syscalls/libevent/Makefile.in
index d1d9af7..dd0138d 100644
--- a/testcases/kernel/syscalls/libevent/Makefile.in
+++ b/testcases/kernel/syscalls/libevent/Makefile.in
@@ -99,6 +99,7 @@ LIBS = @LIBS@
 libevent_a_DEPENDENCIES =  @LIBOBJS@
 libevent_a_OBJECTS =  event.o buffer.o evbuffer.o
 AR = ar
+AR_FLAGS = cr
 COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
 CCLD = $(CC)
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS) -o $@
@@ -219,7 +220,7 @@ maintainer-clean-compile:
 
 libevent.a: $(libevent_a_OBJECTS) $(libevent_a_DEPENDENCIES)
 	-rm -f libevent.a
-	$(AR) cru libevent.a $(libevent_a_OBJECTS) $(libevent_a_LIBADD)
+	$(AR) $(AR_FLAGS) libevent.a $(libevent_a_OBJECTS) $(libevent_a_LIBADD)
 	$(RANLIB) libevent.a
 
 install-man3:


hooks/post-receive
-- 
ltp

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2010-03-10  5:36 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-10  4:30 [LTP] [Git] ltp updated Rishi kesh K Rajak
2010-03-10  5:18 ` Shi Weihua
2010-03-10  5:30   ` Rishikesh K Rajak
  -- strict thread matches above, loose matches on Subject: below --
2010-03-10  5:36 Rishi kesh K Rajak
2010-03-10  5:35 Rishi kesh K Rajak
2010-03-10  5:34 Rishi kesh K Rajak
2010-03-10  5:32 Rishi kesh K Rajak
2010-03-09 16:23 Rishi kesh K Rajak
2010-03-09 20:47 ` Garrett Cooper
2010-03-10  4:08   ` Rishikesh K Rajak

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox