From: Rishikesh <risrajak@linux.vnet.ibm.com>
To: LTP <ltp-list@lists.sourceforge.net>
Cc: risrajak@in.ibm.com, iranna.ankad@in.ibm.com
Subject: [LTP] [PATCH 2/2] Added check for memory controller ( functional, regression & stress )
Date: Mon, 28 Dec 2009 16:16:25 +0530 [thread overview]
Message-ID: <4B388C81.80903@linux.vnet.ibm.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1 bytes --]
[-- Attachment #2: ltp-mem-enable2.patch --]
[-- Type: text/plain, Size: 2538 bytes --]
commit fe4599d210be37a7d1bb2d6a5523b9e29bbd87e1
Author: Rishikesh K Rajak <rishikesh@rishikesh.in.ibm.com>
Date: Mon Dec 28 15:11:54 2009 +0530
Added check for regression and funcitonal memcg test
diff --git a/testcases/kernel/controllers/memcg/functional/memcg_function_test.sh b/testcases/kernel/controllers/memcg/functional/memcg_function_test.sh
index 003af1c..303661c 100755
--- a/testcases/kernel/controllers/memcg/functional/memcg_function_test.sh
+++ b/testcases/kernel/controllers/memcg/functional/memcg_function_test.sh
@@ -28,8 +28,8 @@ export TCID="memcg_function_test"
export TST_TOTAL=38
export TST_COUNT=0
-grep -w memory /proc/cgroups 2>&1 > /dev/null
-if [ $? -ne 0 ]; then
+if [ `grep -w memory /proc/cgroups | cut -f4` == 0 ]
+then
echo "WARNING:";
echo "Kernel does not support for memory resource controller";
echo "Skipping all memcgroup testcases....";
diff --git a/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh b/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh
index 6bf7c88..0bc3d75 100755
--- a/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh
+++ b/testcases/kernel/controllers/memcg/regression/memcg_regression_test.sh
@@ -33,6 +33,15 @@ if [ "$USER" != root ]; then
exit 0
fi
+if [ `grep -w memory /proc/cgroups | cut -f4` == 0 ]
+then
+ echo "WARNING:";
+ echo "Kernel does not support for memory resource controller";
+ echo "Skipping all memcgroup testcases....";
+ exit 0
+fi
+
+
tst_kvercmp 2 6 30
if [ $? -eq 0 ]; then
tst_brkm TBROK ignored "Test should be run with kernel 2.6.30 or newer"
diff --git a/testcases/kernel/controllers/memcg/stress/memcg_stress_test.sh b/testcases/kernel/controllers/memcg/stress/memcg_stress_test.sh
index 7244a16..c155bf1 100755
--- a/testcases/kernel/controllers/memcg/stress/memcg_stress_test.sh
+++ b/testcases/kernel/controllers/memcg/stress/memcg_stress_test.sh
@@ -28,14 +28,15 @@ export TCID="memcg_stress_test"
export TST_TOTAL=2
export TST_COUNT=0
-grep -w memory /proc/cgroups 2>&1 > /dev/null
-if [ $? -ne 0 ]; then
- echo "WARNING:";
- echo "Kernel does not support for memory resource controller";
- echo "Skipping all memcgroup testcases....";
- exit 0
+if [ `grep -w memory /proc/cgroups | cut -f4` == 0 ]
+then
+ echo "WARNING:";
+ echo "Kernel does not support for memory resource controller";
+ echo "Skipping all memcgroup testcases....";
+ exit 0
fi
+
RUN_TIME=$(( 60 * 60 ))
cleanup()
[-- Attachment #3: Type: text/plain, Size: 390 bytes --]
------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev
[-- Attachment #4: Type: text/plain, Size: 155 bytes --]
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
next reply other threads:[~2009-12-28 10:46 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-28 10:46 Rishikesh [this message]
2009-12-29 9:20 ` [LTP] [PATCH 2/2] Added check for memory controller ( functional, regression & stress ) Li Zefan
2009-12-29 10:03 ` Rishikesh
2009-12-30 4:00 ` Rishikesh
2009-12-30 5:21 ` Li Zefan
2010-01-07 10:46 ` Garrett Cooper
2010-01-07 11:06 ` Subrata Modak
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4B388C81.80903@linux.vnet.ibm.com \
--to=risrajak@linux.vnet.ibm.com \
--cc=iranna.ankad@in.ibm.com \
--cc=ltp-list@lists.sourceforge.net \
--cc=risrajak@in.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.