You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(6) |
Jun
(12) |
Jul
(46) |
Aug
(8) |
Sep
(27) |
Oct
(73) |
Nov
(56) |
Dec
(34) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(36) |
Feb
(33) |
Mar
(50) |
Apr
(66) |
May
(76) |
Jun
(63) |
Jul
(63) |
Aug
(26) |
Sep
(35) |
Oct
(34) |
Nov
(82) |
Dec
(99) |
2003 |
Jan
(152) |
Feb
(76) |
Mar
(146) |
Apr
(156) |
May
(71) |
Jun
(46) |
Jul
(42) |
Aug
(34) |
Sep
(32) |
Oct
(49) |
Nov
(66) |
Dec
(78) |
2004 |
Jan
(76) |
Feb
(48) |
Mar
(25) |
Apr
(78) |
May
(76) |
Jun
(71) |
Jul
(39) |
Aug
(53) |
Sep
(27) |
Oct
(26) |
Nov
(23) |
Dec
(29) |
2005 |
Jan
(53) |
Feb
(41) |
Mar
(48) |
Apr
(36) |
May
(29) |
Jun
(71) |
Jul
(61) |
Aug
(77) |
Sep
(49) |
Oct
(32) |
Nov
(27) |
Dec
(40) |
2006 |
Jan
(23) |
Feb
(48) |
Mar
(24) |
Apr
(31) |
May
(50) |
Jun
(42) |
Jul
(24) |
Aug
(140) |
Sep
(55) |
Oct
(43) |
Nov
(11) |
Dec
(18) |
2007 |
Jan
(15) |
Feb
(20) |
Mar
(99) |
Apr
(110) |
May
(140) |
Jun
(98) |
Jul
(90) |
Aug
(58) |
Sep
(86) |
Oct
(79) |
Nov
(137) |
Dec
(129) |
2008 |
Jan
(277) |
Feb
(321) |
Mar
(285) |
Apr
(373) |
May
(415) |
Jun
(328) |
Jul
(288) |
Aug
(469) |
Sep
(334) |
Oct
(570) |
Nov
(368) |
Dec
(376) |
2009 |
Jan
(401) |
Feb
(317) |
Mar
(373) |
Apr
(309) |
May
(280) |
Jun
(371) |
Jul
(504) |
Aug
(465) |
Sep
(231) |
Oct
(295) |
Nov
(271) |
Dec
(222) |
2010 |
Jan
(313) |
Feb
(231) |
Mar
(251) |
Apr
(166) |
May
(124) |
Jun
(83) |
Jul
(141) |
Aug
(195) |
Sep
(160) |
Oct
(204) |
Nov
(295) |
Dec
(206) |
2011 |
Jan
(262) |
Feb
(176) |
Mar
(168) |
Apr
(217) |
May
(70) |
Jun
(65) |
Jul
(89) |
Aug
(169) |
Sep
(125) |
Oct
(64) |
Nov
(116) |
Dec
(148) |
2012 |
Jan
(343) |
Feb
(352) |
Mar
(205) |
Apr
(151) |
May
(140) |
Jun
(103) |
Jul
(156) |
Aug
(221) |
Sep
(55) |
Oct
(150) |
Nov
(79) |
Dec
(77) |
2013 |
Jan
(95) |
Feb
(78) |
Mar
(157) |
Apr
(213) |
May
(220) |
Jun
(227) |
Jul
(275) |
Aug
(224) |
Sep
(156) |
Oct
(248) |
Nov
(338) |
Dec
(181) |
2014 |
Jan
(165) |
Feb
(299) |
Mar
(338) |
Apr
(315) |
May
(277) |
Jun
(186) |
Jul
(204) |
Aug
(212) |
Sep
(231) |
Oct
(152) |
Nov
(107) |
Dec
(167) |
2015 |
Jan
(197) |
Feb
(182) |
Mar
(135) |
Apr
(167) |
May
(192) |
Jun
(326) |
Jul
(311) |
Aug
(198) |
Sep
(84) |
Oct
(11) |
Nov
(3) |
Dec
(4) |
2016 |
Jan
(1) |
Feb
(1) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
(3) |
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(5) |
Jun
|
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
2021 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
From: Wanlong G. <wan...@gm...> - 2015-09-10 11:50:37
|
On 9/10/15, kamal p <pka...@gm...> wrote: > Hi , > > Can anyone tell me the procedure how to run user defined set of > test-cases(LTP) using runltp with "-f" option by creating command file $ cat >runtest/myset <<EOF # list the cases you like accept01 accept01 accept4_01 accept4_01 access01 access01 access02 access02 EOF $ ./runltp -f myset Thanks, Wanlong Gao > > Regards, > Kamal > |
From: kamal p <pka...@gm...> - 2015-09-10 11:20:38
|
Hi , Can anyone tell me the procedure how to run user defined set of test-cases(LTP) using runltp with "-f" option by creating command file Regards, Kamal |
From: Jan S. <jst...@re...> - 2015-09-10 10:44:19
|
----- Original Message ----- > From: "Cyril Hrubis" <ch...@su...> > To: "Jan Stancek" <jst...@re...> > Cc: ltp...@li... > Sent: Wednesday, 9 September, 2015 3:26:42 PM > Subject: Re: [LTP] [PATCH] mprotect04: fix powerpc crash when copying exec_func > > Hi! > > > > I'm seeing this on RHEL6.7 kernel, I haven't tried latest upstream yet. > > > > > > Ah, you are right, the memory is not touched in the write_null() > > > function at all. > > > > Right, I got confused by "access_ok(VERIFY_READ, buf, count)" > > in vfs_write(), but after reading code and comments it's clear it > > only checks if range _may_ be valid: > > * access_ok: - Checks if a user space pointer is valid > > ... > > * Returns true (nonzero) if the memory block may be valid, false (zero) > > * if it is definitely invalid. > > * > > * Note that, depending on architecture, this function probably just > > * checks that the pointer is in the user space range - after calling > > * this function, memory access functions may still return -EFAULT. > > I do not have further questions. Acked. Pushed. Regards, Jan > > -- > Cyril Hrubis > ch...@su... > |
From: Zeng L. <zen...@cn...> - 2015-09-10 06:24:45
|
Hello, CC: lt...@li... On Thu, 2015-09-10 at 10:07 +0530, kamal p wrote: > Hi, > > I've query which is based on LTP test-cases running. > > these days I've downloaded and installed LTP on my linux host > machine. > while running the test cases using runltp script my system went to > crash after running few testcases. > > why I am facing these problem and Please clarify me anyone with > relevant answer for these same. > As I known, inotify06 would make some system crash caused by a known kernel bug and the bug has been fixed, you can see this url: https://github.com/torvalds/linux/commit/8f2f3eb59dff4ec538de55f2e0592fec85966aab If the issue is inotify06, I suggest that you should remove it before using runltp script. You can just do like: rm -rf <path_to_install_ltp>/testcases/bin/inotify06 Thanks, Zeng > Regards &Thanks, > > Kamal > > ------------------------------------------------------------------------------ > Monitor Your Dynamic Infrastructure at Any Scale With Datadog! > Get real-time metrics from all of your servers, apps and tools > in one place. > SourceForge users - Click here to start your Free Trial of Datadog now! > http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140 > _______________________________________________ > Ltp-list mailing list > Ltp...@li... > https://lists.sourceforge.net/lists/listinfo/ltp-list |
From: Zeng L. <zen...@cn...> - 2015-09-10 06:00:27
|
Hello, CC: lt...@li... On Thu, 2015-09-10 at 01:02 +0000, Cui Bixuan wrote: > Delete unnecessary if in testcase > > Signed-off-by: Cui Bixuan <cui...@hu...> > --- > testcases/kernel/syscalls/rmdir/rmdir05.c | 3 --- > 1 files changed, 0 insertions(+), 3 deletions(-) > > diff --git a/testcases/kernel/syscalls/rmdir/rmdir05.c b/testcases/kernel/syscalls/rmdir/rmdir05.c > index 10037c7..2f0f102 100644 > --- a/testcases/kernel/syscalls/rmdir/rmdir05.c > +++ b/testcases/kernel/syscalls/rmdir/rmdir05.c > @@ -81,9 +81,6 @@ int main(int argc, char **argv) > TEST(rmdir(".")); > > if (TEST_RETURN == -1) { > - } > - > - if (TEST_RETURN == -1) { > if (TEST_ERRNO & (EBUSY | ENOTEMPTY)) { > /* For functionality tests, verify that the > * directory wasn't removed. Good catch. And more cleanup: ---------------------------------------------------------------------------------------- diff --git a/testcases/kernel/syscalls/bind/bind01.c b/testcases/kernel/syscalls/bind/bind01.c index 6a3bc50..54c54c7 100644 --- a/testcases/kernel/syscalls/bind/bind01.c +++ b/testcases/kernel/syscalls/bind/bind01.c @@ -119,10 +119,8 @@ int main(int argc, char *argv[]) TEST(bind (s, tdat[testno].sockaddr, tdat[testno].salen)); - if (TEST_RETURN > 0) { + if (TEST_RETURN > 0) TEST_RETURN = 0; - } else { - } if (TEST_RETURN != tdat[testno].retval || (TEST_RETURN < 0 && TEST_ERRNO != tdat[testno].experrno)) { diff --git a/testcases/kernel/syscalls/mkdir/mkdir01.c b/testcases/kernel/syscalls/mkdir/mkdir01.c index 9839a09..9488dbe 100644 --- a/testcases/kernel/syscalls/mkdir/mkdir01.c +++ b/testcases/kernel/syscalls/mkdir/mkdir01.c @@ -141,8 +141,6 @@ int main(int ac, char **av) TEST(mkdir(bad_addr, 0777)); /* check return code */ - if (TEST_RETURN == -1) { - } if (TEST_RETURN == -1) { if (TEST_ERRNO == EFAULT) { @@ -171,8 +169,6 @@ int main(int ac, char **av) TEST(mkdir(get_high_address(), 0777)); /* check return code */ - if (TEST_RETURN == -1) { - } if (TEST_RETURN == -1) { if (TEST_ERRNO == EFAULT) { diff --git a/testcases/kernel/syscalls/rmdir/rmdir03.c b/testcases/kernel/syscalls/rmdir/rmdir03.c index 8a42058..acdb4e7 100644 --- a/testcases/kernel/syscalls/rmdir/rmdir03.c +++ b/testcases/kernel/syscalls/rmdir/rmdir03.c @@ -246,9 +246,6 @@ void dochild1(void) /* rmdir tstdir2 */ TEST(rmdir(tstdir2)); - if (TEST_ERRNO) { - } - if (TEST_RETURN != -1) { retval = 1; tst_resm(TFAIL, "call succeeded unexpectedly"); @@ -284,9 +281,6 @@ void dochild2(void) /* rmdir tstdir4 */ TEST(rmdir(tstdir4)); - if (TEST_ERRNO) { - } - if (TEST_RETURN != -1) { retval = 1; tst_resm(TFAIL, "call succeeded unexpectedly"); diff --git a/testcases/kernel/syscalls/rmdir/rmdir05.c b/testcases/kernel/syscalls/rmdir/rmdir05.c index 10037c7..cdfca1b 100644 --- a/testcases/kernel/syscalls/rmdir/rmdir05.c +++ b/testcases/kernel/syscalls/rmdir/rmdir05.c @@ -81,9 +81,6 @@ int main(int argc, char **argv) TEST(rmdir(".")); if (TEST_RETURN == -1) { - } - - if (TEST_RETURN == -1) { if (TEST_ERRNO & (EBUSY | ENOTEMPTY)) { /* For functionality tests, verify that the * directory wasn't removed. @@ -125,9 +122,6 @@ int main(int argc, char **argv) TEST(rmdir(bad_addr)); if (TEST_RETURN == -1) { - } - - if (TEST_RETURN == -1) { if (TEST_ERRNO == EFAULT) { tst_resm(TPASS, "rmdir() - path argument points below the minimum allocated address space failed as expected with errno %d : %s", @@ -151,8 +145,6 @@ int main(int argc, char **argv) TEST(rmdir(get_high_address())); - if (TEST_RETURN == -1) { - } if (TEST_RETURN == -1) { if (TEST_ERRNO == EFAULT) { diff --git a/testcases/kernel/syscalls/sched_setscheduler/sched_setscheduler02.c b/testcases/kernel/syscalls/sched_setscheduler/sched_setscheduler02.c index ba0e894..764cb7f 100644 --- a/testcases/kernel/syscalls/sched_setscheduler/sched_setscheduler02.c +++ b/testcases/kernel/syscalls/sched_setscheduler/sched_setscheduler02.c @@ -94,9 +94,6 @@ int main(int ac, char **av) TEST(sched_setscheduler(pid, SCHED_FIFO, ¶m)); - if (TEST_ERRNO) { - } - if (TEST_RETURN != -1) { tst_resm(TFAIL, "sched_setscheduler(2) passed " "with non root priveledges"); diff --git a/testcases/kernel/syscalls/setregid/setregid03.c b/testcases/kernel/syscalls/setregid/setregid03.c index 2a13c72..ea2c0a5 100644 --- a/testcases/kernel/syscalls/setregid/setregid03.c +++ b/testcases/kernel/syscalls/setregid/setregid03.c @@ -154,8 +154,6 @@ int main(int ac, char **av) *test_data[i].eff_gid); flag = -1; } - if (test_ret == -1) { - } gid_verify(test_data[i].exp_real_usr, test_data[i].exp_eff_usr, diff --git a/testcases/kernel/syscalls/setreuid/setreuid03.c b/testcases/kernel/syscalls/setreuid/setreuid03.c index b62098e..2f5bf03 100644 --- a/testcases/kernel/syscalls/setreuid/setreuid03.c +++ b/testcases/kernel/syscalls/setreuid/setreuid03.c @@ -136,8 +136,6 @@ int main(int ac, char **av) *test_data[i].eff_uid); } - if (TEST_RETURN == -1) { - } uid_verify(test_data[i].exp_real_usr, test_data[i].exp_eff_usr, test_data[i].test_msg); diff --git a/testcases/kernel/syscalls/setreuid/setreuid05.c b/testcases/kernel/syscalls/setreuid/setreuid05.c index 39b30f9..073d0ad 100644 --- a/testcases/kernel/syscalls/setreuid/setreuid05.c +++ b/testcases/kernel/syscalls/setreuid/setreuid05.c @@ -137,8 +137,6 @@ int main(int argc, char **argv) *test_data[i].eff_uid); } - if (TEST_RETURN == -1) { - } uid_verify(test_data[i].exp_real_usr, test_data[i].exp_eff_usr, test_data[i].test_msg); diff --git a/testcases/kernel/syscalls/setsockopt/setsockopt01.c b/testcases/kernel/syscalls/setsockopt/setsockopt01.c index f25694a..f7b9e57 100644 --- a/testcases/kernel/syscalls/setsockopt/setsockopt01.c +++ b/testcases/kernel/syscalls/setsockopt/setsockopt01.c @@ -145,9 +145,6 @@ int main(int argc, char *argv[]) tdat[testno].optval, tdat[testno].optlen)); - if (TEST_RETURN == -1) { - } - if (TEST_RETURN != tdat[testno].retval || (TEST_RETURN < 0 && TEST_ERRNO != tdat[testno].experrno)) { diff --git a/testcases/kernel/syscalls/socket/socket01.c b/testcases/kernel/syscalls/socket/socket01.c index f471d8b..eaa7796 100644 --- a/testcases/kernel/syscalls/socket/socket01.c +++ b/testcases/kernel/syscalls/socket/socket01.c @@ -94,10 +94,8 @@ int main(int argc, char *argv[]) for (testno = 0; testno < TST_TOTAL; ++testno) { TEST((s = socket(tdat[testno].domain, tdat[testno].type, tdat[testno].proto))); - if (TEST_RETURN >= 0) { + if (TEST_RETURN >= 0) TEST_RETURN = 0; /* > 0 equivalent */ - } else { - } if (TEST_RETURN != tdat[testno].retval || (TEST_RETURN < 0 && (TEST_ERRNO != tdat[testno].experrno && TEST_ERRNO != EPROTONOSUPPORT))) { /* Change for defect 21065 for kernel change */ tst_resm(TFAIL, "%s ; returned" /* of return code for this test but don't want */ " %d (expected %d), errno %d (expected" /* to break on older kernels */ diff --git a/testcases/kernel/syscalls/socketpair/socketpair01.c b/testcases/kernel/syscalls/socketpair/socketpair01.c index 3a045b7..ca07a5e 100644 --- a/testcases/kernel/syscalls/socketpair/socketpair01.c +++ b/testcases/kernel/syscalls/socketpair/socketpair01.c @@ -106,10 +106,8 @@ int main(int argc, char *argv[]) tdat[testno].type, tdat[testno].proto, tdat[testno].sv))); - if (TEST_RETURN >= 0) { + if (TEST_RETURN >= 0) TEST_RETURN = 0; /* > 0 equivalent */ - } else { - } if (TEST_RETURN != tdat[testno].retval || (TEST_RETURN && (TEST_ERRNO != tdat[testno].experrno ---------------------------------------------------------------------------------------- Thanks, Zeng |
From: Wanlong G. <wan...@gm...> - 2015-09-10 05:48:49
|
On 9/10/15, kamal p <pka...@gm...> wrote: > Hi, > I've query which is based on LTP test-cases running. > these days I've downloaded and installed LTP on my linux host machine. > while running the test cases using runltp script my system went to crash > after running few testcases. > why I am facing these problem and Please clarify me anyone with relevant > answer for these same. It's possible that system crashes by some test case, you can check the LTP result log to see which may cause it. And you can run the specific test case suite under "runtest/" directory using the "-f" option of "runltp". Thanks, Wanlong Gao > Regards &Thanks, > Kamal > |
From: kamal p <pka...@gm...> - 2015-09-10 04:37:08
|
Hi, I've query which is based on LTP test-cases running. these days I've downloaded and installed LTP on my linux host machine. while running the test cases using runltp script my system went to crash after running few testcases. why I am facing these problem and Please clarify me anyone with relevant answer for these same. Regards &Thanks, Kamal |
From: Wanlong G. <wan...@gm...> - 2015-09-10 03:34:14
|
On 9/9/15, Cyril Hrubis <ch...@su...> wrote: > Good news everyone, > the Italian Linux Society (ILS - www.ils.org) members are kind enough to > support us with mailing list on lt...@li.... I've send an > invitation to the list to everyone subscribed to this list. I would like > to wait for a few days for everyone to subscribe to the new list and > then we will move the discusssion there. Great news! Cheers, Wanlong Gao > > -- > Cyril Hrubis > ch...@su... > > ------------------------------------------------------------------------------ > Monitor Your Dynamic Infrastructure at Any Scale With Datadog! > Get real-time metrics from all of your servers, apps and tools > in one place. > SourceForge users - Click here to start your Free Trial of Datadog now! > http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140 > _______________________________________________ > Ltp-list mailing list > Ltp...@li... > https://lists.sourceforge.net/lists/listinfo/ltp-list > |
From: Cui B. <cui...@hu...> - 2015-09-10 01:02:44
|
Delete unnecessary if in testcase Signed-off-by: Cui Bixuan <cui...@hu...> --- testcases/kernel/syscalls/rmdir/rmdir05.c | 3 --- 1 files changed, 0 insertions(+), 3 deletions(-) diff --git a/testcases/kernel/syscalls/rmdir/rmdir05.c b/testcases/kernel/syscalls/rmdir/rmdir05.c index 10037c7..2f0f102 100644 --- a/testcases/kernel/syscalls/rmdir/rmdir05.c +++ b/testcases/kernel/syscalls/rmdir/rmdir05.c @@ -81,9 +81,6 @@ int main(int argc, char **argv) TEST(rmdir(".")); if (TEST_RETURN == -1) { - } - - if (TEST_RETURN == -1) { if (TEST_ERRNO & (EBUSY | ENOTEMPTY)) { /* For functionality tests, verify that the * directory wasn't removed. -- 1.6.0.2 |
From: Cedric H. <ch...@su...> - 2015-09-09 14:13:01
|
Signed-off-by: Cedric Hnyda <ch...@su...> --- runtest/controllers | 197 ++++++++++++++++++++- .../controllers/cgroup_fj/cgroup_fj_function.sh | 14 +- .../controllers/cgroup_fj/cgroup_fj_function2.sh | 15 +- .../controllers/cgroup_fj/cgroup_fj_stress.sh | 19 +- .../controllers/cgroup_fj/cgroup_fj_testcases.sh | 194 -------------------- .../controllers/cgroup_fj/cgroup_fj_utility.sh | 76 ++++---- .../controllers/cgroup_fj/run_cgroup_test_fj.sh | 82 ++++----- 7 files changed, 295 insertions(+), 302 deletions(-) delete mode 100644 testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh diff --git a/runtest/controllers b/runtest/controllers index 7ec8ab2..6a819a1 100644 --- a/runtest/controllers +++ b/runtest/controllers @@ -10,7 +10,202 @@ memcg_use_hierarchy memcg_use_hierarchy_test.sh memcg_usage_in_bytes memcg_usage_in_bytes_test.sh memcg_stress memcg_stress_test.sh memcg_control PAGESIZE=$(mem_process -p);memcg_control_test.sh $PAGESIZE $PAGESIZE $((PAGESIZE * 2)) -cgroup_fj run_cgroup_test_fj.sh + +function_debug_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 1 +function_debug_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug no yes 1 yes 2 3 2 1 +function_debug_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 2 yes 2 3 2 1 +function_debug_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 1 +function_debug_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 4 yes 2 3 2 1 +function_debug_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 5 yes 2 3 2 1 +function_debug_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 6 yes 2 3 2 1 +function_debug_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 7 yes 2 3 2 1 +function_debug_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 8 yes 2 3 2 1 +function_cpuset_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 1 yes 2 3 2 1 +function_cpuset_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset no yes 1 yes 2 3 2 1 +function_cpuset_yes_no_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes no 1 yes 2 3 2 1 +function_cpuset_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 2 yes 2 3 2 1 +function_cpuset_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 3 yes 2 3 2 1 +function_cpuset_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 4 yes 2 3 2 1 +function_cpuset_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 5 yes 2 3 2 1 +function_cpuset_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 6 yes 2 3 2 1 +function_cpuset_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 7 yes 2 3 2 1 +function_cpuset_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 8 yes 2 3 2 1 +function_ns_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 1 yes 2 3 2 1 +function_ns_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function ns no yes 1 yes 2 3 2 1 +function_ns_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 2 yes 2 3 2 1 +function_ns_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 3 yes 2 3 2 1 +function_ns_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 4 yes 2 3 2 1 +function_ns_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 5 yes 2 3 2 1 +function_ns_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 6 yes 2 3 2 1 +function_ns_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 7 yes 2 3 2 1 +function_ns_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 8 yes 2 3 2 1 +function_cpu_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 1 yes 2 3 2 1 +function_cpu_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu no yes 1 yes 2 3 2 1 +function_cpu_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 2 yes 2 3 2 1 +function_cpu_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 3 yes 2 3 2 1 +function_cpu_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 4 yes 2 3 2 1 +function_cpu_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 5 yes 2 3 2 1 +function_cpu_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 6 yes 2 3 2 1 +function_cpu_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 7 yes 2 3 2 1 +function_cpu_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 8 yes 2 3 2 1 +function_cpuacct_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 1 yes 2 3 2 1 +function_cpuacct_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct no yes 1 yes 2 3 2 1 +function_cpuacct_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 2 yes 2 3 2 1 +function_cpuacct_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 3 yes 2 3 2 1 +function_cpuacct_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 4 yes 2 3 2 1 +function_cpuacct_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 5 yes 2 3 2 1 +function_cpuacct_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 6 yes 2 3 2 1 +function_cpuacct_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 7 yes 2 3 2 1 +function_cpuacct_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 8 yes 2 3 2 1 +function_memory_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 1 yes 2 3 2 1 +function_memory_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function memory no yes 1 yes 2 3 2 1 +function_memory_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 2 yes 2 3 2 1 +function_memory_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 3 yes 2 3 2 1 +function_memory_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 4 yes 2 3 2 1 +function_memory_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 5 yes 2 3 2 1 +function_memory_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 6 yes 2 3 2 1 +function_memory_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 7 yes 2 3 2 1 +function_memory_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 8 yes 2 3 2 1 +function_all_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 1 yes 2 3 2 1 +function_all_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function all no yes 1 yes 2 3 2 1 +function_all_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 2 yes 2 3 2 1 +function_all_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 3 yes 2 3 2 1 +function_all_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 4 yes 2 3 2 1 +function_all_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 5 yes 2 3 2 1 +function_all_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 6 yes 2 3 2 1 +function_all_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 7 yes 2 3 2 1 +function_all_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 8 yes 2 3 2 1 +function_none_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function none yes yes 1 yes 2 3 2 1 +function_debug,debug_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 1 yes 2 3 2 1 +function_debug,debug_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug no yes 1 yes 2 3 2 1 +function_debug,debug_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 2 yes 2 3 2 1 +function_debug,debug_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 3 yes 2 3 2 1 +function_debug,debug_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 4 yes 2 3 2 1 +function_debug,debug_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 5 yes 2 3 2 1 +function_debug,debug_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 6 yes 2 3 2 1 +function_debug,debug_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 7 yes 2 3 2 1 +function_debug,debug_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 8 yes 2 3 2 1 +function_nonexistent_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function nonexistent yes yes 1 yes 2 3 2 1 +function_freezer_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 1 yes 2 3 2 1 +function_freezer_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer no yes 1 yes 2 3 2 1 +function_freezer_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 2 yes 2 3 2 1 +function_freezer_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 3 yes 2 3 2 1 +function_freezer_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 4 yes 2 3 2 1 +function_freezer_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 5 yes 2 3 2 1 +function_freezer_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 6 yes 2 3 2 1 +function_freezer_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 7 yes 2 3 2 1 +function_freezer_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 8 yes 2 3 2 1 +function_devices_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 1 yes 2 3 2 1 +function_devices_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function devices no yes 1 yes 2 3 2 1 +function_devices_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 2 yes 2 3 2 1 +function_devices_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 3 yes 2 3 2 1 +function_devices_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 4 yes 2 3 2 1 +function_devices_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 5 yes 2 3 2 1 +function_devices_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 6 yes 2 3 2 1 +function_devices_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 7 yes 2 3 2 1 +function_devices_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 8 yes 2 3 2 1 +function_debug_yes_yes_1_yes_1_2_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 1 2 1 1 +function_debug_yes_yes_1_yes_2_2_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 2 1 1 +function_debug_yes_yes_1_yes_2_3_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 1 1 +function_debug_yes_yes_1_yes_2_5_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 5 1 1 +function_debug_yes_yes_1_yes_3_1_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 3 1 1 1 +function_debug_yes_yes_1_yes_3_2_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 3 2 1 1 +function_debug_yes_yes_1_yes_3_4_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 3 4 1 1 +function_debug_yes_yes_1_yes_4_3_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 4 3 1 1 +function_debug_yes_yes_1_yes_4_5_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 4 5 1 1 +function_debug_yes_yes_1_no_1_1_1_1 run_cgroup_test_fj.sh function debug yes yes 1 no 1 1 1 1 +function_debug_yes_yes_1_yes_1_1_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 1 1 1 1 +function_debug_yes_yes_1_yes_1_3_2_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 1 3 2 1 +function_debug_yes_yes_1_yes_2_3_2_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 2 +function_debug_yes_yes_1_yes_2_3_2_3 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 3 +function_debug_yes_yes_1_yes_2_3_2_4 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 4 +function_debug_yes_yes_1_yes_2_3_2_5 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 5 +function_debug_yes_yes_1_yes_2_3_2_6 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 6 +function_debug_yes_yes_1_yes_2_3_2_7 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 7 +function_debug_yes_yes_1_yes_2_3_3_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 3 2 +function_debug_yes_yes_1_yes_2_3_4_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 4 2 +function_debug_yes_yes_1_yes_2_3_5_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 5 2 +function_debug_yes_yes_1_yes_2_3_6_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 6 2 +function_debug_yes_yes_1_yes_2_3_7_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 7 2 +function_debug_yes_yes_2_yes_2_3_2_2 run_cgroup_test_fj.sh function debug yes yes 2 yes 2 3 2 2 +function_debug_yes_yes_3_yes_2_3_1_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 1 1 +function_debug_yes_yes_3_yes_2_3_1_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 1 2 +function_debug_yes_yes_3_yes_2_3_1_3 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 1 3 +function_debug_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 1 +function_debug_yes_yes_3_yes_2_3_2_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 2 +function_debug_yes_yes_3_yes_2_3_2_3 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 3 +function_debug_yes_yes_3_yes_2_3_2_4 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 4 +function_debug_yes_yes_3_yes_2_3_2_5 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 5 +function_debug_yes_yes_3_yes_2_3_2_6 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 6 +function_debug_yes_yes_3_yes_2_3_2_7 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 7 +function_debug_yes_yes_3_yes_2_3_3_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 3 1 +function_debug_yes_yes_3_yes_2_3_3_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 3 2 +function_debug_yes_yes_3_yes_2_3_3_3 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 3 3 +function_debug_yes_yes_3_yes_2_3_4_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 4 2 +function_debug_yes_yes_3_yes_2_3_5_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 5 2 +function_debug_yes_yes_3_yes_2_3_6_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 6 2 +function_debug_yes_yes_3_yes_2_3_7_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 7 2 +function2_1 run_cgroup_test_fj.sh function2 1 +function2_2 run_cgroup_test_fj.sh function2 2 +function2_3 run_cgroup_test_fj.sh function2 3 +function2_4 run_cgroup_test_fj.sh function2 4 +function2_5 run_cgroup_test_fj.sh function2 5 +function2_6 run_cgroup_test_fj.sh function2 6 +function2_7 run_cgroup_test_fj.sh function2 7 +function2_8 run_cgroup_test_fj.sh function2 8 +function2_9 run_cgroup_test_fj.sh function2 9 +function2_10 run_cgroup_test_fj.sh function2 10 +function2_11 run_cgroup_test_fj.sh function2 11 +function2_12 run_cgroup_test_fj.sh function2 12 +function2_13 run_cgroup_test_fj.sh function2 13 +stress_debug_100_1_1_1 run_cgroup_test_fj.sh stress debug 100 1 1 1 +stress_cpuset_100_1_1_1 run_cgroup_test_fj.sh stress cpuset 100 1 1 1 +stress_ns_100_1_1_1 run_cgroup_test_fj.sh stress ns 100 1 1 1 +stress_cpu_100_1_1_1 run_cgroup_test_fj.sh stress cpu 100 1 1 1 +stress_cpuacct_100_1_1_1 run_cgroup_test_fj.sh stress cpuacct 100 1 1 1 +stress_memory_100_1_1_1 run_cgroup_test_fj.sh stress memory 100 1 1 1 +stress_all_100_1_1_1 run_cgroup_test_fj.sh stress all 100 1 1 1 +stress_debug_1_1_1_2 run_cgroup_test_fj.sh stress debug 1 1 1 2 +stress_debug_1_1_100_1 run_cgroup_test_fj.sh stress debug 1 1 100 1 +stress_debug_1_1_100_2 run_cgroup_test_fj.sh stress debug 1 1 100 2 +stress_debug_1_1_100_3 run_cgroup_test_fj.sh stress debug 1 1 100 3 +stress_debug_1_100_1_1 run_cgroup_test_fj.sh stress debug 1 100 1 1 +stress_debug_1_100_1_2 run_cgroup_test_fj.sh stress debug 1 100 1 2 +stress_debug_1_100_1_3 run_cgroup_test_fj.sh stress debug 1 100 1 3 +stress_debug_1_100_100_1 run_cgroup_test_fj.sh stress debug 1 100 100 1 +stress_debug_1_100_100_2 run_cgroup_test_fj.sh stress debug 1 100 100 2 +stress_cpuset_1_1_1_2 run_cgroup_test_fj.sh stress cpuset 1 1 1 2 +stress_cpuset_1_1_100_1 run_cgroup_test_fj.sh stress cpuset 1 1 100 1 +stress_cpuset_1_1_100_2 run_cgroup_test_fj.sh stress cpuset 1 1 100 2 +stress_cpuset_1_1_100_3 run_cgroup_test_fj.sh stress cpuset 1 1 100 3 +stress_cpuset_1_100_1_1 run_cgroup_test_fj.sh stress cpuset 1 100 1 1 +stress_cpuset_1_100_1_2 run_cgroup_test_fj.sh stress cpuset 1 100 1 2 +stress_cpuset_1_100_1_3 run_cgroup_test_fj.sh stress cpuset 1 100 1 3 +stress_cpuset_1_100_100_1 run_cgroup_test_fj.sh stress cpuset 1 100 100 1 +stress_cpuset_1_100_100_2 run_cgroup_test_fj.sh stress cpuset 1 100 100 2 +stress_cpu_1_1_1_2 run_cgroup_test_fj.sh stress cpu 1 1 1 2 +stress_cpu_1_100_1_1 run_cgroup_test_fj.sh stress cpu 1 100 1 1 +stress_cpu_1_100_1_2 run_cgroup_test_fj.sh stress cpu 1 100 1 2 +stress_cpu_1_100_1_3 run_cgroup_test_fj.sh stress cpu 1 100 1 3 +stress_cpuacct_1_1_1_2 run_cgroup_test_fj.sh stress cpuacct 1 1 1 2 +stress_cpuacct_1_1_100_1 run_cgroup_test_fj.sh stress cpuacct 1 1 100 1 +stress_cpuacct_1_1_100_2 run_cgroup_test_fj.sh stress cpuacct 1 1 100 2 +stress_cpuacct_1_1_100_3 run_cgroup_test_fj.sh stress cpuacct 1 1 100 3 +stress_cpuacct_1_100_1_1 run_cgroup_test_fj.sh stress cpuacct 1 100 1 1 +stress_cpuacct_1_100_1_2 run_cgroup_test_fj.sh stress cpuacct 1 100 1 2 +stress_cpuacct_1_100_1_3 run_cgroup_test_fj.sh stress cpuacct 1 100 1 3 +stress_cpuacct_1_100_100_1 run_cgroup_test_fj.sh stress cpuacct 1 100 100 1 +stress_cpuacct_1_100_100_2 run_cgroup_test_fj.sh stress cpuacct 1 100 100 2 +stress_memory_1_1_1_2 run_cgroup_test_fj.sh stress memory 1 1 1 2 +stress_memory_1_1_100_1 run_cgroup_test_fj.sh stress memory 1 1 100 1 +stress_memory_1_1_100_2 run_cgroup_test_fj.sh stress memory 1 1 100 2 +stress_memory_1_1_100_3 run_cgroup_test_fj.sh stress memory 1 1 100 3 +stress_memory_1_100_1_1 run_cgroup_test_fj.sh stress memory 1 100 1 1 +stress_memory_1_100_1_2 run_cgroup_test_fj.sh stress memory 1 100 1 2 +stress_memory_1_100_1_3 run_cgroup_test_fj.sh stress memory 1 100 1 3 +stress_memory_1_100_100_1 run_cgroup_test_fj.sh stress memory 1 100 100 1 +stress_memory_1_100_100_2 run_cgroup_test_fj.sh stress memory 1 100 100 2 + controllers test_controllers.sh cpuset_base_ops cpuset_base_ops_testset.sh diff --git a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function.sh b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function.sh index 673a942..2202708 100755 --- a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function.sh +++ b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function.sh @@ -120,23 +120,21 @@ usage() } export TESTROOT=`pwd` -if [ "$LOGFILE" = "" ]; then - LOGFILE="/dev/stdout" -fi + export TMPFILE=$TESTROOT/tmp_tasks . $TESTROOT/cgroup_fj_utility.sh ########################## main ####################### if [ "$#" -ne "9" ]; then - echo "ERROR: Wrong inputed parameter..Exiting test" >> $LOGFILE; + echo "ERROR: Wrong inputed parameter..Exiting test"; usage; exit -1; fi -echo "-------------------------------------------------------------------------" >> $LOGFILE -echo "case no : $CASENO1" >> $LOGFILE -echo `date` >> $LOGFILE +echo "-------------------------------------------------------------------------" +echo "case no : $CASENO1" +echo `date` check_para; if [ $? -ne 0 ]; then @@ -145,7 +143,7 @@ if [ $? -ne 0 ]; then fi setup; -echo "INFO: now we begin to test no $CASENO1 ..." >> $LOGFILE +echo "INFO: now we begin to test no $CASENO1 ..." mount_cgroup; diff --git a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function2.sh b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function2.sh index 2b47df1..57d131d 100755 --- a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function2.sh +++ b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_function2.sh @@ -10,7 +10,7 @@ ## (at your option) any later version. ## ## ## ## This program is distributed in the hope that it will be useful, but ## -## WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY ## +## WITHOUT ANY WARRANTY; without evsen the implied warranty of MERCHANTABILITY ## ## or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ## ## for more details. ## ## ## @@ -45,14 +45,11 @@ usage() exit_parameter() { - echo "ERROR: Wrong inputed parameter..Exiting test" >> $LOGFILE + echo "ERROR: Wrong inputed parameter..Exiting test" exit -1; } export TESTROOT=`pwd` -if [ "$LOGFILE" = "" ]; then - LOGFILE="/dev/stdout" -fi export TMPFILE=$TESTROOT/tmp_tasks . $TESTROOT/cgroup_fj_utility.sh @@ -303,14 +300,14 @@ if [ "$#" -ne "1" ] || [ $caseno -lt 1 ] || [ $caseno -gt 13 ]; then exit_parameter; fi -echo "-------------------------------------------------------------------------" >> $LOGFILE -echo "case no : $CASENO1" >> $LOGFILE -echo `date` >> $LOGFILE +echo "-------------------------------------------------------------------------" +echo "case no : $CASENO1" +echo `date` exist_subsystem "debug" setup; -echo "INFO: now we begin to test no $CASENO1 ..." >> $LOGFILE +echo "INFO: now we begin to test no $CASENO1 ..." if [ $caseno -lt 3 ] || [ $caseno -gt 6 ]; then mount_cgroup; diff --git a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_stress.sh b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_stress.sh index 972a717..fd9fa2a 100755 --- a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_stress.sh +++ b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_stress.sh @@ -76,14 +76,11 @@ usage() exit_parameter() { - echo "ERROR: Wrong inputed parameter..Exiting test" >> $LOGFILE + echo "ERROR: Wrong inputed parameter..Exiting test" exit -1; } export TESTROOT=`pwd` -if [ "$LOGFILE" = "" ]; then - LOGFILE="/dev/stdout" -fi export TMPFILE=$TESTROOT/tmp_tasks . $TESTROOT/cgroup_fj_utility.sh @@ -150,13 +147,13 @@ case $subgroup_hiers in esac ########################## main ####################### -echo "-------------------------------------------------------------------------" >> $LOGFILE -echo "case no : $CASENO2" >> $LOGFILE -echo `date` >> $LOGFILE +echo "-------------------------------------------------------------------------" +echo "case no : $CASENO2" +echo `date` setup; -echo "INFO: now we begin to stress test no $CASENO2 ..." >> $LOGFILE +echo "INFO: now we begin to stress test no $CASENO2 ..." mount_cgroup; @@ -209,9 +206,9 @@ if [ $mount_times -ne 1 ]; then fi fi let "count = $count + 1" - echo "$count .. OK" >> $LOGFILE + echo "$count .. OK" done - echo "...executed $count times" >> $LOGFILE + echo "...executed $count times" else get_subgroup_path2 $subgroup_hiers count=0 @@ -242,7 +239,7 @@ else pathes[$count]="$cur_subgroup_path1""$cur_subgroup_path2" done done - echo "...mkdired $count times" >> $LOGFILE + echo "...mkdired $count times" sleep 1 diff --git a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh deleted file mode 100644 index a03918a..0000000 --- a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh +++ /dev/null @@ -1,194 +0,0 @@ -function debug yes yes 1 yes 2 3 2 1 -function debug no yes 1 yes 2 3 2 1 -function debug yes yes 2 yes 2 3 2 1 -function debug yes yes 3 yes 2 3 2 1 -function debug yes yes 4 yes 2 3 2 1 -function debug yes yes 5 yes 2 3 2 1 -function debug yes yes 6 yes 2 3 2 1 -function debug yes yes 7 yes 2 3 2 1 -function debug yes yes 8 yes 2 3 2 1 -function cpuset yes yes 1 yes 2 3 2 1 -function cpuset no yes 1 yes 2 3 2 1 -function cpuset yes no 1 yes 2 3 2 1 -function cpuset yes yes 2 yes 2 3 2 1 -function cpuset yes yes 3 yes 2 3 2 1 -function cpuset yes yes 4 yes 2 3 2 1 -function cpuset yes yes 5 yes 2 3 2 1 -function cpuset yes yes 6 yes 2 3 2 1 -function cpuset yes yes 7 yes 2 3 2 1 -function cpuset yes yes 8 yes 2 3 2 1 -function ns yes yes 1 yes 2 3 2 1 -function ns no yes 1 yes 2 3 2 1 -function ns yes yes 2 yes 2 3 2 1 -function ns yes yes 3 yes 2 3 2 1 -function ns yes yes 4 yes 2 3 2 1 -function ns yes yes 5 yes 2 3 2 1 -function ns yes yes 6 yes 2 3 2 1 -function ns yes yes 7 yes 2 3 2 1 -function ns yes yes 8 yes 2 3 2 1 -function cpu yes yes 1 yes 2 3 2 1 -function cpu no yes 1 yes 2 3 2 1 -function cpu yes yes 2 yes 2 3 2 1 -function cpu yes yes 3 yes 2 3 2 1 -function cpu yes yes 4 yes 2 3 2 1 -function cpu yes yes 5 yes 2 3 2 1 -function cpu yes yes 6 yes 2 3 2 1 -function cpu yes yes 7 yes 2 3 2 1 -function cpu yes yes 8 yes 2 3 2 1 -function cpuacct yes yes 1 yes 2 3 2 1 -function cpuacct no yes 1 yes 2 3 2 1 -function cpuacct yes yes 2 yes 2 3 2 1 -function cpuacct yes yes 3 yes 2 3 2 1 -function cpuacct yes yes 4 yes 2 3 2 1 -function cpuacct yes yes 5 yes 2 3 2 1 -function cpuacct yes yes 6 yes 2 3 2 1 -function cpuacct yes yes 7 yes 2 3 2 1 -function cpuacct yes yes 8 yes 2 3 2 1 -function memory yes yes 1 yes 2 3 2 1 -function memory no yes 1 yes 2 3 2 1 -function memory yes yes 2 yes 2 3 2 1 -function memory yes yes 3 yes 2 3 2 1 -function memory yes yes 4 yes 2 3 2 1 -function memory yes yes 5 yes 2 3 2 1 -function memory yes yes 6 yes 2 3 2 1 -function memory yes yes 7 yes 2 3 2 1 -function memory yes yes 8 yes 2 3 2 1 -function all yes yes 1 yes 2 3 2 1 -function all no yes 1 yes 2 3 2 1 -function all yes yes 2 yes 2 3 2 1 -function all yes yes 3 yes 2 3 2 1 -function all yes yes 4 yes 2 3 2 1 -function all yes yes 5 yes 2 3 2 1 -function all yes yes 6 yes 2 3 2 1 -function all yes yes 7 yes 2 3 2 1 -function all yes yes 8 yes 2 3 2 1 -function none yes yes 1 yes 2 3 2 1 -function debug,debug yes yes 1 yes 2 3 2 1 -function debug,debug no yes 1 yes 2 3 2 1 -function debug,debug yes yes 2 yes 2 3 2 1 -function debug,debug yes yes 3 yes 2 3 2 1 -function debug,debug yes yes 4 yes 2 3 2 1 -function debug,debug yes yes 5 yes 2 3 2 1 -function debug,debug yes yes 6 yes 2 3 2 1 -function debug,debug yes yes 7 yes 2 3 2 1 -function debug,debug yes yes 8 yes 2 3 2 1 -function nonexistent yes yes 1 yes 2 3 2 1 -function freezer yes yes 1 yes 2 3 2 1 -function freezer no yes 1 yes 2 3 2 1 -function freezer yes yes 2 yes 2 3 2 1 -function freezer yes yes 3 yes 2 3 2 1 -function freezer yes yes 4 yes 2 3 2 1 -function freezer yes yes 5 yes 2 3 2 1 -function freezer yes yes 6 yes 2 3 2 1 -function freezer yes yes 7 yes 2 3 2 1 -function freezer yes yes 8 yes 2 3 2 1 -function devices yes yes 1 yes 2 3 2 1 -function devices no yes 1 yes 2 3 2 1 -function devices yes yes 2 yes 2 3 2 1 -function devices yes yes 3 yes 2 3 2 1 -function devices yes yes 4 yes 2 3 2 1 -function devices yes yes 5 yes 2 3 2 1 -function devices yes yes 6 yes 2 3 2 1 -function devices yes yes 7 yes 2 3 2 1 -function devices yes yes 8 yes 2 3 2 1 -function debug yes yes 1 yes 1 2 1 1 -function debug yes yes 1 yes 2 2 1 1 -function debug yes yes 1 yes 2 3 1 1 -function debug yes yes 1 yes 2 5 1 1 -function debug yes yes 1 yes 3 1 1 1 -function debug yes yes 1 yes 3 2 1 1 -function debug yes yes 1 yes 3 4 1 1 -function debug yes yes 1 yes 4 3 1 1 -function debug yes yes 1 yes 4 5 1 1 -function debug yes yes 1 no 1 1 1 1 -function debug yes yes 1 yes 1 1 1 1 -function debug yes yes 1 yes 1 3 2 1 -function debug yes yes 1 yes 2 3 2 2 -function debug yes yes 1 yes 2 3 2 3 -function debug yes yes 1 yes 2 3 2 4 -function debug yes yes 1 yes 2 3 2 5 -function debug yes yes 1 yes 2 3 2 6 -function debug yes yes 1 yes 2 3 2 7 -function debug yes yes 1 yes 2 3 3 2 -function debug yes yes 1 yes 2 3 4 2 -function debug yes yes 1 yes 2 3 5 2 -function debug yes yes 1 yes 2 3 6 2 -function debug yes yes 1 yes 2 3 7 2 -function debug yes yes 2 yes 2 3 2 2 -function debug yes yes 3 yes 2 3 1 1 -function debug yes yes 3 yes 2 3 1 2 -function debug yes yes 3 yes 2 3 1 3 -function debug yes yes 3 yes 2 3 2 1 -function debug yes yes 3 yes 2 3 2 2 -function debug yes yes 3 yes 2 3 2 3 -function debug yes yes 3 yes 2 3 2 4 -function debug yes yes 3 yes 2 3 2 5 -function debug yes yes 3 yes 2 3 2 6 -function debug yes yes 3 yes 2 3 2 7 -function debug yes yes 3 yes 2 3 3 1 -function debug yes yes 3 yes 2 3 3 2 -function debug yes yes 3 yes 2 3 3 3 -function debug yes yes 3 yes 2 3 4 2 -function debug yes yes 3 yes 2 3 5 2 -function debug yes yes 3 yes 2 3 6 2 -function debug yes yes 3 yes 2 3 7 2 -function2 1 -function2 2 -function2 3 -function2 4 -function2 5 -function2 6 -function2 7 -function2 8 -function2 9 -function2 10 -function2 11 -function2 12 -function2 13 -stress debug 100 1 1 1 -stress cpuset 100 1 1 1 -stress ns 100 1 1 1 -stress cpu 100 1 1 1 -stress cpuacct 100 1 1 1 -stress memory 100 1 1 1 -stress all 100 1 1 1 -stress debug 1 1 1 2 -stress debug 1 1 100 1 -stress debug 1 1 100 2 -stress debug 1 1 100 3 -stress debug 1 100 1 1 -stress debug 1 100 1 2 -stress debug 1 100 1 3 -stress debug 1 100 100 1 -stress debug 1 100 100 2 -stress cpuset 1 1 1 2 -stress cpuset 1 1 100 1 -stress cpuset 1 1 100 2 -stress cpuset 1 1 100 3 -stress cpuset 1 100 1 1 -stress cpuset 1 100 1 2 -stress cpuset 1 100 1 3 -stress cpuset 1 100 100 1 -stress cpuset 1 100 100 2 -stress cpu 1 1 1 2 -stress cpu 1 100 1 1 -stress cpu 1 100 1 2 -stress cpu 1 100 1 3 -stress cpuacct 1 1 1 2 -stress cpuacct 1 1 100 1 -stress cpuacct 1 1 100 2 -stress cpuacct 1 1 100 3 -stress cpuacct 1 100 1 1 -stress cpuacct 1 100 1 2 -stress cpuacct 1 100 1 3 -stress cpuacct 1 100 100 1 -stress cpuacct 1 100 100 2 -stress memory 1 1 1 2 -stress memory 1 1 100 1 -stress memory 1 1 100 2 -stress memory 1 1 100 3 -stress memory 1 100 1 1 -stress memory 1 100 1 2 -stress memory 1 100 1 3 -stress memory 1 100 100 1 -stress memory 1 100 100 2 \ No newline at end of file diff --git a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_utility.sh b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_utility.sh index 1e2e521..75c0dcb 100755 --- a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_utility.sh +++ b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_utility.sh @@ -228,7 +228,7 @@ get_release_agent() do_exit() { if [ "$#" -ne "3" ]; then - echo "ERROR: exit failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: exit failed,your parameter is wrong..Exiting test" exit -1 fi @@ -238,7 +238,7 @@ do_exit() if [ $exit_status -eq 0 ] ;then if [ $expectted -lt 1 ]; then - echo " against with expectted" >> $LOGFILE + echo " against with expectted" if [ $exit_here -ge 1 ]; then cleanup; exit -1 @@ -246,7 +246,7 @@ do_exit() fi else if [ $expectted -ge 1 ]; then - echo " against with expectted" >> $LOGFILE + echo " against with expectted" if [ $exit_here -ge 1 ]; then cleanup; exit -1 @@ -263,7 +263,7 @@ do_exit() do_echo() { if [ "$#" -ne "4" ]; then - echo "ERROR: echo failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: echo failed,your parameter is wrong..Exiting test" exit -1 fi @@ -274,20 +274,20 @@ do_echo() if [ $no_debug -ne 1 ]; then if [ $expectted -ge 1 ]; then - echo "\"echo $value > $target\" (expectted: success)" >> $LOGFILE + echo "\"echo $value > $target\" (expectted: success)" else - echo "\"echo $value > $target\" (expectted: fail)" >> $LOGFILE + echo "\"echo $value > $target\" (expectted: fail)" fi fi - `echo $value > $target` >> $LOGFILE 2>&1 + `echo $value > $target` do_exit $exit_here $expectted $?; } do_mkdir() { if [ "$#" -ne "3" ] && [ "$#" -ne "4" ]; then - echo "ERROR: mkdir failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: mkdir failed,your parameter is wrong..Exiting test" exit -1 fi @@ -301,9 +301,9 @@ do_mkdir() if [ $no_debug -ne 1 ]; then if [ $expectted -ge 1 ]; then - echo "\"mkdir $target\" (expectted: success)" >> $LOGFILE + echo "\"mkdir $target\" (expectted: success)" else - echo "\"mkdir $target\" (expectted: fail)" >> $LOGFILE + echo "\"mkdir $target\" (expectted: fail)" fi fi @@ -312,9 +312,9 @@ do_mkdir() fi if [ $parents -ne "1" ]; then - mkdir $target >> $LOGFILE 2>&1 + mkdir $target else - mkdir -p $target >> $LOGFILE 2>&1 + mkdir -p $target fi do_exit $exit_here $expectted $?; } @@ -322,7 +322,7 @@ do_mkdir() do_rmdir() { if [ "$#" -lt "3" ]; then - echo "ERROR: rmdir failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: rmdir failed,your parameter is wrong..Exiting test" exit -1 fi @@ -331,26 +331,26 @@ do_rmdir() target=$3 if ! [ -e $target ]; then - echo "INFO: $target is not exist" >> $LOGFILE + echo "INFO: $target is not exist" return fi if [ $no_debug -ne 1 ]; then if [ $expectted -ge 1 ]; then - echo "\"rmdir $target\" (expectted: success)" >> $LOGFILE + echo "\"rmdir $target\" (expectted: success)" else - echo "\"rmdir $target\" (expectted: fail)" >> $LOGFILE + echo "\"rmdir $target\" (expectted: fail)" fi fi - rmdir $3 $4 $5 >> $LOGFILE 2>&1 + rmdir $3 $4 $5 do_exit $exit_here $expectted $?; } do_mount() { if [ "$#" -ne "4" ] && [ "$#" -ne "5" ] ; then - echo "ERROR: mount failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: mount failed,your parameter is wrong..Exiting test" exit -1 fi @@ -365,20 +365,20 @@ do_mount() if [ $no_debug -ne 1 ]; then if [ $expectted -ge 1 ]; then - echo "\"mount -t cgroup $para_o $something $target\" (expectted: success)" >> $LOGFILE + echo "\"mount -t cgroup $para_o $something $target\" (expectted: success)" else - echo "\"mount -t cgroup $para_o $something $target\" (expectted: fail)" >> $LOGFILE + echo "\"mount -t cgroup $para_o $something $target\" (expectted: fail)" fi fi - mount -t cgroup $para_o $something $target >> $LOGFILE 2>&1 + mount -t cgroup $para_o $something $target do_exit $exit_here $expectted $?; } do_umount() { if [ "$#" -ne "3" ]; then - echo "ERROR: umount failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: umount failed,your parameter is wrong..Exiting test" exit -1 fi @@ -388,20 +388,20 @@ do_umount() if [ $no_debug -ne 1 ]; then if [ $expectted -ge 1 ]; then - echo "\"umount $target\" (expectted: success)" >> $LOGFILE + echo "\"umount $target\" (expectted: success)" else - echo "\"umount $target\" (expectted: fail)" >> $LOGFILE + echo "\"umount $target\" (expectted: fail)" fi fi - umount $target >> $LOGFILE 2>&1 + umount $target do_exit $exit_here $expectted $?; } do_mv() { if [ "$#" -ne "4" ]; then - echo "ERROR: mv failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: mv failed,your parameter is wrong..Exiting test" exit -1 fi @@ -412,20 +412,20 @@ do_mv() if [ $no_debug -ne 1 ]; then if [ $expectted -ge 1 ]; then - echo "\"mv $source $target\" (expectted: success)" >> $LOGFILE + echo "\"mv $source $target\" (expectted: success)" else - echo "\"mv $source $target\" (expectted: fail)" >> $LOGFILE + echo "\"mv $source $target\" (expectted: fail)" fi fi - mv $source $target >> $LOGFILE 2>&1 + mv $source $target do_exit $exit_here $expectted $?; } do_kill() { if [ "$#" -ne "4" ]; then - echo "ERROR: kill failed,your parameter is wrong..Exiting test" >> $LOGFILE + echo "ERROR: kill failed,your parameter is wrong..Exiting test" exit -1 fi @@ -440,13 +440,13 @@ do_kill() if [ $no_debug -ne 1 ]; then if [ $expectted -ge 1 ]; then - echo "\"kill -$signo $pid\" (expectted: success)" >> $LOGFILE + echo "\"kill -$signo $pid\" (expectted: success)" else - echo "\"kill -$signo $pid\" (expectted: fail)" >> $LOGFILE + echo "\"kill -$signo $pid\" (expectted: fail)" fi fi - kill -s $signo $pid >> $LOGFILE 2>&1 + kill -s $signo $pid do_exit $exit_here $expectted $?; } @@ -464,7 +464,7 @@ setup() cp -f $TESTROOT/cgroup_fj_release_agent /root chmod a+x /root/cgroup_fj_release_agent else - echo "ERROR: $TESTROOT/cgroup_fj_release_agent isn't exist..Exiting test" >> $LOGFILE + echo "ERROR: $TESTROOT/cgroup_fj_release_agent isn't exist..Exiting test" exit -1; fi @@ -476,7 +476,7 @@ setup() then chmod a+x $TESTROOT/cgroup_fj_proc else - echo "ERROR: $TESTROOT/cgroup_fj_proc isn't exist..Exiting test" >> $LOGFILE + echo "ERROR: $TESTROOT/cgroup_fj_proc isn't exist..Exiting test" exit -1; fi } @@ -484,7 +484,7 @@ setup() cleanup() { if [ $no_debug -ne 1 ]; then - echo "INFO: we now cleanup ..." >> $LOGFILE + echo "INFO: we now cleanup ..." fi export LANG=en_US.UTF-8 @@ -547,7 +547,7 @@ reclaim_foundling() mkdir_subgroup() { if ! [ -e /dev/cgroup ]; then - echo "ERROR: /dev/cgroup isn't exist..Exiting test" >> $LOGFILE + echo "ERROR: /dev/cgroup isn't exist..Exiting test" exit -1; fi @@ -613,7 +613,7 @@ check_para() if [ $ret1 -ne 0 ] || [ $ret2 -ne 0 ] || [ $ret3 -ne 0 ] || [ $ret4 -ne 0 ] || [ $ret5 -ne 0 ] || [ $ret6 -ne 0 ] then - echo "ERROR: Wrong inputed parameter..Exiting test" >> $LOGFILE + echo "ERROR: Wrong inputed parameter..Exiting test" return -1 fi diff --git a/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh b/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh index f0b43b8..c8e698b 100755 --- a/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh +++ b/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh @@ -23,12 +23,21 @@ ################################################################################ cd $LTPROOT/testcases/bin -export TCID="cgroup_test_fj" -export TST_TOTAL=194 + +cnt=1 +for arg; do + if [ $cnt -gt 1 ]; then + NAME+="_" + NAME+=$arg + fi + cnt=$(( $cnt + 1 )) +done + +export TCID=$1$NAME +export TST_TOTAL=1 export TST_COUNT=1 export TESTROOT=`pwd` -export LOGFILE=$LTPROOT/output/cgroup_fj_log_`date +%F`.txt export TMPFILE=$TESTROOT/tmp_tasks export CASENO1=0 export CASENO2=0 @@ -86,47 +95,38 @@ if [ "$SYBSYSCOMPILED" = "" ];then # Warning and exit if all cgroup subsystem ar exit -2; fi -echo "Now, we start the test for cgroup..."; +echo `date` +echo `uname -a` -rm -f $LOGFILE 2>/dev/null -echo `date` > $LOGFILE -echo `uname -a` >> $LOGFILE +echo "" -echo "" >> $LOGFILE -echo "Now, we start the test for basic function of cgroup..." >> $LOGFILE +CASETYPE=$1 +shift +CASECMD=$@ -nlines=`cat cgroup_fj_testcases.sh | wc -l` -for i in `seq 1 $nlines` -do - CASETYPE=`sed -n "$i""p" cgroup_fj_testcases.sh | cut -f1` - CASECMD=`sed -n "$i""p" cgroup_fj_testcases.sh | cut -f2` - echo $CASETYPE | grep "#" - if [ $? -ne 0 ]; then - case $CASETYPE in - "function" ) - : $(( CASENO1 += 1 )) - export CASENO1=$CASENO1 - $TESTROOT/cgroup_fj_function.sh $CASECMD - ;; - "function2" ) - : $(( CASENO1 += 1 )) - export CASENO1=$CASENO1 - $TESTROOT/cgroup_fj_function2.sh $CASECMD - ;; - "stress" ) - : $(( CASENO2 += 1 )) - export CASENO2=$CASENO2 - $TESTROOT/cgroup_fj_stress.sh $CASECMD - ;; - esac +case $CASETYPE in +"function" ) + : $(( CASENO1 += 1 )) + export CASENO1=$CASENO1 + $TESTROOT/cgroup_fj_function.sh $CASECMD + ;; +"function2" ) + : $(( CASENO1 += 1 )) + export CASENO1=$CASENO1 + $TESTROOT/cgroup_fj_function2.sh $CASECMD + ;; +"stress" ) + : $(( CASENO2 += 1 )) + export CASENO2=$CASENO2 + $TESTROOT/cgroup_fj_stress.sh $CASECMD + ;; +esac - ret=$? - if [ $ret -eq 0 ]; then - tst_resm TPASS "case$i(`sed -n "$i""p" cgroup_fj_testcases.sh`) PASS" - elif [ $ret -ne 9 ]; then - tst_resm TFAIL "case$i(`sed -n "$i""p" cgroup_fj_testcases.sh`) FAIL" - fi - fi -done +ret=$? +if [ $ret -eq 0 ]; then + tst_resm TPASS "case$i($CASETYPE$CASECMD) PASS" +elif [ $ret -ne 9 ]; then + tst_resm TFAIL "case$i($CASETYPE $CASECMD) FAIL" +fi exit $ret; -- 2.1.4 |
From: Cyril H. <ch...@su...> - 2015-09-09 13:27:28
|
Hi! > > > I'm seeing this on RHEL6.7 kernel, I haven't tried latest upstream yet. > > > > Ah, you are right, the memory is not touched in the write_null() > > function at all. > > Right, I got confused by "access_ok(VERIFY_READ, buf, count)" > in vfs_write(), but after reading code and comments it's clear it > only checks if range _may_ be valid: > * access_ok: - Checks if a user space pointer is valid > ... > * Returns true (nonzero) if the memory block may be valid, false (zero) > * if it is definitely invalid. > * > * Note that, depending on architecture, this function probably just > * checks that the pointer is in the user space range - after calling > * this function, memory access functions may still return -EFAULT. I do not have further questions. Acked. -- Cyril Hrubis ch...@su... |
From: Jan S. <jst...@re...> - 2015-09-09 13:23:31
|
----- Original Message ----- > From: "Cyril Hrubis" <ch...@su...> > To: "Jan Stancek" <jst...@re...> > Cc: ltp...@li... > Sent: Wednesday, 9 September, 2015 3:09:34 PM > Subject: Re: [LTP] [PATCH] mprotect04: fix powerpc crash when copying exec_func > > Hi! > > It doesn't seem reliable: > > > > open("/dev/null", O_WRONLY|O_CREAT, 0644) = 3 > > write(3, NULL, 1) = 1 > > close(3) = 0 > > > > I'm seeing this on RHEL6.7 kernel, I haven't tried latest upstream yet. > > Ah, you are right, the memory is not touched in the write_null() > function at all. Right, I got confused by "access_ok(VERIFY_READ, buf, count)" in vfs_write(), but after reading code and comments it's clear it only checks if range _may_ be valid: * access_ok: - Checks if a user space pointer is valid ... * Returns true (nonzero) if the memory block may be valid, false (zero) * if it is definitely invalid. * * Note that, depending on architecture, this function probably just * checks that the pointer is in the user space range - after calling * this function, memory access functions may still return -EFAULT. Regards, Jan > > drivers/char/mem.c: > > static ssize_t write_null(struct file *file, const char __user *buf, > size_t count, loff_t *ppos) > { > return count; > } > > -- > Cyril Hrubis > ch...@su... > |
From: Cyril H. <ch...@su...> - 2015-09-09 13:10:24
|
Hi! > It doesn't seem reliable: > > open("/dev/null", O_WRONLY|O_CREAT, 0644) = 3 > write(3, NULL, 1) = 1 > close(3) = 0 > > I'm seeing this on RHEL6.7 kernel, I haven't tried latest upstream yet. Ah, you are right, the memory is not touched in the write_null() function at all. drivers/char/mem.c: static ssize_t write_null(struct file *file, const char __user *buf, size_t count, loff_t *ppos) { return count; } -- Cyril Hrubis ch...@su... |
From: Jan S. <jst...@re...> - 2015-09-09 13:00:49
|
----- Original Message ----- > From: "Cyril Hrubis" <ch...@su...> > To: "Jan Stancek" <jst...@re...> > Cc: ltp...@li... > Sent: Wednesday, 9 September, 2015 2:37:37 PM > Subject: Re: [LTP] [PATCH] mprotect04: fix powerpc crash when copying exec_func > > Hi! > > Testcase tried to copy page size area starting at &exec_func. > > This results in crash on powerpc, because &exec_func is too close > > to end of page and subsequent page is not mapped: > > I was wondering about this problem when I was fixing the test, but could > not actually hit it. > > > -static void *get_func(void *mem) > > +static int page_present(void *p) > > { > > - memcpy(mem, exec_func, getpagesize()); > > + int fd; > > + > > + fd = SAFE_OPEN(cleanup, "page_present", O_WRONLY|O_CREAT, 0644); > > Why don't we use "/dev/null"? It doesn't seem reliable: open("/dev/null", O_WRONLY|O_CREAT, 0644) = 3 write(3, NULL, 1) = 1 close(3) = 0 I'm seeing this on RHEL6.7 kernel, I haven't tried latest upstream yet. Regards, Jan > > > The rest looks good to me. > > -- > Cyril Hrubis > ch...@su... > |
From: Cyril H. <ch...@su...> - 2015-09-09 12:38:23
|
Hi! > Testcase tried to copy page size area starting at &exec_func. > This results in crash on powerpc, because &exec_func is too close > to end of page and subsequent page is not mapped: I was wondering about this problem when I was fixing the test, but could not actually hit it. > -static void *get_func(void *mem) > +static int page_present(void *p) > { > - memcpy(mem, exec_func, getpagesize()); > + int fd; > + > + fd = SAFE_OPEN(cleanup, "page_present", O_WRONLY|O_CREAT, 0644); Why don't we use "/dev/null"? The rest looks good to me. -- Cyril Hrubis ch...@su... |
From: Jan S. <jst...@re...> - 2015-09-09 11:39:29
|
Testcase tried to copy page size area starting at &exec_func. This results in crash on powerpc, because &exec_func is too close to end of page and subsequent page is not mapped: 10000000-10010000 r-xp 00000000 fd:00 402855 mprotect04 10010000-10020000 rw-p 00000000 fd:00 402855 mprotect04 806a410000-806a440000 r-xp 00000000 fd:00 2097827 /lib64/ld-2.12.so where &exec_func == 0x100199c0, and page_size == 65536. It's also worth noting, that function ptr does not reside in .text, but in .opd section. That shouldn't matter for this testcase as long as it doesn't try to copy non-existent pages. This patch is changing copy function to try copy 2 whole aligned pages. Both pages are checked to be present in memory before memcpy is attempted. First is the page which contains &exec_func, and 2nd is the subsequent page - for the case &exec_func is too close to page boundary. Signed-off-by: Jan Stancek <jst...@re...> --- testcases/kernel/syscalls/mprotect/mprotect04.c | 61 +++++++++++++++++++++---- 1 file changed, 52 insertions(+), 9 deletions(-) diff --git a/testcases/kernel/syscalls/mprotect/mprotect04.c b/testcases/kernel/syscalls/mprotect/mprotect04.c index 8a4a72ad69f2..23aecbd856f4 100644 --- a/testcases/kernel/syscalls/mprotect/mprotect04.c +++ b/testcases/kernel/syscalls/mprotect/mprotect04.c @@ -54,6 +54,7 @@ int TST_TOTAL = ARRAY_SIZE(testfunc); static volatile int sig_caught; static sigjmp_buf env; +static int copy_sz; int main(int ac, char **av) { @@ -83,7 +84,9 @@ static void sighandler(int sig) static void setup(void) { + tst_tmpdir(); tst_sig(NOFORK, sighandler, cleanup); + copy_sz = getpagesize() * 2; TEST_PAUSE; } @@ -158,32 +161,71 @@ static void exec_func(void) return; } -static void *get_func(void *mem) +static int page_present(void *p) { - memcpy(mem, exec_func, getpagesize()); + int fd; + + fd = SAFE_OPEN(cleanup, "page_present", O_WRONLY|O_CREAT, 0644); + TEST(write(fd, p, 1)); + SAFE_CLOSE(cleanup, fd); + + if (TEST_RETURN >= 0) + return 1; + + if (TEST_ERRNO != EFAULT) + tst_brkm(TBROK | TTERRNO, cleanup, "page_present write"); - return mem; + return 0; +} + +/* + * Copy page where &exec_func resides. Also try to copy subsequent page + * in case exec_func is close to page boundary. + */ +static void *get_func(void *mem) +{ + uintptr_t page_sz = getpagesize(); + uintptr_t page_mask = ~(page_sz - 1); + uintptr_t func_page_offset = (uintptr_t)&exec_func & (page_sz - 1); + void *func_copy_start = mem + func_page_offset; + void *page_to_copy = (void *)((uintptr_t)&exec_func & page_mask); + + /* copy 1st page, if it's not present something is wrong */ + if (!page_present(page_to_copy)) { + tst_resm(TINFO, "exec_func: %p, page_to_copy: %p\n", + &exec_func, page_to_copy); + tst_brkm(TBROK, cleanup, "page_to_copy not present\n"); + } + memcpy(mem, page_to_copy, page_sz); + + /* copy 2nd page if possible */ + mem += page_sz; + page_to_copy += page_sz; + if (page_present(page_to_copy)) + memcpy(mem, page_to_copy, page_sz); + else + memset(mem, 0, page_sz); + + /* return pointer to area where copy of exec_func resides */ + return func_copy_start; } #endif static void testfunc_protexec(void) { - int page_sz; void (*func)(void); void *p; sig_caught = 0; - page_sz = getpagesize(); - - p = SAFE_MMAP(cleanup, 0, page_sz, PROT_READ | PROT_WRITE, + p = SAFE_MMAP(cleanup, 0, copy_sz, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); func = get_func(p); /* Change the protection to PROT_EXEC. */ - TEST(mprotect(p, page_sz, PROT_EXEC)); + TEST(mprotect(p, copy_sz, PROT_EXEC)); if (TEST_RETURN == -1) { tst_resm(TFAIL | TTERRNO, "mprotect failed"); @@ -205,9 +247,10 @@ static void testfunc_protexec(void) } } - SAFE_MUNMAP(cleanup, p, page_sz); + SAFE_MUNMAP(cleanup, p, copy_sz); } static void cleanup(void) { + tst_rmdir(); } -- 1.8.3.1 |
From: Cyril H. <ch...@su...> - 2015-09-09 11:32:24
|
Good news everyone, the Italian Linux Society (ILS - www.ils.org) members are kind enough to support us with mailing list on lt...@li.... I've send an invitation to the list to everyone subscribed to this list. I would like to wait for a few days for everyone to subscribe to the new list and then we will move the discusssion there. -- Cyril Hrubis ch...@su... |
From: Zeng L. <zen...@cn...> - 2015-09-09 09:26:23
|
Hello, Could you help to review? CC: Alexey Thanks and best regards, Zeng On Mon, 2015-08-31 at 18:15 +0800, Zeng Linggang wrote: > Signed-off-by: Zeng Linggang <zen...@cn...> > Signed-off-by: Alexey Kodanev <ale...@or...> > Signed-off-by: Cyril Hrubis <ch...@su...> > --- > runtest/ipv6_lib | 4 - > testcases/network/.gitignore | 4 - > testcases/network/lib6/Makefile | 4 - > testcases/network/lib6/asapi_01.c | 251 ---------------------------- > testcases/network/lib6/asapi_02.c | 338 -------------------------------------- > testcases/network/lib6/asapi_03.c | 234 -------------------------- > testcases/network/lib6/asapi_05.c | 119 +------------- > testcases/network/lib6/asapi_07.c | 144 ---------------- > testcases/network/lib6/runcc.c | 209 ----------------------- > testcases/network/lib6/runcc.h | 30 ---- > 10 files changed, 1 insertion(+), 1336 deletions(-) > delete mode 100644 testcases/network/lib6/asapi_01.c > delete mode 100644 testcases/network/lib6/asapi_02.c > delete mode 100644 testcases/network/lib6/asapi_03.c > delete mode 100644 testcases/network/lib6/asapi_07.c > delete mode 100644 testcases/network/lib6/runcc.c > delete mode 100644 testcases/network/lib6/runcc.h > > diff --git a/runtest/ipv6_lib b/runtest/ipv6_lib > index 75614fb..203e275 100644 > --- a/runtest/ipv6_lib > +++ b/runtest/ipv6_lib > @@ -2,10 +2,6 @@ > in6_01 in6_01 > in6_02 in6_02 > getaddrinfo_01 getaddrinfo_01 > -asapi_01 asapi_01 > -asapi_02 asapi_02 > -asapi_03 asapi_03 > asapi_04 asapi_04 > asapi_05 asapi_05 > asapi_06 asapi_06 > -asapi_07 asapi_07 > diff --git a/testcases/network/.gitignore b/testcases/network/.gitignore > index aa6d4da..18b0203 100644 > --- a/testcases/network/.gitignore > +++ b/testcases/network/.gitignore > @@ -1,13 +1,9 @@ > /can/filter-tests/can_filter > /can/filter-tests/can_rcv_own_msgs > /datafiles/ > -/lib6/asapi_01 > -/lib6/asapi_02 > -/lib6/asapi_03 > /lib6/asapi_04 > /lib6/asapi_05 > /lib6/asapi_06 > -/lib6/asapi_07 > /lib6/getaddrinfo_01 > /lib6/in6_01 > /lib6/in6_02 > diff --git a/testcases/network/lib6/Makefile b/testcases/network/lib6/Makefile > index e337938..e9fde3b 100644 > --- a/testcases/network/lib6/Makefile > +++ b/testcases/network/lib6/Makefile > @@ -31,8 +31,4 @@ LDLIBS += -lpthread > > CLEAN_TARGETS += $(LIB) > > -FILTER_OUT_MAKE_TARGETS := runcc > - > include $(top_srcdir)/include/mk/generic_leaf_target.mk > - > -$(MAKE_TARGETS): %: %.o runcc.o > diff --git a/testcases/network/lib6/asapi_01.c b/testcases/network/lib6/asapi_01.c > deleted file mode 100644 > index 5d8bdc7..0000000 > --- a/testcases/network/lib6/asapi_01.c > +++ /dev/null > @@ -1,251 +0,0 @@ > -/* > - * > - * Copyright (c) International Business Machines Corp., 2001 > - * Author: David L Stevens > - * > - * This program is free software; you can redistribute it and/or modify > - * it under the terms of the GNU General Public License as published by > - * the Free Software Foundation; either version 2 of the License, or > - * (at your option) any later version. > - * > - * This program is distributed in the hope that it will be useful, > - * but WITHOUT ANY WARRANTY; without even the implied warranty of > - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See > - * the GNU General Public License for more details. > - * > - * You should have received a copy of the GNU General Public License > - * along with this program; if not, write to the Free Software Foundation, > - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA > - */ > -/* > - * Description: > - * These tests are for the "Advanced Sockets API" (RFC 3542) > - * Verify that in6 and sockaddr fields are present. > - */ > - > -#include <stdio.h> > -#include <unistd.h> > -#include <errno.h> > - > -#include <sys/wait.h> > - > -#include <netinet/ip6.h> > - > -#include "test.h" > -#include "runcc.h" > - > -enum ttype { EXISTS, ALIAS, VALUE }; > - > -static struct ftent { > - char *ft_tname; /* test name */ > - int ft_type; /* test type */ > - char *ft_incl; /* include file list */ > - char *ft_struct; /* structure name */ > - char *ft_field; /* field name */ > - char *ft_offset; /* field offset */ > - union { > - char *fu_value; /* field size or value */ > - char *fu_dname; /* #define name */ > - } ftun; > -#define ft_value ftun.fu_value > -#define ft_dname ftun.fu_dname > -} ftab[] = { > - /* section 2.1 structure & field definitions */ > - { "ip6_hdr un1_flow", EXISTS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_flow", "0", {"4"} }, > - { "ip6_hdr ip6_flow", ALIAS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_flow", NULL, {"ip6_flow"} }, > - { "ip6_hdr un1_plen", EXISTS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_plen", "4", {"2"} }, > - { "ip6_hdr ip6_plen", ALIAS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_plen", "4", {"ip6_plen"} }, > - { "ip6_hdr un1_nxt", EXISTS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_nxt", "6", {"1"} }, > - { "ip6_hdr ip6_nxt", ALIAS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_nxt", NULL, {"ip6_nxt"} }, > - { "ip6_hdr un1_hlim", EXISTS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_hlim", "7", {"1"} }, > - { "ip6_hdr ip6_hlim", ALIAS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un1.ip6_un1_hlim", NULL, {"ip6_hlim"} }, > - { "ip6_hdr un1_vfc", EXISTS, IP6_H, "ip6_hdr", > - "ip6_ctlun.ip6_un2_vfc", "0", {"1"} }, > - { "ip6_hdr ip6_src", EXISTS, IP6_H, "ip6_hdr", > - "ip6_src", "sizeof(struct ip6_hdrctl)", > - {"sizeof(struct in6_addr)"} }, > - { "ip6_hdr ip6_dst", EXISTS, IP6_H, "ip6_hdr", "ip6_dst", > - "(sizeof(struct ip6_hdrctl)+sizeof(struct in6_addr))", > - {"sizeof(struct in6_addr)"} }, > - /* section 2.2 structure and field definitions */ > - { "IPPROTO_HOPOPTS", VALUE, IN_H, "IPPROTO_HOPOPTS", > - NULL, NULL, {"0"} }, > - { "IPPROTO_IPV6", VALUE, IN_H, "IPPROTO_IPV6", > - NULL, NULL, {"41"} }, > - { "IPPROTO_ROUTING", VALUE, IN_H, "IPPROTO_ROUTING", > - NULL, NULL, {"43"} }, > - { "IPPROTO_FRAGMENT", VALUE, IN_H, "IPPROTO_FRAGMENT", > - NULL, NULL, {"44"} }, > - { "IPPROTO_ESP", VALUE, IN_H, "IPPROTO_ESP", > - NULL, NULL, {"50"} }, > - { "IPPROTO_AH", VALUE, IN_H, "IPPROTO_AH", > - NULL, NULL, {"51"} }, > - { "IPPROTO_ICMPV6", VALUE, IN_H, "IPPROTO_ICMPV6", > - NULL, NULL, {"58"} }, > - { "IPPROTO_NONE", VALUE, IN_H, "IPPROTO_NONE", > - NULL, NULL, {"59"} }, > - { "IPPROTO_DSTOPTS", VALUE, IN_H, "IPPROTO_DSTOPTS", > - NULL, NULL, {"60"} }, > - /* ip6_hbh */ > - { "ip6_hbh ip6h_nxt", EXISTS, IP6_H, "ip6_hbh", > - "ip6h_nxt", "0", {"1"} }, > - { "ip6_hbh ip6h_nxt", EXISTS, IP6_H, "ip6_hbh", > - "ip6h_len", "1", {"1"} }, > - /* ip6_dest */ > - { "ip6_dest ip6d_nxt", EXISTS, IP6_H, "ip6_dest", > - "ip6d_nxt", "0", {"1"} }, > - { "ip6_dest ip6d_nxt", EXISTS, IP6_H, "ip6_dest", > - "ip6d_len", "1", {"1"} }, > - /* ip6_rthdr0 */ > - { "ip6_rthdr0 ip6r0_nxt", EXISTS, IP6_H, "ip6_rthdr0", > - "ip6r0_nxt", "0", {"1"} }, > - { "ip6_rthdr0 ip6r0_len", EXISTS, IP6_H, "ip6_rthdr0", > - "ip6r0_len", "1", {"1"} }, > - { "ip6_rthdr0 ip6r0_type", EXISTS, IP6_H, "ip6_rthdr0", > - "ip6r0_type", "2", {"1"} }, > - { "ip6_rthdr0 ip6r0_segleft", EXISTS, IP6_H, "ip6_rthdr0", > - "ip6r0_segleft", "3", {"1"} }, > - { "ip6_rthdr0 ip6r0_reserved", EXISTS, IP6_H, "ip6_rthdr0", > - "ip6r0_reserved", "4", {"1"} }, > - /* ip6_frag */ > - { "ip6_frag ip6f_nxt", EXISTS, IP6_H, "ip6_frag", > - "ip6f_nxt", "0", {"1"} }, > - { "ip6_frag ip6f_reserved", EXISTS, IP6_H, "ip6_frag", > - "ip6f_reserved", "1", {"1"} }, > - { "ip6_frag ip6f_offlg", EXISTS, IP6_H, "ip6_frag", > - "ip6f_offlg", "2", {"2"} }, > - { "ip6_frag ip6f_ident", EXISTS, IP6_H, "ip6_frag", > - "ip6f_ident", "4", {"4"} }, > - { "IP6F_OFF_MASK", VALUE, IP6_H, "IP6F_OFF_MASK", > - NULL, NULL, {"htons(0xfff8)"} }, > - { "IP6F_RESERVED_MASK", VALUE, IP6_H, "IP6F_RESERVED_MASK", > - NULL, NULL, {"htons(0x0006)"} }, > - { "IP6F_MORE_FRAG", VALUE, IP6_H, "IP6F_MORE_FRAG", > - NULL, NULL, {"htons(0x0001)"} }, > - { "IP6OPT_TYPE", VALUE, IP6_H, "IP6OPT_TYPE(0xff)", > - NULL, NULL, {"0xc0"} }, > - { "IP6OPT_TYPE_SKIP", VALUE, IP6_H, "IP6OPT_TYPE_SKIP", > - NULL, NULL, {"0x00"} }, > - { "IP6OPT_TYPE_DISCARD", VALUE, IP6_H, "IP6OPT_TYPE_DISCARD", > - NULL, NULL, {"0x40"} }, > - { "IP6OPT_TYPE_FORCEICMP", VALUE, IP6_H, "IP6OPT_TYPE_FORCEICMP", > - NULL, NULL, {"0x80"} }, > - { "IP6OPT_TYPE_ICMP", VALUE, IP6_H, "IP6OPT_TYPE_ICMP", > - NULL, NULL, {"0xc0"} }, > - { "IP6OPT_TYPE_MUTABLE", VALUE, IP6_H, "IP6OPT_TYPE_MUTABLE", > - NULL, NULL, {"0x20"} }, > - { "IP6OPT_PAD1", VALUE, IP6_H, "IP6OPT_PAD1", > - NULL, NULL, {"0x00"} }, > - { "IP6OPT_PADN", VALUE, IP6_H, "IP6OPT_PADN", > - NULL, NULL, {"0x01"} }, > - { "IP6OPT_JUMBO", VALUE, IP6_H, "IP6OPT_JUMBO", > - NULL, NULL, {"0xc2"} }, > - { "IP6OPT_NSAP_ADDR", VALUE, IP6_H, "IP6OPT_NSAP_ADDR", > - NULL, NULL, {"0xc3"} }, > - { "IP6OPT_TUNNEL_LIMIT", VALUE, IP6_H, "IP6OPT_TUNNEL_LIMIT", > - NULL, NULL, {"0x04"} }, > - { "IP6OPT_ROUTER_ALERT", VALUE, IP6_H, "IP6OPT_ROUTER_ALERT", > - NULL, NULL, {"0x05"} }, > - /* ip6_opt_jumbo */ > - { "ip6_opt_jumbo ip6oj_type", EXISTS, IP6_H, "ip6_opt_jumbo", > - "ip6oj_type", "0", {"1"} }, > - { "ip6_opt_jumbo ip6oj_len", EXISTS, IP6_H, "ip6_opt_jumbo", > - "ip6oj_len", "1", {"1"} }, > - { "ip6_opt_jumbo ip6oj_jumbo_len element", EXISTS, IP6_H, > - "ip6_opt_jumbo", "ip6oj_jumbo_len[0]", "2", {"1"} }, > - { "ip6_opt_jumbo ip6oj_jumbo_len array", EXISTS, IP6_H, > - "ip6_opt_jumbo", "ip6oj_jumbo_len", "2", {"4"} }, > - /* ip6_opt_nsap */ > - { "ip6_opt_nsap ip6on_type", EXISTS, IP6_H, "ip6_opt_nsap", > - "ip6on_type", "0", {"1"} }, > - { "ip6_opt_nsap ip6on_len", EXISTS, IP6_H, "ip6_opt_nsap", > - "ip6on_len", "1", {"1"} }, > - { "ip6_opt_nsap ip6on_src_nsap_len", EXISTS, IP6_H, > - "ip6_opt_nsap", "ip6on_src_nsap_len", "2", {"1"} }, > - { "ip6_opt_nsap ip6on_dst_nsap_len", EXISTS, IP6_H, > - "ip6_opt_nsap", "ip6on_dst_nsap_len", "3", {"1"} }, > - /* ip6_opt_tunnel */ > - { "ip6_opt_tunnel ip6ot_type", EXISTS, IP6_H, > - "ip6_opt_tunnel", "ip6ot_type", "0", {"1"} }, > - { "ip6_opt_tunnel ip6ot_len", EXISTS, IP6_H, > - "ip6_opt_tunnel", "ip6ot_len", "1", {"1"} }, > - { "ip6_opt_tunnel ip6ot_encap_limit", EXISTS, IP6_H, > - "ip6_opt_tunnel", "ip6ot_encap_limit", "2", {"1"} }, > - /* ip6_opt_router */ > - { "ip6_opt_router ip6or_type", EXISTS, IP6_H, > - "ip6_opt_router", "ip6or_type", "0", {"1"} }, > - { "ip6_opt_router ip6or_len", EXISTS, IP6_H, > - "ip6_opt_router", "ip6or_len", "1", {"1"} }, > - { "ip6_opt_router ip6or_value element", EXISTS, IP6_H, > - "ip6_opt_router", "ip6or_value[0]", "2", {"1"} }, > - { "ip6_opt_router ip6or_value array", EXISTS, IP6_H, > - "ip6_opt_router", "ip6or_value", "2", {"2"} }, > - /* IP6_ALERT_* definitions */ > - { "IP6_ALERT_MLD", VALUE, IP6_H, "IP6_ALERT_MLD", > - NULL, NULL, {"0"} }, > - { "IP6_ALERT_RSVP", VALUE, IP6_H, "IP6_ALERT_RSVP", > - NULL, NULL, {"htons(1)"} }, > - { "IP6_ALERT_AN", VALUE, IP6_H, "IP6_ALERT_AN", > - NULL, NULL, {"htons(2)"} }, > -}; > - > -static void setup(void); > -static void do_test(const struct ftent *); > - > -char *TCID = "asapi_01"; > -int TST_TOTAL = ARRAY_SIZE(ftab); > - > -int main(int argc, char *argv[]) > -{ > - int i, lc; > - > - tst_parse_opts(argc, argv, NULL, NULL); > - > - setup(); > - > - for (lc = 0; TEST_LOOPING(lc); ++lc) { > - tst_count = 0; > - > - for (i = 0; i < TST_TOTAL; i++) > - do_test(&ftab[i]); > - } > - > - tst_exit(); > -} > - > -void setup(void) > -{ > - TEST_PAUSE; > -} > - > -void do_test(const struct ftent *ftptr) > -{ > - switch (ftptr->ft_type) { > - case EXISTS: > - structcheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_field, > - ftptr->ft_offset, ftptr->ft_value); > - break; > - case ALIAS: > - aliascheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_field, > - ftptr->ft_dname); > - break; > - case VALUE: > - valuecheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_dname); > - break; > - default: > - tst_resm(TBROK, "invalid type %d", > - ftptr->ft_type); > - break; > - } > -} > diff --git a/testcases/network/lib6/asapi_02.c b/testcases/network/lib6/asapi_02.c > deleted file mode 100644 > index 01bee37..0000000 > --- a/testcases/network/lib6/asapi_02.c > +++ /dev/null > @@ -1,338 +0,0 @@ > -/* > - * > - * Copyright (c) International Business Machines Corp., 2001 > - * Author: David L Stevens > - * > - * This program is free software; you can redistribute it and/or modify > - * it under the terms of the GNU General Public License as published by > - * the Free Software Foundation; either version 2 of the License, or > - * (at your option) any later version. > - * > - * This program is distributed in the hope that it will be useful, > - * but WITHOUT ANY WARRANTY; without even the implied warranty of > - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See > - * the GNU General Public License for more details. > - * > - * You should have received a copy of the GNU General Public License > - * along with this program; if not, write to the Free Software Foundation, > - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA > - */ > -/* > - * Description: > - * These tests are for the "Advanced Sockets API" (RFC 3542) > - * Verify that in6 and sockaddr fields are present. > - */ > - > -#include <stdio.h> > -#include <unistd.h> > -#include <errno.h> > - > -#include <sys/wait.h> > - > -#include <netinet/ip6.h> > - > -#include "test.h" > -#include "runcc.h" > - > -enum ttype { EXISTS, ALIAS, VALUE }; > - > -static struct ftent { > - char *ft_tname; /* test name */ > - int ft_type; /* test type */ > - char *ft_incl; /* include file list */ > - char *ft_struct; /* structure name */ > - char *ft_field; /* field name */ > - char *ft_offset; /* field offset */ > - union { > - char *fu_value; /* field size or value */ > - char *fu_dname; /* #define name */ > - } ftun; > -#define ft_value ftun.fu_value > -#define ft_dname ftun.fu_dname > -} ftab[] = { > - /* Section 2.2, icmp6_hdr & defines */ > - { "icmp6_hdr icmp6_type", EXISTS, ICMP6_H, "icmp6_hdr", > - "icmp6_type", "0", {"1"} }, > - { "icmp6_hdr icmp6_code", EXISTS, ICMP6_H, "icmp6_hdr", > - "icmp6_code", "1", {"1"} }, > - { "icmp6_hdr icmp6_cksum", EXISTS, ICMP6_H, "icmp6_hdr", > - "icmp6_cksum", "2", {"2"} }, > - { "icmp6_hdr icmp6_un_data32 element", EXISTS, ICMP6_H, > - "icmp6_hdr", "icmp6_dataun.icmp6_un_data32[0]", "4", {"4"} }, > - { "icmp6_hdr icmp6_un_data32 array", EXISTS, ICMP6_H, > - "icmp6_hdr", "icmp6_dataun.icmp6_un_data32", "4", {"4"} }, > - { "icmp6_hdr icmp6_un_data16 element", EXISTS, ICMP6_H, > - "icmp6_hdr", "icmp6_dataun.icmp6_un_data16[0]", "4", {"2"} }, > - { "icmp6_hdr icmp6_un_data16 array", EXISTS, ICMP6_H, > - "icmp6_hdr", "icmp6_dataun.icmp6_un_data16", "4", {"4"} }, > - { "icmp6_hdr icmp6_un_data8 element", EXISTS, ICMP6_H, > - "icmp6_hdr", "icmp6_dataun.icmp6_un_data8[0]", "4", {"1"} }, > - { "icmp6_hdr icmp6_un_data8 array", EXISTS, ICMP6_H, > - "icmp6_hdr", "icmp6_dataun.icmp6_un_data8", "4", {"4"} }, > - /* icmp6_hdr definitions */ > - { "icmp6_hdr icmp6_data32 define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data32", NULL, {"icmp6_data32"} }, > - { "icmp6_hdr icmp6_data16 define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data16", NULL, {"icmp6_data16"} }, > - { "icmp6_hdr icmp6_data8 define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data8", NULL, {"icmp6_data8"} }, > - { "icmp6_hdr icmp6_pptr define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data32[0]", NULL, {"icmp6_pptr"} }, > - { "icmp6_hdr icmp6_mtu define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data32[0]", NULL, {"icmp6_mtu"} }, > - { "icmp6_hdr icmp6_id define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data16[0]", NULL, {"icmp6_id"} }, > - { "icmp6_hdr icmp6_seq define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data16[1]", NULL, {"icmp6_seq"} }, > - { "icmp6_hdr icmp6_maxdelay define", ALIAS, ICMP6_H, "icmp6_hdr", > - "icmp6_dataun.icmp6_un_data16[0]", NULL, {"icmp6_maxdelay"} }, > - /* Section 2.2.1 ICMPv6 Type and Code Values */ > - { "ICMP6_DST_UNREACH", VALUE, ICMP6_H, "ICMP6_DST_UNREACH", > - NULL, NULL, {"1"} }, > - { "ICMP6_PACKET_TOO_BIG", VALUE, ICMP6_H, "ICMP6_PACKET_TOO_BIG", > - NULL, NULL, {"2"} }, > - { "ICMP6_TIME_EXCEEDED", VALUE, ICMP6_H, "ICMP6_TIME_EXCEEDED", > - NULL, NULL, {"3"} }, > - { "ICMP6_PARAM_PROB", VALUE, ICMP6_H, "ICMP6_PARAM_PROB", > - NULL, NULL, {"4"} }, > - { "ICMP6_INFOMSG_MASK", VALUE, ICMP6_H, "ICMP6_INFOMSG_MASK", > - NULL, NULL, {"0x80"} }, > - { "ICMP6_ECHO_REQUEST", VALUE, ICMP6_H, "ICMP6_ECHO_REQUEST", > - NULL, NULL, {"128"} }, > - { "ICMP6_ECHO_REPLY", VALUE, ICMP6_H, "ICMP6_ECHO_REPLY", > - NULL, NULL, {"129"} }, > - { "ICMP6_DST_UNREACH_NOROUTE", VALUE, ICMP6_H, > - "ICMP6_DST_UNREACH_NOROUTE", NULL, NULL, {"0"} }, > - { "ICMP6_DST_UNREACH_ADMIN", VALUE, ICMP6_H, > - "ICMP6_DST_UNREACH_ADMIN", NULL, NULL, {"1"} }, > - { "ICMP6_DST_UNREACH_BEYONDSCOPE", VALUE, ICMP6_H, > - "ICMP6_DST_UNREACH_BEYONDSCOPE", NULL, NULL, {"2"} }, > - { "ICMP6_DST_UNREACH_ADDR", VALUE, ICMP6_H, > - "ICMP6_DST_UNREACH_ADDR", NULL, NULL, {"3"} }, > - { "ICMP6_DST_UNREACH_NOPORT", VALUE, ICMP6_H, > - "ICMP6_DST_UNREACH_NOPORT", NULL, NULL, {"4"} }, > - { "ICMP6_TIME_EXCEED_TRANSIT", VALUE, ICMP6_H, > - "ICMP6_TIME_EXCEED_TRANSIT", NULL, NULL, {"0"} }, > - { "ICMP6_TIME_EXCEED_REASSEMBLY", VALUE, ICMP6_H, > - "ICMP6_TIME_EXCEED_REASSEMBLY", NULL, NULL, {"1"} }, > - { "ICMP6_PARAMPROB_HEADER", VALUE, ICMP6_H, > - "ICMP6_PARAMPROB_HEADER", NULL, NULL, {"0"} }, > - { "ICMP6_PARAMPROB_NEXTHEADER", VALUE, ICMP6_H, > - "ICMP6_PARAMPROB_NEXTHEADER", NULL, NULL, {"1"} }, > - { "ICMP6_PARAMPROB_OPTION", VALUE, ICMP6_H, > - "ICMP6_PARAMPROB_OPTION", NULL, NULL, {"2"} }, > - /* section 2.2.2, Neighbor Discovery */ > - { "ND_ROUTER_SOLICIT", VALUE, ICMP6_H, > - "ND_ROUTER_SOLICIT", NULL, NULL, {"133"} }, > - { "ND_ROUTER_ADVERT", VALUE, ICMP6_H, > - "ND_ROUTER_ADVERT", NULL, NULL, {"134"} }, > - { "ND_NEIGHBOR_SOLICIT", VALUE, ICMP6_H, > - "ND_NEIGHBOR_SOLICIT", NULL, NULL, {"135"} }, > - { "ND_NEIGHBOR_ADVERT", VALUE, ICMP6_H, > - "ND_NEIGHBOR_ADVERT", NULL, NULL, {"136"} }, > - { "ND_REDIRECT", VALUE, ICMP6_H, > - "ND_REDIRECT", NULL, NULL, {"137"} }, > - { "nd_router_solicit nd_rs_hdr", EXISTS, ICMP6_H, > - "nd_router_solicit", "nd_rs_hdr", "0", > - {"sizeof(struct icmp6_hdr)"} }, > - { "nd_router_solicit nd_rs_type define", ALIAS, ICMP6_H, > - "nd_router_solicit", "nd_rs_hdr.icmp6_type", > - NULL, {"nd_rs_type"} }, > - { "nd_router_solicit nd_rs_code define", ALIAS, ICMP6_H, > - "nd_router_solicit", "nd_rs_hdr.icmp6_code", > - NULL, {"nd_rs_code"} }, > - { "nd_router_solicit nd_rs_cksum define", ALIAS, ICMP6_H, > - "nd_router_solicit", "nd_rs_hdr.icmp6_cksum", > - NULL, {"nd_rs_cksum"} }, > - { "nd_router_solicit nd_rs_reserved define", ALIAS, ICMP6_H, > - "nd_router_solicit", "nd_rs_hdr.icmp6_data32[0]", > - NULL, {"nd_rs_reserved"} }, > - { "nd_router_advert nd_ra_hdr", EXISTS, ICMP6_H, > - "nd_router_advert", "nd_ra_hdr", "0", > - {"sizeof(struct icmp6_hdr)"} }, > - { "nd_router_advert nd_ra_reachable", EXISTS, ICMP6_H, > - "nd_router_advert", "nd_ra_reachable", > - "sizeof(struct icmp6_hdr)", {"4"} }, > - { "nd_router_advert nd_ra_retransmit", EXISTS, ICMP6_H, > - "nd_router_advert", "nd_ra_retransmit", > - "sizeof(struct icmp6_hdr)+4", {"4"} }, > - { "nd_router_advert nd_ra_type define", ALIAS, ICMP6_H, > - "nd_router_advert", "nd_ra_hdr.icmp6_type", > - NULL, {"nd_ra_type"} }, > - { "nd_router_advert nd_ra_code define", ALIAS, ICMP6_H, > - "nd_router_advert", "nd_ra_hdr.icmp6_code", > - NULL, {"nd_ra_code"} }, > - { "nd_router_advert nd_ra_cksum define", ALIAS, ICMP6_H, > - "nd_router_advert", "nd_ra_hdr.icmp6_cksum", > - NULL, {"nd_ra_cksum"} }, > - { "nd_router_advert nd_ra_curhoplimit define", ALIAS, ICMP6_H, > - "nd_router_advert", "nd_ra_hdr.icmp6_data8[0]", > - NULL, {"nd_ra_curhoplimit"} }, > - { "nd_router_advert nd_ra_flags_reserved define", ALIAS, ICMP6_H, > - "nd_router_advert", "nd_ra_hdr.icmp6_data8[1]", > - NULL, {"nd_ra_flags_reserved"} }, > - { "ND_RA_FLAG_MANAGED", VALUE, ICMP6_H, > - "ND_RA_FLAG_MANAGED", NULL, NULL, {"0x80"} }, > - { "ND_RA_FLAG_OTHER", VALUE, ICMP6_H, > - "ND_RA_FLAG_OTHER", NULL, NULL, {"0x40"} }, > - { "nd_router_advert nd_ra_router_lifetime define", ALIAS, ICMP6_H, > - "nd_router_advert", "nd_ra_hdr.icmp6_data16[1]", > - NULL, {"nd_ra_router_lifetime"} }, > - { "nd_neighbor_solicit nd_ns_hdr", EXISTS, ICMP6_H, > - "nd_neighbor_solicit", "nd_ns_hdr", > - "0", {"sizeof(struct icmp6_hdr)"} }, > - { "nd_neighbor_solicit nd_ns_target", EXISTS, ICMP6_H, > - "nd_neighbor_solicit", "nd_ns_target", > - "sizeof(struct icmp6_hdr)", {"sizeof(struct in6_addr)"} }, > - { "nd_neighbor_solicit nd_ns_type define", ALIAS, ICMP6_H, > - "nd_neighbor_solicit", "nd_ns_hdr.icmp6_type", > - NULL, {"nd_ns_type"} }, > - { "nd_neighbor_solicit nd_ns_code define", ALIAS, ICMP6_H, > - "nd_neighbor_solicit", "nd_ns_hdr.icmp6_code", > - NULL, {"nd_ns_code"} }, > - { "nd_neighbor_solicit nd_ns_cksum define", ALIAS, ICMP6_H, > - "nd_neighbor_solicit", "nd_ns_hdr.icmp6_cksum", > - NULL, {"nd_ns_cksum"} }, > - { "nd_neighbor_solicit nd_ns_reserved define", ALIAS, ICMP6_H, > - "nd_neighbor_solicit", "nd_ns_hdr.icmp6_data32[0]", > - NULL, {"nd_ns_reserved"} }, > - { "nd_neighbor_advert nd_na_hdr", EXISTS, ICMP6_H, > - "nd_neighbor_advert", "nd_na_hdr", > - "0", {"sizeof(struct icmp6_hdr)"} }, > - { "nd_neighbor_advert nd_na_target", EXISTS, ICMP6_H, > - "nd_neighbor_advert", "nd_na_target", > - "sizeof(struct icmp6_hdr)", {"sizeof(struct in6_addr)"} }, > - { "nd_neighbor_advert nd_na_type define", ALIAS, ICMP6_H, > - "nd_neighbor_advert", "nd_na_hdr.icmp6_type", > - NULL, {"nd_na_type"} }, > - { "nd_neighbor_advert nd_na_code define", ALIAS, ICMP6_H, > - "nd_neighbor_advert", "nd_na_hdr.icmp6_code", > - NULL, {"nd_na_code"} }, > - { "nd_neighbor_advert nd_na_cksum define", ALIAS, ICMP6_H, > - "nd_neighbor_advert", "nd_na_hdr.icmp6_cksum", > - NULL, {"nd_na_cksum"} }, > - { "nd_neighbor_advert nd_na_flags_reserved define", ALIAS, > - ICMP6_H, "nd_neighbor_advert", "nd_na_hdr.icmp6_data32[0]", > - NULL, {"nd_na_flags_reserved"} }, > - { "ND_NA_FLAG_ROUTER", VALUE, ICMP6_H, "ND_NA_FLAG_ROUTER", > - NULL, NULL, {"htonl(0x80000000)"} }, > - { "ND_NA_FLAG_SOLICITED", VALUE, ICMP6_H, "ND_NA_FLAG_SOLICITED", > - NULL, NULL, {"htonl(0x40000000)"} }, > - { "ND_NA_FLAG_OVERRIDE", VALUE, ICMP6_H, "ND_NA_FLAG_OVERRIDE", > - NULL, NULL, {"htonl(0x20000000)"} }, > - { "nd_redirect nd_rd_hdr", EXISTS, ICMP6_H, "nd_redirect", > - "nd_rd_hdr", "0", {"sizeof(struct icmp6_hdr)"} }, > - { "nd_redirect nd_rd_target", EXISTS, ICMP6_H, > - "nd_redirect", "nd_rd_target", > - "sizeof(struct icmp6_hdr)", {"sizeof(struct in6_addr)"} }, > - { "nd_redirect nd_rd_dst", EXISTS, ICMP6_H, "nd_redirect", > - "nd_rd_dst", "sizeof(struct icmp6_hdr)+sizeof(struct in6_addr)", > - {"sizeof(struct in6_addr)"} }, > - { "nd_redirect nd_rd_type define", ALIAS, ICMP6_H, > - "nd_neighbor_advert", "nd_na_hdr.icmp6_data32[0]", > - NULL, {"nd_na_flags_reserved"} }, > - { "nd_opt_hdr nd_rd_hdr", EXISTS, ICMP6_H, "nd_opt_hdr", > - "nd_opt_type", "0", {"1"} }, > - { "nd_opt_hdr nd_rd_hdr", EXISTS, ICMP6_H, "nd_opt_hdr", > - "nd_opt_len", "1", {"1"} }, > - { "ND_OPT_SOURCE_LINKADDR", VALUE, ICMP6_H, > - "ND_OPT_SOURCE_LINKADDR", NULL, NULL, {"1"} }, > - { "ND_OPT_TARGET_LINKADDR", VALUE, ICMP6_H, > - "ND_OPT_TARGET_LINKADDR", NULL, NULL, {"2"} }, > - { "ND_OPT_PREFIX_INFORMATION", VALUE, ICMP6_H, > - "ND_OPT_PREFIX_INFORMATION", NULL, NULL, {"3"} }, > - { "ND_OPT_REDIRECTED_HEADER", VALUE, ICMP6_H, > - "ND_OPT_REDIRECTED_HEADER", NULL, NULL, {"4"} }, > - { "ND_OPT_MTU", VALUE, ICMP6_H, "ND_OPT_MTU", > - NULL, NULL, {"5"} }, > - { "nd_opt_prefix_info nd_opt_pi_type", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_type", "0", {"1"} }, > - { "nd_opt_prefix_info nd_opt_pi_len", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_len", "1", {"1"} }, > - { "nd_opt_prefix_info nd_opt_pi_prefix_len", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_prefix_len", "2", {"1"} }, > - { "nd_opt_prefix_info nd_opt_pi_flags_reserved", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_flags_reserved", "3", {"1"} }, > - { "nd_opt_prefix_info nd_opt_pi_valid_time", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_valid_time", "4", {"4"} }, > - { "nd_opt_prefix_info nd_opt_pi_preferred_time", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_preferred_time", "8", {"4"} }, > - { "nd_opt_prefix_info nd_opt_pi_reserved2", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_reserved2", "12", {"4"} }, > - { "nd_opt_prefix_info nd_opt_pi_prefix", EXISTS, ICMP6_H, > - "nd_opt_prefix_info", "nd_opt_pi_prefix", > - "16", {"sizeof(struct in6_addr)"} }, > - { "ND_OPT_PI_FLAG_ONLINK", VALUE, ICMP6_H, > - "ND_OPT_PI_FLAG_ONLINK", NULL, NULL, {"0x80"} }, > - { "ND_OPT_PI_FLAG_AUTO", VALUE, ICMP6_H, > - "ND_OPT_PI_FLAG_AUTO", NULL, NULL, {"0x40"} }, > - { "nd_opt_rd_hdr nd_opt_rh_type", EXISTS, ICMP6_H, > - "nd_opt_rd_hdr", "nd_opt_rh_type", "0", {"1"} }, > - { "nd_opt_rd_hdr nd_opt_rh_len", EXISTS, ICMP6_H, > - "nd_opt_rd_hdr", "nd_opt_rh_len", "1", {"1"} }, > - { "nd_opt_rd_hdr nd_opt_rh_reserved1", EXISTS, ICMP6_H, > - "nd_opt_rd_hdr", "nd_opt_rh_reserved1", "2", {"2"} }, > - { "nd_opt_rd_hdr nd_opt_rh_reserved2", EXISTS, ICMP6_H, > - "nd_opt_rd_hdr", "nd_opt_rh_reserved2", "4", {"4"} }, > - { "nd_opt_mtu nd_opt_mtu_type", EXISTS, ICMP6_H, > - "nd_opt_mtu", "nd_opt_mtu_type", "0", {"1"} }, > - { "nd_opt_mtu nd_opt_mtu_len", EXISTS, ICMP6_H, > - "nd_opt_mtu", "nd_opt_mtu_len", "1", {"1"} }, > - { "nd_opt_mtu nd_opt_mtu_reserved", EXISTS, ICMP6_H, > - "nd_opt_mtu", "nd_opt_mtu_reserved", "2", {"2"} }, > - { "nd_opt_mtu nd_opt_mtu_mtu", EXISTS, ICMP6_H, > - "nd_opt_mtu", "nd_opt_mtu_mtu", "4", {"4"} }, > -}; > - > -static void setup(void); > -static void do_test(const struct ftent *); > - > -char *TCID = "asapi_02"; > -int TST_TOTAL = ARRAY_SIZE(ftab); > - > -int main(int argc, char *argv[]) > -{ > - int i, lc; > - > - tst_parse_opts(argc, argv, NULL, NULL); > - > - setup(); > - > - for (lc = 0; TEST_LOOPING(lc); ++lc) { > - tst_count = 0; > - > - for (i = 0; i < TST_TOTAL; i++) > - do_test(&ftab[i]); > - } > - > - tst_exit(); > -} > - > -void setup(void) > -{ > - TEST_PAUSE; > -} > - > -void do_test(const struct ftent *ftptr) > -{ > - switch (ftptr->ft_type) { > - case EXISTS: > - structcheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_field, > - ftptr->ft_offset, ftptr->ft_value); > - break; > - case ALIAS: > - aliascheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_field, > - ftptr->ft_dname); > - break; > - case VALUE: > - valuecheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_dname); > - break; > - default: > - tst_resm(TBROK, "invalid type %d", > - ftptr->ft_type); > - break; > - } > -} > diff --git a/testcases/network/lib6/asapi_03.c b/testcases/network/lib6/asapi_03.c > deleted file mode 100644 > index f458d7d..0000000 > --- a/testcases/network/lib6/asapi_03.c > +++ /dev/null > @@ -1,234 +0,0 @@ > -/* > - * > - * Copyright (c) International Business Machines Corp., 2001 > - * Author: David L Stevens > - * > - * This program is free software; you can redistribute it and/or modify > - * it under the terms of the GNU General Public License as published by > - * the Free Software Foundation; either version 2 of the License, or > - * (at your option) any later version. > - * > - * This program is distributed in the hope that it will be useful, > - * but WITHOUT ANY WARRANTY; without even the implied warranty of > - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See > - * the GNU General Public License for more details. > - * > - * You should have received a copy of the GNU General Public License > - * along with this program; if not, write to the Free Software Foundation, > - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA > - */ > -/* > - * Description: > - * These tests are for the "Advanced Sockets API" (RFC 3542) > - * Verify that in6 and sockaddr fields are present. > - */ > - > -#include <stdio.h> > -#include <unistd.h> > -#include <errno.h> > - > -#include <sys/wait.h> > - > -#include <netinet/ip6.h> > - > -#include "test.h" > -#include "runcc.h" > - > -enum ttype { EXISTS, ALIAS, VALUE }; > - > -static struct ftent { > - char *ft_tname; /* test name */ > - int ft_type; /* test type */ > - char *ft_incl; /* include file list */ > - char *ft_struct; /* structure name */ > - char *ft_field; /* field name */ > - char *ft_offset; /* field offset */ > - union { > - char *fu_value; /* field size or value */ > - char *fu_dname; /* #define name */ > - } ftun; > -#define ft_value ftun.fu_value > -#define ft_dname ftun.fu_dname > -} ftab[] = { > - /* section 2.2.3, MLDv1 */ > - { "MLD_LISTENER_QUERY", VALUE, ICMP6_H, > - "MLD_LISTENER_QUERY", NULL, NULL, {"130"} }, > - { "MLD_LISTENER_REPORT", VALUE, ICMP6_H, > - "MLD_LISTENER_REPORT", NULL, NULL, {"131"} }, > - { "MLD_LISTENER_REDUCTION", VALUE, ICMP6_H, > - "MLD_LISTENER_REDUCTION", NULL, NULL, {"132"} }, > - { "mld_hdr mld_icmp6_hdr", EXISTS, ICMP6_H, > - "mld_hdr", "mld_icmp6_hdr", "0", > - {"sizeof(struct icmp6_hdr)"} }, > - { "mld_hdr mld_addr", EXISTS, ICMP6_H, "mld_hdr", > - "mld_addr", "sizeof(struct icmp6_hdr)", > - {"sizeof(struct in6_addr)"} }, > - { "mld_hdr mld_type define", ALIAS, ICMP6_H, "mld_hdr", > - "mld_icmp6_hdr.icmp6_type", NULL, {"mld_type"} }, > - { "mld_hdr mld_code define", ALIAS, ICMP6_H, "mld_hdr", > - "mld_icmp6_hdr.icmp6_code", NULL, {"mld_code"} }, > - { "mld_hdr mld_cksum define", ALIAS, ICMP6_H, "mld_hdr", > - "mld_icmp6_hdr.icmp6_cksum", NULL, {"mld_cksum"} }, > - { "mld_hdr mld_maxdelay define", ALIAS, ICMP6_H, "mld_hdr", > - "mld_icmp6_hdr.icmp6_data16[0]", NULL, {"mld_maxdelay"} }, > - { "mld_hdr mld_reserved define", ALIAS, ICMP6_H, "mld_hdr", > - "mld_icmp6_hdr.icmp6_data16[1]", NULL, {"mld_reserved"} }, > - /* section 2.2.4, Router renumbering */ > - { "ICMP6_ROUTER_RENUMBERING", VALUE, ICMP6_H, > - "ICMP6_ROUTER_RENUMBERING", NULL, NULL, {"138"} }, > - { "icmp6_router_renum rr_hdr", EXISTS, ICMP6_H, > - "icmp6_router_renum", "rr_hdr", "0", > - {"sizeof(struct icmp6_hdr)"} }, > - { "icmp6_router_renum rr_segnum", EXISTS, ICMP6_H, > - "icmp6_router_renum", "rr_segnum", > - "sizeof(struct icmp6_hdr)", {"1"} }, > - { "icmp6_router_renum rr_flags", EXISTS, ICMP6_H, > - "icmp6_router_renum", "rr_flags", > - "sizeof(struct icmp6_hdr)+1", {"1"} }, > - { "icmp6_router_renum rr_maxdelay", EXISTS, ICMP6_H, > - "icmp6_router_renum", "rr_maxdelay", > - "sizeof(struct icmp6_hdr)+2", {"2"} }, > - { "icmp6_router_renum rr_reserved", EXISTS, ICMP6_H, > - "icmp6_router_renum", "rr_reserved", > - "sizeof(struct icmp6_hdr)+4", {"4"} }, > - { "icmp6_router_renum rr_type define", ALIAS, ICMP6_H, > - "icmp6_router_renum", "rr_hdr.icmp6_type", > - NULL, {"rr_type"} }, > - { "icmp6_router_renum rr_code define", ALIAS, ICMP6_H, > - "icmp6_router_renum", "rr_hdr.icmp6_code", > - NULL, {"rr_code"} }, > - { "icmp6_router_renum rr_cksum define", ALIAS, ICMP6_H, > - "icmp6_router_renum", "rr_hdr.icmp6_cksum", > - NULL, {"rr_cksum"} }, > - { "icmp6_router_renum rr_seqnum define", ALIAS, ICMP6_H, > - "icmp6_router_renum", "rr_hdr.icmp6_data32[0]", > - NULL, {"rr_seqnum"} }, > - { "ICMP6_RR_FLAGS_TEST", VALUE, ICMP6_H, > - "ICMP6_RR_FLAGS_TEST", NULL, NULL, {"0x80"} }, > - { "ICMP6_RR_FLAGS_REQRESULT", VALUE, ICMP6_H, > - "ICMP6_RR_FLAGS_REQRESULT", NULL, NULL, {"0x40"} }, > - { "ICMP6_RR_FLAGS_FORCEAPPLY", VALUE, ICMP6_H, > - "ICMP6_RR_FLAGS_FORCEAPPLY", NULL, NULL, {"0x20"} }, > - { "ICMP6_RR_FLAGS_SPECSITE", VALUE, ICMP6_H, > - "ICMP6_RR_FLAGS_SPECSITE", NULL, NULL, {"0x10"} }, > - { "ICMP6_RR_FLAGS_PREVDONE", VALUE, ICMP6_H, > - "ICMP6_RR_FLAGS_PREVDONE", NULL, NULL, {"0x08"} }, > - { "rr_pco_match rpm_code", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_code", "0", {"1"} }, > - { "rr_pco_match rpm_len", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_len", "1", {"1"} }, > - { "rr_pco_match rpm_ordinal", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_ordinal", "2", {"1"} }, > - { "rr_pco_match rpm_matchlen", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_matchlen", "3", {"1"} }, > - { "rr_pco_match rpm_minlen", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_minlen", "4", {"1"} }, > - { "rr_pco_match rpm_maxlen", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_maxlen", "5", {"1"} }, > - { "rr_pco_match rpm_reserved", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_reserved", "6", {"2"} }, > - { "rr_pco_match rpm_prefix", EXISTS, ICMP6_H, > - "rr_pco_match", "rpm_prefix", "8", > - {"sizeof(struct in6_addr)"} }, > - { "RPM_PCO_ADD", VALUE, ICMP6_H, "RPM_PCO_ADD", > - NULL, NULL, {"1"} }, > - { "RPM_PCO_CHANGE", VALUE, ICMP6_H, "RPM_PCO_CHANGE", > - NULL, NULL, {"2"} }, > - { "RPM_PCO_SETGLOBAL", VALUE, ICMP6_H, "RPM_PCO_SETGLOBAL", > - NULL, NULL, {"3"} }, > - { "rr_pco_use rpu_uselen", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_uselen", "0", {"1"} }, > - { "rr_pco_use rpu_keeplen", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_keeplen", "1", {"1"} }, > - { "rr_pco_use rpu_ramask", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_ramask", "2", {"1"} }, > - { "rr_pco_use rpu_raflags", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_raflags", "3", {"1"} }, > - { "rr_pco_use rpu_vltime", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_vltime", "4", {"4"} }, > - { "rr_pco_use rpu_pltime", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_pltime", "8", {"4"} }, > - { "rr_pco_use rpu_flags", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_flags", "12", {"4"} }, > - { "rr_pco_use rpu_prefix", EXISTS, ICMP6_H, "rr_pco_use", > - "rpu_prefix", "16", {"sizeof(struct in6_addr)"} }, > - { "ICMP6_RR_PCOUSE_RAFLAGS_ONLINK", VALUE, ICMP6_H, > - "ICMP6_RR_PCOUSE_RAFLAGS_ONLINK", NULL, NULL, {"0x20"} }, > - { "ICMP6_RR_PCOUSE_RAFLAGS_AUTO", VALUE, ICMP6_H, > - "ICMP6_RR_PCOUSE_RAFLAGS_AUTO", NULL, NULL, {"0x10"} }, > - { "ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME", VALUE, ICMP6_H, > - "ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME", NULL, NULL, > - {"htonl(0x80000000)"} }, > - { "ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME", VALUE, ICMP6_H, > - "ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME", NULL, NULL, > - {"htonl(0x40000000)"} }, > - { "rr_result rrr_flags", EXISTS, ICMP6_H, "rr_result", > - "rrr_flags", "0", {"2"} }, > - { "rr_result rrr_ordinal", EXISTS, ICMP6_H, "rr_result", > - "rrr_ordinal", "2", {"1"} }, > - { "rr_result rrr_matchedlen", EXISTS, ICMP6_H, "rr_result", > - "rrr_matchedlen", "3", {"1"} }, > - { "rr_result rrr_ifid", EXISTS, ICMP6_H, "rr_result", > - "rrr_ifid", "4", {"4"} }, > - { "rr_result rrr_prefix", EXISTS, ICMP6_H, "rr_result", > - "rrr_prefix", "8", {"sizeof(struct in6_addr)"} }, > - { "ICMP6_RR_RESULT_FLAGS_OOB", VALUE, ICMP6_H, > - "ICMP6_RR_RESULT_FLAGS_OOB", NULL, NULL, > - {"htons(0x0002)"} }, > - { "ICMP6_RR_RESULT_FLAGS_FORBIDDEN", VALUE, ICMP6_H, > - "ICMP6_RR_RESULT_FLAGS_FORBIDDEN", NULL, NULL, > - {"htons(0x0001)"} }, > -}; > - > -static void setup(void); > -static void do_test(const struct ftent *); > - > -char *TCID = "asapi_03"; > -int TST_TOTAL = ARRAY_SIZE(ftab); > - > -int main(int argc, char *argv[]) > -{ > - int i, lc; > - > - tst_parse_opts(argc, argv, NULL, NULL); > - > - setup(); > - > - for (lc = 0; TEST_LOOPING(lc); ++lc) { > - tst_count = 0; > - > - for (i = 0; i < TST_TOTAL; i++) > - do_test(&ftab[i]); > - } > - > - tst_exit(); > -} > - > -void setup(void) > -{ > - TEST_PAUSE; > -} > - > -void do_test(const struct ftent *ftptr) > -{ > - switch (ftptr->ft_type) { > - case EXISTS: > - structcheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_field, > - ftptr->ft_offset, ftptr->ft_value); > - break; > - case ALIAS: > - aliascheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_field, > - ftptr->ft_dname); > - break; > - case VALUE: > - valuecheck(ftptr->ft_tname, ftptr->ft_incl, > - ftptr->ft_struct, ftptr->ft_dname); > - break; > - default: > - tst_resm(TBROK, "invalid type %d", > - ftptr->ft_type); > - break; > - } > -} > diff --git a/testcases/network/lib6/asapi_05.c b/testcases/network/lib6/asapi_05.c > index b2e7d2a..e251eee 100644 > --- a/testcases/network/lib6/asapi_05.c > +++ b/testcases/network/lib6/asapi_05.c > @@ -47,14 +47,12 @@ > #include <netinet/icmp6.h> > > #include "test.h" > -#include "runcc.h" > > char *TCID = "asapi_05"; /* Test program identifier. */ > > void setup(void); > void cleanup(void); > > -void icmp6_et(void); > void icmp6_ft(void); > > int main(int argc, char *argv[]) > @@ -67,7 +65,6 @@ int main(int argc, char *argv[]) > setup(); > > for (lc = 0; TEST_LOOPING(lc); ++lc) { > - icmp6_et(); > icmp6_ft(); > } > > @@ -76,120 +73,6 @@ int main(int argc, char *argv[]) > tst_exit(); > } > > -enum ttype { EXISTS, ALIAS, VALUE, DEFINED }; > - > -struct etent { > - char *et_tname; /* test name */ > - int et_type; /* test type */ > - char *et_incl; /* include file list */ > - char *et_struct; /* structure name */ > - char *et_field; /* field name */ > - char *et_offset; /* field offset */ > - union { > - char *fu_value; /* field size or value */ > - char *fu_dname; /* #define name */ > - } ftun; > -#define et_value ftun.fu_value > -#define et_dname ftun.fu_dname > -} etab[] = { > -/* existence checks, RFC 3542 section 3 */ > - { > - "icmp6_filter icmp6_filt", EXISTS, ICMP6_H, "icmp6_filter", > - "icmp6_filt", "0", { > - "32"}}, { > - "icmp6_filter icmp6_filt[0]", EXISTS, ICMP6_H, "icmp6_filter", > - "icmp6_filt[0]", "0", { > - "4"}}, { > - "ICMP6_FILTER_WILLPASS", DEFINED, ICMP6_H, > - "ICMP6_FILTER_WILLPASS", NULL, NULL, { > - 0}}, { > - "ICMP6_FILTER_WILLBLOCK", DEFINED, ICMP6_H, > - "ICMP6_FILTER_WILLBLOCK", NULL, NULL, { > - 0}}, { > - "ICMP6_FILTER_SETPASS", DEFINED, ICMP6_H, > - "ICMP6_FILTER_SETPASS", NULL, NULL, { > - 0}}, { > - "ICMP6_FILTER_SETBLOCK", DEFINED, ICMP6_H, > - "ICMP6_FILTER_SETBLOCK", NULL, NULL, { > - 0}}, { > - "ICMP6_FILTER_SETPASSALL", DEFINED, ICMP6_H, > - "ICMP6_FILTER_SETPASSALL", NULL, NULL, { > - 0}}, { > - "ICMP6_FILTER_SETBLOCKALL", DEFINED, ICMP6_H, > - "ICMP6_FILTER_SETBLOCKALL", NULL, NULL, { > - 0}}, { > - "ICMP6_FILTER", DEFINED, ICMP6_H, "ICMP6_FILTER", NULL, NULL, { > - 0}}, > -/* existence checks, RFC 3542 section 4 */ > -/* socket options */ > - { > - "IPV6_RECVPKTINFO", VALUE, IN_H, "IPV6_RECVPKTINFO", NULL, NULL, { > - "IPV6_RECVPKTINFO"}}, { > - "IPV6_RECVHOPLIMIT", VALUE, IN_H, "IPV6_RECVHOPLIMIT", NULL, > - NULL, { > - "IPV6_RECVHOPLIMIT"}}, { > - "IPV6_RECVRTHDR", VALUE, IN_H, "IPV6_RECVRTHDR", NULL, NULL, { > - "IPV6_RECVRTHDR"}}, { > - "IPV6_RECVHOPOPTS", VALUE, IN_H, "IPV6_RECVHOPOPTS", NULL, NULL, { > - "IPV6_RECVHOPOPTS"}}, { > - "IPV6_RECVDSTOPTS", VALUE, IN_H, "IPV6_RECVDSTOPTS", NULL, NULL, { > - "IPV6_RECVDSTOPTS"}}, { > - "IPV6_RECVTCLASS", VALUE, IN_H, "IPV6_RECVTCLASS", NULL, NULL, { > - "IPV6_RECVTCLASS"}}, > -/* cmsg types */ > - { > - "IPV6_PKTINFO", DEFINED, IN_H, "IPV6_PKTINFO", NULL, NULL, { > - 0}}, { > - "IPV6_HOPLIMIT", DEFINED, IN_H, "IPV6_HOPLIMIT", NULL, NULL, { > - 0}}, { > - "IPV6_NEXTHOP", DEFINED, IN_H, "IPV6_NEXTHOP", NULL, NULL, { > - 0}}, { > - "IPV6_RTHDR", DEFINED, IN_H, "IPV6_RTHDR", NULL, NULL, { > - 0}}, { > - "IPV6_HOPOPTS", DEFINED, IN_H, "IPV6_HOPOPTS", NULL, NULL, { > - 0}}, { > - "IPV6_DSTOPTS", DEFINED, IN_H, "IPV6_DSTOPTS", NULL, NULL, { > - 0}}, { > - "IPV6_RTHDRDSTOPTS", DEFINED, IN_H, "IPV6_RTHDRDSTOPTS", NULL, > - NULL, { > - 0}}, { > - "IPV6_TCLASS", DEFINED, IN_H, "IPV6_TCLASS", NULL, NULL, { > -0}},}; > - > -#define ETCOUNT (sizeof(etab)/sizeof(etab[0])) > - > -/* existence tests */ > -void icmp6_et(void) > -{ > - int i; > - > - for (i = 0; i < ETCOUNT; ++i) { > - switch (etab[i].et_type) { > - case EXISTS: > - structcheck(etab[i].et_tname, etab[i].et_incl, > - etab[i].et_struct, etab[i].et_field, > - etab[i].et_offset, etab[i].et_value); > - break; > - case ALIAS: > - aliascheck(etab[i].et_tname, etab[i].et_incl, > - etab[i].et_struct, etab[i].et_field, > - etab[i].et_dname); > - break; > - case VALUE: > - valuecheck(etab[i].et_tname, etab[i].et_incl, > - etab[i].et_struct, etab[i].et_dname); > - break; > - case DEFINED: > - funccheck(etab[i].et_tname, etab[i].et_incl, > - etab[i].et_struct); > - break; > - default: > - tst_resm(TBROK, "invalid type %d", etab[i].et_type); > - break; > - } > - } > -} > - > void setup(void) > { > TEST_PAUSE; /* if -P option specified */ > @@ -414,4 +297,4 @@ void icmp6_ft(void) > } > } > > -int TST_TOTAL = ETCOUNT; > +int TST_TOTAL = FTCOUNT; > diff --git a/testcases/network/lib6/asapi_07.c b/testcases/network/lib6/asapi_07.c > deleted file mode 100644 > index 826cea6..0000000 > --- a/testcases/network/lib6/asapi_07.c > +++ /dev/null > @@ -1,144 +0,0 @@ > -/* > - * > - * Copyright (c) International Business Machines Corp., 2001 > - * Author: David L Stevens > - * > - * This program is free software; you can redistribute it and/or modify > - * it under the terms of the GNU General Public License as published by > - * the Free Software Foundation; either version 2 of the License, or > - * (at your option) any later version. > - * > - * This program is distributed in the hope that it will be useful, > - * but WITHOUT ANY WARRANTY; without even the implied warranty of > - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See > - * the GNU General Public License for more details. > - * > - * You should have received a copy of the GNU General Public License > - * along with this program; if not, write to the Free Software Foundation, > - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA > - */ > -/* > - * Description: > - * These tests are for the "Advanced Sockets API" (RFC 3542) > - * Section 20, ancillary data macros and structure definitions > - */ > - > -#include <stdio.h> > -#include <unistd.h> > -#include <errno.h> > - > -#include <sys/wait.h> > - > -#include <netinet/in.h> > -#include <netinet/ip6.h> > -#include <netinet/icmp6.h> > - > -#include "test.h" > -#include "runcc.h" > - > -enum ttype { EXISTS, ALIAS, VALUE, DEFINED }; > - > -static struct etent { > - char *et_tname; /* test name */ > - int et_type; /* test type */ > - char *et_incl; /* include file list */ > - char *et_struct; /* structure name */ > - char *et_field; /* field name */ > - char *et_offset; /* field offset */ > - union { > - char *fu_value; /* field size or value */ > - char *fu_dname; /* #define name */ > - } ftun; > -#define et_value ftun.fu_value > -#define et_dname ftun.fu_dname > -} etab[] = { > - /* existence checks, RFC 3542 sections 5, 20 */ > - { "msghdr msg_name", EXISTS, SOCKET_H, "msghdr", > - "msg_name", NULL, {"sizeof(void *)"} }, > - { "msghdr msg_namelen", EXISTS, SOCKET_H, "msghdr", > - "msg_namelen", NULL, {"sizeof(socklen_t)"} }, > - { "msghdr msg_iov", EXISTS, SOCKET_H, "msghdr", > - "msg_iov", NULL, {"sizeof(struct iovec *)"} }, > - { "msghdr msg_iovlen", EXISTS, SOCKET_H, "msghdr", > - "msg_iovlen", NULL, {"sizeof(size_t)"} }, > - { "msghdr msg_control", EXISTS, SOCKET_H, "msghdr", > - "msg_control", NULL, {"sizeof(void *)"} }, > - { "msghdr msg_controllen", EXISTS, SOCKET_H, "msghdr", > - "msg_controllen", NULL, {"sizeof(size_t)"} }, > - { "msghdr msg_flags", EXISTS, SOCKET_H, "msghdr", > - "msg_flags", NULL, {"sizeof(int)"} }, > - { "cmsghdr cmsg_len", EXISTS, SOCKET_H, "cmsghdr", > - "cmsg_len", NULL, {"sizeof(size_t)"} }, > - { "cmsghdr cmsg_level", EXISTS, SOCKET_H, "cmsghdr", > - "cmsg_level", NULL, {"sizeof(int)"} }, > - { "cmsghdr cmsg_type", EXISTS, SOCKET_H, "cmsghdr", > - "cmsg_type", NULL, {"sizeof(int)"} }, > - { "CMSG_DATA", DEFINED, SOCKET_H, "CMSG_DATA", > - NULL, NULL, {0} }, > - { "CMSG_NXTHDR", DEFINED, SOCKET_H, "CMSG_NXTHDR", > - NULL, NULL, {0} }, > - { "CMSG_FIRSTHDR", DEFINED, SOCKET_H, "CMSG_FIRSTHDR", > - NULL, NULL, {0} }, > - { "CMSG_SPACE", DEFINED, SOCKET_H, "CMSG_SPACE", > - NULL, NULL, {0} }, > - { "CMSG_LEN", DEFINED, SOCKET_H, "CMSG_LEN", > - NULL, NULL, {0} }, > -}; > - > -static void setup(void); > -static void adatet(const struct etent *etptr); > - > -char *TCID = "asapi_07"; > -int TST_TOTAL = ARRAY_SIZE(etab); > - > -int main(int argc, char *argv[]) > -{ > - int i, lc; > - > - tst_parse_opts(argc, argv, NULL, NULL); > - > - setup(); > - > - for (lc = 0; TEST_LOOPING(lc); ++lc) { > - tst_count = 0; > - > - for (i = 0; i < TST_TOTAL; i++) > - adatet(&etab[i]); > - } > - > - tst_exit(); > -} > - > -void setup(void) > -{ > - TEST_PAUSE; > -} > - > -/* existence tests */ > -void adatet(const struct etent *etptr) > -{ > - switch (etptr->et_type) { > - case EXISTS: > - structcheck(etptr->et_tname, etptr->et_incl, > - etptr->et_struct, etptr->et_field, > - etptr->et_offset, etptr->et_value); > - break; > - case ALIAS: > - aliascheck(etptr->et_tname, etptr->et_incl, > - etptr->et_struct, etptr->et_field, > - etptr->et_dname); > - break; > - case VALUE: > - valuecheck(etptr->et_tname, etptr->et_incl, > - etptr->et_struct, etptr->et_dname); > - break; > - case DEFINED: > - funccheck(etptr->et_tname, etptr->et_incl, > - etptr->et_struct); > - break; > - default: > - tst_resm(TBROK, "invalid type %d", > - etptr->et_type); > - break; > - } > -} > diff --git a/testcases/network/lib6/runcc.c b/testcases/network/lib6/runcc.c > deleted file mode 100644 > index 91a0b16..0000000 > --- a/testcases/network/lib6/runcc.c > +++ /dev/null > @@ -1,209 +0,0 @@ > -/* > - * > - * Copyright (c) International Business Machines Corp., 2001 > - * > - * This program is free software; you can redistribute it and/or modify > - * it under the terms of the GNU General Public License as published by > - * the Free Software Foundation; either version 2 of the License, or > - * (at your option) any later version. > - * > - * This program is distributed in the hope that it will be useful, > - * but WITHOUT ANY WARRANTY; without even the implied warranty of > - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See > - * the GNU General Public License for more details. > - * > - * You should have received a copy of the GNU General Public License > - * along with this program; if not, write to the Free Software > - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA > - */ > - > -/* > - * runcc.a - common functions for lib6 testing > - * > - * HISTORY > - * 05/2005 written by David L Stevens > - * > - * RESTRICTIONS: > - * None. > - * > - */ > - > -#include <stdio.h> > -#include <unistd.h> > -#include <errno.h> > -#include <ctype.h> > - > -#include <sys/wait.h> > - > -#include "test.h" > - > -char fieldref[1024]; > -char program[8192]; > - > -char *filetmpl = "/tmp/%.*s_XXXXXX"; > - > -char cmd[1024]; > - > -/* > - * like strspn, with ASCII, numbers and underscore only > - */ > -int strfpn(char *name) > -{ > - int i; > - > - for (i = 0; *name; ++name, ++i) > - if (!(isalnum(*name) || *name == '_')) > - break; > - return i; > -} > - > -int runcc(char *tname, char *filename0, char *program) > -{ > - static char filename[1024]; > - int fd, es, saved_errno; > - char *cflags = ""; > - > - fd = mkstemp(filename0); > - if (fd < 0) { > - perror("mkstemp"); > - return -1; > - } > - strncpy(filename, filename0, sizeof(filename) - 1); > - filename[sizeof(filename) - 1] = '\0'; > - strncat(filename, ".c", sizeof(filename) - strlen(filename) - 1); > - if (rename(filename0, filename) < 0) { > - perror("rename"); > - unlink(filename0); > - return -1; > - } > - if (write(fd, program, strlen(program)) < 0) { > - perror("write"); > - unlink(filename); > - return -1; > - } > - (void)close(fd); > - > - cflags = getenv("CFLAGS"); > - if (cflags == NULL) { > - tst_resm(TINFO, "CFLAGS not found, using default cc arch."); > - cflags = ""; > - } > - > - snprintf(cmd, sizeof(cmd), "%s %s -o %s %s > /tmp/test 2>&1", "cc", > - cflags, filename0, filename); > - es = system(cmd); > - if (WEXITSTATUS(es) == 127) { > - tst_resm(TBROK, "can't run C compiler: \"%s\"", cmd); > - if (unlink(filename) < 0) > - tst_resm(TWARN, "%s; unlink \"%s\" failed: %s", tname, > - filename, strerror(errno)); > - return -1; > - } > - if (unlink(filename) < 0) > - tst_resm(TWARN, "%s: unlink \"%s\" failed: %s", tname, > - filename, strerror(errno)); > - > - if (WIFSIGNALED(es) && > - (WTERMSIG(es) == SIGINT || WTERMSIG(es) == SIGQUIT)) > - exit(1); > - > - if (WEXITSTATUS(es)) { > - tst_resm(TFAIL, "%s: not present", tname); > - return -1; > - } > - /* run the test */ > - > - es = system(filename0); > - saved_errno = errno; > - if (unlink(filename0) < 0) > - tst_resm(TWARN, "%s: unlink \"%s\" failed: %s", tname, > - filename0, strerror(errno)); > - > - if (WIFSIGNALED(es) && > - (WTERMSIG(es) == SIGINT || WTERMSIG(es) == SIGQUIT)) > - exit(1); > - > - if (WEXITSTATUS(es) == 127) > - tst_resm(TBROK, "%s: can't run \"%s\": %s", tname, filename0, > - strerror(saved_errno)); > - if (WEXITSTATUS(es)) > - tst_resm(TFAIL, "%s: present, but incorrect", tname); > - else > - tst_resm(TPASS, "%s present and correct", tname); > - return 0; > -} > - > -char *field_fmt = "\n\texit((offsetof(struct %s, %s) != %s) || " > - "sizeof(tst.%s) != (%s));\n"; > -/* no offset check */ > -char *field_fmt2 = "\n\texit(sizeof(tst.%s) != (%s));\n"; > - > -const char *stmpl = > - "%s\n#ifndef offsetof\n" > - "#define offsetof(dtype, dfield) ((int)&((dtype *)0)->dfield)\n" > - "#endif\n\nstruct %s tst;\n\nmain(int argc, char *argv[])\n{\n\t%s\n}\n"; > - > -int > -structcheck(char *tname, char *incl, char *structure, char *field, > - char *offset, char *size) > -{ > - int rv; > - static char filename[1024]; > - > - if (offset) > - sprintf(fieldref, field_fmt, structure, field, offset, field, > - size); > - else > - sprintf(fieldref, field_fmt2, field, size); > - sprintf(program, stmpl, incl, structure, fieldref); > - snprintf(filename, sizeof(filename), filetmpl, strfpn(structure), > - structure); > - rv = runcc(tname, filename, program); > - return rv; > -} > - > -char *aliasfmt = > - "exit(&tst.%s != &tst.%s || sizeof(tst.%s) != sizeof(tst.%s));"; > - > -int > -aliascheck(char *tname, char *incl, char *structure, char *field, char *dname) > -{ > - int rv; > - static char filename[1024]; > - > - sprintf(fieldref, aliasfmt, field, dname, field, dname); > - sprintf(program, stmpl, incl, structure, fieldref); > - snprintf(filename, sizeof(filename), filetmpl, strfpn(structure), > - structure); > - rv = runcc(tname, filename, program); > - return rv; > -} > - > -const char *dtmpl = > - "%s\n\nmain(int argc, char *argv[])\n{\n\texit((%s) != (%s));\n}\n"; > - > -int valuecheck(char *tname, char *incl, char *dname, char *dval) > -{ > - int rv; > - static char filename[1024]; > - > - sprintf(program, dtmpl, incl, dname, dval); > - snprintf(filename, sizeof(filename), filetmpl, strfpn(dname), dname); > - rv = runcc(tname, filename, program); > - return rv; > -} > - > -const char *ftmpl = > - "%s\n\nmain(int argc, char *argv[])\n{\n#ifdef %s\n\texit(0);\n#else\n" > - "\tsyntax error;\n#endif\n}\n"; > - > -int funccheck(char *tname, char *incl, char *fname) > -{ > - int rv; > - static char filename[1024]; > - > - sprintf(program, ftmpl, incl, fname); > - snprintf(filename, sizeof(filename), filetmpl, strfpn(fname), fname); > - rv = runcc(tname, filename, program); > - return rv; > -} > diff --git a/testcases/network/lib6/runcc.h b/testcases/network/lib6/runcc.h > deleted file mode 100644 > index 4e2a0d5..0000000 > --- a/testcases/network/lib6/runcc.h > +++ /dev/null > @@ -1,30 +0,0 @@ > -/* > - * > - * Copyright (c) International Business Machines Corp., 2001 > - * > - * This program is free software; you can redistribute it and/or modify > - * it under the terms of the GNU General Public License as published by > - * the Free Software Foundation; either version 2 of the License, or > - * (at your option) any later version. > - * > - * This program is distributed in the hope that it will be useful, > - * but WITHOUT ANY WARRANTY; without even the implied warranty of > - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See > - * the GNU General Public License for more details. > - * > - * You should have received a copy of the GNU General Public License > - * along with this program; if not, write to the Free Software > - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA > - */ > - > -int aliascheck(char *tname, char *incl, char *structure, char *field, > - char *dname); > -int funccheck(char *tname, char *incl, char *fname); > -int structcheck(char *tname, char *incl, char *structure, char *field, > - char *offset, char *size); > -int valuecheck(char *tname, char *incl, char *dname, char *dval); > - > -#define IP6_H "#include <netinet/ip6.h>\n" > -#define IN_H "#include <netinet/in.h>\n" > -#define ICMP6_H "#include <netinet/icmp6.h>\n" > -#define SOCKET_H "#include <sys/types.h>\n#include <sys/socket.h>\n" |
From: xcf733520 <xcf...@si...> - 2015-09-09 06:58:07
|
> >Hi, >On 09/08/2015 02:39 PM, xcf733520 wrote: >> Hi all, >> >> I try to run testscript in the directory of /opt/ltp/testscripts, when try networkstress.sh/networktests.sh it show as below, >> >> ./network.sh: line 5: test_net.sh: No such file or directory > >test_net.sh script should be in the PATH. Usually, installation >directory /opt/ltp/testcases/bin is set to the PATH. Then you can run >./networktests.sh. > >Alternatively, you can try to set the PATH to networkstress.sh or >networktests.sh: > >$ PATH=/opt/ltp/testcases/bin:$PATH ./networktests.sh > >Thanks, >Alexey > > > Hi Alexey, Thanks for your help, add the $PATH "PATH=/opt/ltp/testcases/bin:$PATH" , it can be run normally. |
From: Guangwen F. <fen...@cn...> - 2015-09-09 03:14:36
|
Hello! ping, thanks! Best Regards, Guangwen Feng On 2015/08/17 18:42, Guangwen Feng wrote: > Add new testcase to verify that a write lease may be placed > on a file only if there are no other open file descriptors > for the file. > > Signed-off-by: Guangwen Feng <fen...@cn...> > --- > runtest/ltplite | 1 + > runtest/stress.part3 | 1 + > runtest/syscalls | 2 + > testcases/kernel/syscalls/.gitignore | 2 + > testcases/kernel/syscalls/fcntl/fcntl32.c | 137 ++++++++++++++++++++++++++++++ > 5 files changed, 143 insertions(+) > create mode 100644 testcases/kernel/syscalls/fcntl/fcntl32.c > > diff --git a/runtest/ltplite b/runtest/ltplite > index ab6424c..e3ae8cf 100644 > --- a/runtest/ltplite > +++ b/runtest/ltplite > @@ -225,6 +225,7 @@ fcntl26 fcntl26 > fcntl29 fcntl29 > fcntl30 fcntl30 > fcntl31 fcntl31 > +fcntl32 fcntl32 > > fdatasync01 fdatasync01 > fdatasync02 fdatasync02 > diff --git a/runtest/stress.part3 b/runtest/stress.part3 > index ab9af3c..ca8b70c 100644 > --- a/runtest/stress.part3 > +++ b/runtest/stress.part3 > @@ -164,6 +164,7 @@ fcntl26 fcntl26 > fcntl29 fcntl29 > fcntl30 fcntl30 > fcntl31 fcntl31 > +fcntl32 fcntl32 > > fdatasync01 fdatasync01 > fdatasync02 fdatasync02 > diff --git a/runtest/syscalls b/runtest/syscalls > index ee2627f..a641bcd 100644 > --- a/runtest/syscalls > +++ b/runtest/syscalls > @@ -258,6 +258,8 @@ fcntl30 fcntl30 > fcntl30_64 fcntl30_64 > fcntl31 fcntl31 > fcntl31_64 fcntl31_64 > +fcntl32 fcntl32 > +fcntl32_64 fcntl32_64 > > fdatasync01 fdatasync01 > fdatasync02 fdatasync02 > diff --git a/testcases/kernel/syscalls/.gitignore b/testcases/kernel/syscalls/.gitignore > index 18c0ad6..2b288e0 100644 > --- a/testcases/kernel/syscalls/.gitignore > +++ b/testcases/kernel/syscalls/.gitignore > @@ -221,6 +221,8 @@ > /fcntl/fcntl30_64 > /fcntl/fcntl31 > /fcntl/fcntl31_64 > +/fcntl/fcntl32 > +/fcntl/fcntl32_64 > /fdatasync/fdatasync01 > /fdatasync/fdatasync02 > /flock/flock01 > diff --git a/testcases/kernel/syscalls/fcntl/fcntl32.c b/testcases/kernel/syscalls/fcntl/fcntl32.c > new file mode 100644 > index 0000000..05d963e > --- /dev/null > +++ b/testcases/kernel/syscalls/fcntl/fcntl32.c > @@ -0,0 +1,137 @@ > +/* > + * Copyright (c) 2015 Fujitsu Ltd. > + * Author: Guangwen Feng <fen...@cn...> > + * > + * This program is free software; you can redistribute it and/or modify it > + * under the terms of version 2 of the GNU General Public License as > + * published by the Free Software Foundation. > + * > + * This program is distributed in the hope that it would be useful, but > + * WITHOUT ANY WARRANTY; without even the implied warranty of > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. > + * > + * You should have received a copy of the GNU General Public License > + * alone with this program. > + */ > + > +/* > + * DESCRIPTION > + * Basic test for fcntl(2) using F_SETLEASE & F_WRLCK argument. > + * "A write lease may be placed on a file only if there are > + * no other open file descriptors for the file." > + */ > + > +#include <errno.h> > + > +#include "test.h" > +#include "safe_macros.h" > +#include "tst_fs_type.h" > + > +static void setup(void); > +static void verify_fcntl(int); > +static void cleanup(void); > + > +#define FILE_MODE (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID) > + > +static int fd1; > +static int fd2; > + > +static struct test_case_t { > + int fd1_flag; > + int fd2_flag; > +} test_cases[] = { > + {O_RDONLY, O_RDONLY}, > + {O_RDONLY, O_WRONLY}, > + {O_RDONLY, O_RDWR}, > + {O_WRONLY, O_RDONLY}, > + {O_WRONLY, O_WRONLY}, > + {O_WRONLY, O_RDWR}, > + {O_RDWR, O_RDONLY}, > + {O_RDWR, O_WRONLY}, > + {O_RDWR, O_RDWR}, > +}; > + > +char *TCID = "fcntl32"; > +int TST_TOTAL = ARRAY_SIZE(test_cases); > + > +int main(int ac, char **av) > +{ > + int lc; > + int tc; > + long type; > + > + tst_parse_opts(ac, av, NULL, NULL); > + > + setup(); > + > + switch ((type = tst_fs_type(cleanup, "."))) { > + case TST_NFS_MAGIC: > + case TST_RAMFS_MAGIC: > + case TST_TMPFS_MAGIC: > + tst_brkm(TCONF, cleanup, "%s filesystem does not support " > + "fcntl(2)'s F_SETLEASE operation", > + tst_fs_type_name(type)); > + default: > + break; > + } > + > + for (lc = 0; TEST_LOOPING(lc); lc++) { > + tst_count = 0; > + > + for (tc = 0; tc < TST_TOTAL; tc++) > + verify_fcntl(tc); > + } > + > + cleanup(); > + tst_exit(); > +} > + > +static void setup(void) > +{ > + tst_sig(NOFORK, DEF_HANDLER, cleanup); > + TEST_PAUSE; > + > + tst_tmpdir(); > + > + SAFE_TOUCH(cleanup, "file", FILE_MODE, NULL); > +} > + > +static void verify_fcntl(int i) > +{ > + fd1 = SAFE_OPEN(cleanup, "file", test_cases[i].fd1_flag); > + fd2 = SAFE_OPEN(cleanup, "file", test_cases[i].fd2_flag); > + > + TEST(fcntl(fd1, F_SETLEASE, F_WRLCK)); > + > + if (TEST_RETURN == 0) { > + tst_resm(TFAIL, "fcntl(F_SETLEASE, F_WRLCK) " > + "succeeded unexpectedly"); > + } else { > + if (TEST_ERRNO == EBUSY || TEST_ERRNO == EAGAIN) { > + tst_resm(TPASS | TTERRNO, > + "fcntl(F_SETLEASE, F_WRLCK) " > + "failed as expected"); > + } else { > + tst_resm(TFAIL | TTERRNO, > + "fcntl(F_SETLEASE, F_WRLCK) " > + "failed unexpectedly, " > + "expected errno is EBUSY or EAGAIN"); > + } > + } > + > + SAFE_CLOSE(cleanup, fd1); > + fd1 = 0; > + SAFE_CLOSE(cleanup, fd2); > + fd2 = 0; > +} > + > +static void cleanup(void) > +{ > + if (fd1 > 0 && close(fd1)) > + tst_resm(TWARN | TERRNO, "Failed to close file"); > + > + if (fd2 > 0 && close(fd2)) > + tst_resm(TWARN | TERRNO, "Failed to close file"); > + > + tst_rmdir(); > +} > |
From: Cedric H. <ch...@su...> - 2015-09-08 13:01:52
|
Signed-off-by: Cedric Hnyda <ch...@su...> --- runtest/controllers | 197 ++++++++++++++++++++- .../controllers/cgroup_fj/cgroup_fj_testcases.sh | 194 -------------------- .../controllers/cgroup_fj/run_cgroup_test_fj.sh | 76 ++++---- 3 files changed, 235 insertions(+), 232 deletions(-) delete mode 100644 testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh diff --git a/runtest/controllers b/runtest/controllers index 7ec8ab2..6a819a1 100644 --- a/runtest/controllers +++ b/runtest/controllers @@ -10,7 +10,202 @@ memcg_use_hierarchy memcg_use_hierarchy_test.sh memcg_usage_in_bytes memcg_usage_in_bytes_test.sh memcg_stress memcg_stress_test.sh memcg_control PAGESIZE=$(mem_process -p);memcg_control_test.sh $PAGESIZE $PAGESIZE $((PAGESIZE * 2)) -cgroup_fj run_cgroup_test_fj.sh + +function_debug_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 1 +function_debug_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug no yes 1 yes 2 3 2 1 +function_debug_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 2 yes 2 3 2 1 +function_debug_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 1 +function_debug_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 4 yes 2 3 2 1 +function_debug_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 5 yes 2 3 2 1 +function_debug_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 6 yes 2 3 2 1 +function_debug_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 7 yes 2 3 2 1 +function_debug_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 8 yes 2 3 2 1 +function_cpuset_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 1 yes 2 3 2 1 +function_cpuset_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset no yes 1 yes 2 3 2 1 +function_cpuset_yes_no_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes no 1 yes 2 3 2 1 +function_cpuset_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 2 yes 2 3 2 1 +function_cpuset_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 3 yes 2 3 2 1 +function_cpuset_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 4 yes 2 3 2 1 +function_cpuset_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 5 yes 2 3 2 1 +function_cpuset_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 6 yes 2 3 2 1 +function_cpuset_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 7 yes 2 3 2 1 +function_cpuset_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuset yes yes 8 yes 2 3 2 1 +function_ns_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 1 yes 2 3 2 1 +function_ns_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function ns no yes 1 yes 2 3 2 1 +function_ns_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 2 yes 2 3 2 1 +function_ns_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 3 yes 2 3 2 1 +function_ns_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 4 yes 2 3 2 1 +function_ns_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 5 yes 2 3 2 1 +function_ns_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 6 yes 2 3 2 1 +function_ns_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 7 yes 2 3 2 1 +function_ns_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function ns yes yes 8 yes 2 3 2 1 +function_cpu_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 1 yes 2 3 2 1 +function_cpu_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu no yes 1 yes 2 3 2 1 +function_cpu_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 2 yes 2 3 2 1 +function_cpu_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 3 yes 2 3 2 1 +function_cpu_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 4 yes 2 3 2 1 +function_cpu_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 5 yes 2 3 2 1 +function_cpu_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 6 yes 2 3 2 1 +function_cpu_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 7 yes 2 3 2 1 +function_cpu_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function cpu yes yes 8 yes 2 3 2 1 +function_cpuacct_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 1 yes 2 3 2 1 +function_cpuacct_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct no yes 1 yes 2 3 2 1 +function_cpuacct_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 2 yes 2 3 2 1 +function_cpuacct_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 3 yes 2 3 2 1 +function_cpuacct_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 4 yes 2 3 2 1 +function_cpuacct_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 5 yes 2 3 2 1 +function_cpuacct_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 6 yes 2 3 2 1 +function_cpuacct_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 7 yes 2 3 2 1 +function_cpuacct_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function cpuacct yes yes 8 yes 2 3 2 1 +function_memory_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 1 yes 2 3 2 1 +function_memory_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function memory no yes 1 yes 2 3 2 1 +function_memory_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 2 yes 2 3 2 1 +function_memory_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 3 yes 2 3 2 1 +function_memory_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 4 yes 2 3 2 1 +function_memory_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 5 yes 2 3 2 1 +function_memory_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 6 yes 2 3 2 1 +function_memory_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 7 yes 2 3 2 1 +function_memory_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function memory yes yes 8 yes 2 3 2 1 +function_all_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 1 yes 2 3 2 1 +function_all_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function all no yes 1 yes 2 3 2 1 +function_all_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 2 yes 2 3 2 1 +function_all_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 3 yes 2 3 2 1 +function_all_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 4 yes 2 3 2 1 +function_all_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 5 yes 2 3 2 1 +function_all_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 6 yes 2 3 2 1 +function_all_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 7 yes 2 3 2 1 +function_all_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function all yes yes 8 yes 2 3 2 1 +function_none_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function none yes yes 1 yes 2 3 2 1 +function_debug,debug_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 1 yes 2 3 2 1 +function_debug,debug_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug no yes 1 yes 2 3 2 1 +function_debug,debug_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 2 yes 2 3 2 1 +function_debug,debug_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 3 yes 2 3 2 1 +function_debug,debug_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 4 yes 2 3 2 1 +function_debug,debug_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 5 yes 2 3 2 1 +function_debug,debug_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 6 yes 2 3 2 1 +function_debug,debug_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 7 yes 2 3 2 1 +function_debug,debug_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function debug,debug yes yes 8 yes 2 3 2 1 +function_nonexistent_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function nonexistent yes yes 1 yes 2 3 2 1 +function_freezer_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 1 yes 2 3 2 1 +function_freezer_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer no yes 1 yes 2 3 2 1 +function_freezer_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 2 yes 2 3 2 1 +function_freezer_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 3 yes 2 3 2 1 +function_freezer_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 4 yes 2 3 2 1 +function_freezer_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 5 yes 2 3 2 1 +function_freezer_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 6 yes 2 3 2 1 +function_freezer_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 7 yes 2 3 2 1 +function_freezer_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function freezer yes yes 8 yes 2 3 2 1 +function_devices_yes_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 1 yes 2 3 2 1 +function_devices_no_yes_1_yes_2_3_2_1 run_cgroup_test_fj.sh function devices no yes 1 yes 2 3 2 1 +function_devices_yes_yes_2_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 2 yes 2 3 2 1 +function_devices_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 3 yes 2 3 2 1 +function_devices_yes_yes_4_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 4 yes 2 3 2 1 +function_devices_yes_yes_5_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 5 yes 2 3 2 1 +function_devices_yes_yes_6_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 6 yes 2 3 2 1 +function_devices_yes_yes_7_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 7 yes 2 3 2 1 +function_devices_yes_yes_8_yes_2_3_2_1 run_cgroup_test_fj.sh function devices yes yes 8 yes 2 3 2 1 +function_debug_yes_yes_1_yes_1_2_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 1 2 1 1 +function_debug_yes_yes_1_yes_2_2_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 2 1 1 +function_debug_yes_yes_1_yes_2_3_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 1 1 +function_debug_yes_yes_1_yes_2_5_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 5 1 1 +function_debug_yes_yes_1_yes_3_1_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 3 1 1 1 +function_debug_yes_yes_1_yes_3_2_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 3 2 1 1 +function_debug_yes_yes_1_yes_3_4_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 3 4 1 1 +function_debug_yes_yes_1_yes_4_3_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 4 3 1 1 +function_debug_yes_yes_1_yes_4_5_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 4 5 1 1 +function_debug_yes_yes_1_no_1_1_1_1 run_cgroup_test_fj.sh function debug yes yes 1 no 1 1 1 1 +function_debug_yes_yes_1_yes_1_1_1_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 1 1 1 1 +function_debug_yes_yes_1_yes_1_3_2_1 run_cgroup_test_fj.sh function debug yes yes 1 yes 1 3 2 1 +function_debug_yes_yes_1_yes_2_3_2_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 2 +function_debug_yes_yes_1_yes_2_3_2_3 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 3 +function_debug_yes_yes_1_yes_2_3_2_4 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 4 +function_debug_yes_yes_1_yes_2_3_2_5 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 5 +function_debug_yes_yes_1_yes_2_3_2_6 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 6 +function_debug_yes_yes_1_yes_2_3_2_7 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 2 7 +function_debug_yes_yes_1_yes_2_3_3_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 3 2 +function_debug_yes_yes_1_yes_2_3_4_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 4 2 +function_debug_yes_yes_1_yes_2_3_5_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 5 2 +function_debug_yes_yes_1_yes_2_3_6_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 6 2 +function_debug_yes_yes_1_yes_2_3_7_2 run_cgroup_test_fj.sh function debug yes yes 1 yes 2 3 7 2 +function_debug_yes_yes_2_yes_2_3_2_2 run_cgroup_test_fj.sh function debug yes yes 2 yes 2 3 2 2 +function_debug_yes_yes_3_yes_2_3_1_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 1 1 +function_debug_yes_yes_3_yes_2_3_1_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 1 2 +function_debug_yes_yes_3_yes_2_3_1_3 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 1 3 +function_debug_yes_yes_3_yes_2_3_2_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 1 +function_debug_yes_yes_3_yes_2_3_2_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 2 +function_debug_yes_yes_3_yes_2_3_2_3 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 3 +function_debug_yes_yes_3_yes_2_3_2_4 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 4 +function_debug_yes_yes_3_yes_2_3_2_5 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 5 +function_debug_yes_yes_3_yes_2_3_2_6 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 6 +function_debug_yes_yes_3_yes_2_3_2_7 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 2 7 +function_debug_yes_yes_3_yes_2_3_3_1 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 3 1 +function_debug_yes_yes_3_yes_2_3_3_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 3 2 +function_debug_yes_yes_3_yes_2_3_3_3 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 3 3 +function_debug_yes_yes_3_yes_2_3_4_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 4 2 +function_debug_yes_yes_3_yes_2_3_5_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 5 2 +function_debug_yes_yes_3_yes_2_3_6_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 6 2 +function_debug_yes_yes_3_yes_2_3_7_2 run_cgroup_test_fj.sh function debug yes yes 3 yes 2 3 7 2 +function2_1 run_cgroup_test_fj.sh function2 1 +function2_2 run_cgroup_test_fj.sh function2 2 +function2_3 run_cgroup_test_fj.sh function2 3 +function2_4 run_cgroup_test_fj.sh function2 4 +function2_5 run_cgroup_test_fj.sh function2 5 +function2_6 run_cgroup_test_fj.sh function2 6 +function2_7 run_cgroup_test_fj.sh function2 7 +function2_8 run_cgroup_test_fj.sh function2 8 +function2_9 run_cgroup_test_fj.sh function2 9 +function2_10 run_cgroup_test_fj.sh function2 10 +function2_11 run_cgroup_test_fj.sh function2 11 +function2_12 run_cgroup_test_fj.sh function2 12 +function2_13 run_cgroup_test_fj.sh function2 13 +stress_debug_100_1_1_1 run_cgroup_test_fj.sh stress debug 100 1 1 1 +stress_cpuset_100_1_1_1 run_cgroup_test_fj.sh stress cpuset 100 1 1 1 +stress_ns_100_1_1_1 run_cgroup_test_fj.sh stress ns 100 1 1 1 +stress_cpu_100_1_1_1 run_cgroup_test_fj.sh stress cpu 100 1 1 1 +stress_cpuacct_100_1_1_1 run_cgroup_test_fj.sh stress cpuacct 100 1 1 1 +stress_memory_100_1_1_1 run_cgroup_test_fj.sh stress memory 100 1 1 1 +stress_all_100_1_1_1 run_cgroup_test_fj.sh stress all 100 1 1 1 +stress_debug_1_1_1_2 run_cgroup_test_fj.sh stress debug 1 1 1 2 +stress_debug_1_1_100_1 run_cgroup_test_fj.sh stress debug 1 1 100 1 +stress_debug_1_1_100_2 run_cgroup_test_fj.sh stress debug 1 1 100 2 +stress_debug_1_1_100_3 run_cgroup_test_fj.sh stress debug 1 1 100 3 +stress_debug_1_100_1_1 run_cgroup_test_fj.sh stress debug 1 100 1 1 +stress_debug_1_100_1_2 run_cgroup_test_fj.sh stress debug 1 100 1 2 +stress_debug_1_100_1_3 run_cgroup_test_fj.sh stress debug 1 100 1 3 +stress_debug_1_100_100_1 run_cgroup_test_fj.sh stress debug 1 100 100 1 +stress_debug_1_100_100_2 run_cgroup_test_fj.sh stress debug 1 100 100 2 +stress_cpuset_1_1_1_2 run_cgroup_test_fj.sh stress cpuset 1 1 1 2 +stress_cpuset_1_1_100_1 run_cgroup_test_fj.sh stress cpuset 1 1 100 1 +stress_cpuset_1_1_100_2 run_cgroup_test_fj.sh stress cpuset 1 1 100 2 +stress_cpuset_1_1_100_3 run_cgroup_test_fj.sh stress cpuset 1 1 100 3 +stress_cpuset_1_100_1_1 run_cgroup_test_fj.sh stress cpuset 1 100 1 1 +stress_cpuset_1_100_1_2 run_cgroup_test_fj.sh stress cpuset 1 100 1 2 +stress_cpuset_1_100_1_3 run_cgroup_test_fj.sh stress cpuset 1 100 1 3 +stress_cpuset_1_100_100_1 run_cgroup_test_fj.sh stress cpuset 1 100 100 1 +stress_cpuset_1_100_100_2 run_cgroup_test_fj.sh stress cpuset 1 100 100 2 +stress_cpu_1_1_1_2 run_cgroup_test_fj.sh stress cpu 1 1 1 2 +stress_cpu_1_100_1_1 run_cgroup_test_fj.sh stress cpu 1 100 1 1 +stress_cpu_1_100_1_2 run_cgroup_test_fj.sh stress cpu 1 100 1 2 +stress_cpu_1_100_1_3 run_cgroup_test_fj.sh stress cpu 1 100 1 3 +stress_cpuacct_1_1_1_2 run_cgroup_test_fj.sh stress cpuacct 1 1 1 2 +stress_cpuacct_1_1_100_1 run_cgroup_test_fj.sh stress cpuacct 1 1 100 1 +stress_cpuacct_1_1_100_2 run_cgroup_test_fj.sh stress cpuacct 1 1 100 2 +stress_cpuacct_1_1_100_3 run_cgroup_test_fj.sh stress cpuacct 1 1 100 3 +stress_cpuacct_1_100_1_1 run_cgroup_test_fj.sh stress cpuacct 1 100 1 1 +stress_cpuacct_1_100_1_2 run_cgroup_test_fj.sh stress cpuacct 1 100 1 2 +stress_cpuacct_1_100_1_3 run_cgroup_test_fj.sh stress cpuacct 1 100 1 3 +stress_cpuacct_1_100_100_1 run_cgroup_test_fj.sh stress cpuacct 1 100 100 1 +stress_cpuacct_1_100_100_2 run_cgroup_test_fj.sh stress cpuacct 1 100 100 2 +stress_memory_1_1_1_2 run_cgroup_test_fj.sh stress memory 1 1 1 2 +stress_memory_1_1_100_1 run_cgroup_test_fj.sh stress memory 1 1 100 1 +stress_memory_1_1_100_2 run_cgroup_test_fj.sh stress memory 1 1 100 2 +stress_memory_1_1_100_3 run_cgroup_test_fj.sh stress memory 1 1 100 3 +stress_memory_1_100_1_1 run_cgroup_test_fj.sh stress memory 1 100 1 1 +stress_memory_1_100_1_2 run_cgroup_test_fj.sh stress memory 1 100 1 2 +stress_memory_1_100_1_3 run_cgroup_test_fj.sh stress memory 1 100 1 3 +stress_memory_1_100_100_1 run_cgroup_test_fj.sh stress memory 1 100 100 1 +stress_memory_1_100_100_2 run_cgroup_test_fj.sh stress memory 1 100 100 2 + controllers test_controllers.sh cpuset_base_ops cpuset_base_ops_testset.sh diff --git a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh b/testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh deleted file mode 100644 index a03918a..0000000 --- a/testcases/kernel/controllers/cgroup_fj/cgroup_fj_testcases.sh +++ /dev/null @@ -1,194 +0,0 @@ -function debug yes yes 1 yes 2 3 2 1 -function debug no yes 1 yes 2 3 2 1 -function debug yes yes 2 yes 2 3 2 1 -function debug yes yes 3 yes 2 3 2 1 -function debug yes yes 4 yes 2 3 2 1 -function debug yes yes 5 yes 2 3 2 1 -function debug yes yes 6 yes 2 3 2 1 -function debug yes yes 7 yes 2 3 2 1 -function debug yes yes 8 yes 2 3 2 1 -function cpuset yes yes 1 yes 2 3 2 1 -function cpuset no yes 1 yes 2 3 2 1 -function cpuset yes no 1 yes 2 3 2 1 -function cpuset yes yes 2 yes 2 3 2 1 -function cpuset yes yes 3 yes 2 3 2 1 -function cpuset yes yes 4 yes 2 3 2 1 -function cpuset yes yes 5 yes 2 3 2 1 -function cpuset yes yes 6 yes 2 3 2 1 -function cpuset yes yes 7 yes 2 3 2 1 -function cpuset yes yes 8 yes 2 3 2 1 -function ns yes yes 1 yes 2 3 2 1 -function ns no yes 1 yes 2 3 2 1 -function ns yes yes 2 yes 2 3 2 1 -function ns yes yes 3 yes 2 3 2 1 -function ns yes yes 4 yes 2 3 2 1 -function ns yes yes 5 yes 2 3 2 1 -function ns yes yes 6 yes 2 3 2 1 -function ns yes yes 7 yes 2 3 2 1 -function ns yes yes 8 yes 2 3 2 1 -function cpu yes yes 1 yes 2 3 2 1 -function cpu no yes 1 yes 2 3 2 1 -function cpu yes yes 2 yes 2 3 2 1 -function cpu yes yes 3 yes 2 3 2 1 -function cpu yes yes 4 yes 2 3 2 1 -function cpu yes yes 5 yes 2 3 2 1 -function cpu yes yes 6 yes 2 3 2 1 -function cpu yes yes 7 yes 2 3 2 1 -function cpu yes yes 8 yes 2 3 2 1 -function cpuacct yes yes 1 yes 2 3 2 1 -function cpuacct no yes 1 yes 2 3 2 1 -function cpuacct yes yes 2 yes 2 3 2 1 -function cpuacct yes yes 3 yes 2 3 2 1 -function cpuacct yes yes 4 yes 2 3 2 1 -function cpuacct yes yes 5 yes 2 3 2 1 -function cpuacct yes yes 6 yes 2 3 2 1 -function cpuacct yes yes 7 yes 2 3 2 1 -function cpuacct yes yes 8 yes 2 3 2 1 -function memory yes yes 1 yes 2 3 2 1 -function memory no yes 1 yes 2 3 2 1 -function memory yes yes 2 yes 2 3 2 1 -function memory yes yes 3 yes 2 3 2 1 -function memory yes yes 4 yes 2 3 2 1 -function memory yes yes 5 yes 2 3 2 1 -function memory yes yes 6 yes 2 3 2 1 -function memory yes yes 7 yes 2 3 2 1 -function memory yes yes 8 yes 2 3 2 1 -function all yes yes 1 yes 2 3 2 1 -function all no yes 1 yes 2 3 2 1 -function all yes yes 2 yes 2 3 2 1 -function all yes yes 3 yes 2 3 2 1 -function all yes yes 4 yes 2 3 2 1 -function all yes yes 5 yes 2 3 2 1 -function all yes yes 6 yes 2 3 2 1 -function all yes yes 7 yes 2 3 2 1 -function all yes yes 8 yes 2 3 2 1 -function none yes yes 1 yes 2 3 2 1 -function debug,debug yes yes 1 yes 2 3 2 1 -function debug,debug no yes 1 yes 2 3 2 1 -function debug,debug yes yes 2 yes 2 3 2 1 -function debug,debug yes yes 3 yes 2 3 2 1 -function debug,debug yes yes 4 yes 2 3 2 1 -function debug,debug yes yes 5 yes 2 3 2 1 -function debug,debug yes yes 6 yes 2 3 2 1 -function debug,debug yes yes 7 yes 2 3 2 1 -function debug,debug yes yes 8 yes 2 3 2 1 -function nonexistent yes yes 1 yes 2 3 2 1 -function freezer yes yes 1 yes 2 3 2 1 -function freezer no yes 1 yes 2 3 2 1 -function freezer yes yes 2 yes 2 3 2 1 -function freezer yes yes 3 yes 2 3 2 1 -function freezer yes yes 4 yes 2 3 2 1 -function freezer yes yes 5 yes 2 3 2 1 -function freezer yes yes 6 yes 2 3 2 1 -function freezer yes yes 7 yes 2 3 2 1 -function freezer yes yes 8 yes 2 3 2 1 -function devices yes yes 1 yes 2 3 2 1 -function devices no yes 1 yes 2 3 2 1 -function devices yes yes 2 yes 2 3 2 1 -function devices yes yes 3 yes 2 3 2 1 -function devices yes yes 4 yes 2 3 2 1 -function devices yes yes 5 yes 2 3 2 1 -function devices yes yes 6 yes 2 3 2 1 -function devices yes yes 7 yes 2 3 2 1 -function devices yes yes 8 yes 2 3 2 1 -function debug yes yes 1 yes 1 2 1 1 -function debug yes yes 1 yes 2 2 1 1 -function debug yes yes 1 yes 2 3 1 1 -function debug yes yes 1 yes 2 5 1 1 -function debug yes yes 1 yes 3 1 1 1 -function debug yes yes 1 yes 3 2 1 1 -function debug yes yes 1 yes 3 4 1 1 -function debug yes yes 1 yes 4 3 1 1 -function debug yes yes 1 yes 4 5 1 1 -function debug yes yes 1 no 1 1 1 1 -function debug yes yes 1 yes 1 1 1 1 -function debug yes yes 1 yes 1 3 2 1 -function debug yes yes 1 yes 2 3 2 2 -function debug yes yes 1 yes 2 3 2 3 -function debug yes yes 1 yes 2 3 2 4 -function debug yes yes 1 yes 2 3 2 5 -function debug yes yes 1 yes 2 3 2 6 -function debug yes yes 1 yes 2 3 2 7 -function debug yes yes 1 yes 2 3 3 2 -function debug yes yes 1 yes 2 3 4 2 -function debug yes yes 1 yes 2 3 5 2 -function debug yes yes 1 yes 2 3 6 2 -function debug yes yes 1 yes 2 3 7 2 -function debug yes yes 2 yes 2 3 2 2 -function debug yes yes 3 yes 2 3 1 1 -function debug yes yes 3 yes 2 3 1 2 -function debug yes yes 3 yes 2 3 1 3 -function debug yes yes 3 yes 2 3 2 1 -function debug yes yes 3 yes 2 3 2 2 -function debug yes yes 3 yes 2 3 2 3 -function debug yes yes 3 yes 2 3 2 4 -function debug yes yes 3 yes 2 3 2 5 -function debug yes yes 3 yes 2 3 2 6 -function debug yes yes 3 yes 2 3 2 7 -function debug yes yes 3 yes 2 3 3 1 -function debug yes yes 3 yes 2 3 3 2 -function debug yes yes 3 yes 2 3 3 3 -function debug yes yes 3 yes 2 3 4 2 -function debug yes yes 3 yes 2 3 5 2 -function debug yes yes 3 yes 2 3 6 2 -function debug yes yes 3 yes 2 3 7 2 -function2 1 -function2 2 -function2 3 -function2 4 -function2 5 -function2 6 -function2 7 -function2 8 -function2 9 -function2 10 -function2 11 -function2 12 -function2 13 -stress debug 100 1 1 1 -stress cpuset 100 1 1 1 -stress ns 100 1 1 1 -stress cpu 100 1 1 1 -stress cpuacct 100 1 1 1 -stress memory 100 1 1 1 -stress all 100 1 1 1 -stress debug 1 1 1 2 -stress debug 1 1 100 1 -stress debug 1 1 100 2 -stress debug 1 1 100 3 -stress debug 1 100 1 1 -stress debug 1 100 1 2 -stress debug 1 100 1 3 -stress debug 1 100 100 1 -stress debug 1 100 100 2 -stress cpuset 1 1 1 2 -stress cpuset 1 1 100 1 -stress cpuset 1 1 100 2 -stress cpuset 1 1 100 3 -stress cpuset 1 100 1 1 -stress cpuset 1 100 1 2 -stress cpuset 1 100 1 3 -stress cpuset 1 100 100 1 -stress cpuset 1 100 100 2 -stress cpu 1 1 1 2 -stress cpu 1 100 1 1 -stress cpu 1 100 1 2 -stress cpu 1 100 1 3 -stress cpuacct 1 1 1 2 -stress cpuacct 1 1 100 1 -stress cpuacct 1 1 100 2 -stress cpuacct 1 1 100 3 -stress cpuacct 1 100 1 1 -stress cpuacct 1 100 1 2 -stress cpuacct 1 100 1 3 -stress cpuacct 1 100 100 1 -stress cpuacct 1 100 100 2 -stress memory 1 1 1 2 -stress memory 1 1 100 1 -stress memory 1 1 100 2 -stress memory 1 1 100 3 -stress memory 1 100 1 1 -stress memory 1 100 1 2 -stress memory 1 100 1 3 -stress memory 1 100 100 1 -stress memory 1 100 100 2 \ No newline at end of file diff --git a/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh b/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh index f0b43b8..c2a111b 100755 --- a/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh +++ b/testcases/kernel/controllers/cgroup_fj/run_cgroup_test_fj.sh @@ -23,8 +23,18 @@ ################################################################################ cd $LTPROOT/testcases/bin -export TCID="cgroup_test_fj" -export TST_TOTAL=194 + +cnt=1 +for arg; do + if [ $cnt -gt 1 ]; then + NAME+="_" + NAME+=$arg + fi + cnt=$(( $cnt + 1 )) +done + +export TCID=$1$NAME +export TST_TOTAL=1 export TST_COUNT=1 export TESTROOT=`pwd` @@ -86,47 +96,39 @@ if [ "$SYBSYSCOMPILED" = "" ];then # Warning and exit if all cgroup subsystem ar exit -2; fi -echo "Now, we start the test for cgroup..."; - rm -f $LOGFILE 2>/dev/null echo `date` > $LOGFILE echo `uname -a` >> $LOGFILE echo "" >> $LOGFILE -echo "Now, we start the test for basic function of cgroup..." >> $LOGFILE -nlines=`cat cgroup_fj_testcases.sh | wc -l` -for i in `seq 1 $nlines` -do - CASETYPE=`sed -n "$i""p" cgroup_fj_testcases.sh | cut -f1` - CASECMD=`sed -n "$i""p" cgroup_fj_testcases.sh | cut -f2` - echo $CASETYPE | grep "#" - if [ $? -ne 0 ]; then - case $CASETYPE in - "function" ) - : $(( CASENO1 += 1 )) - export CASENO1=$CASENO1 - $TESTROOT/cgroup_fj_function.sh $CASECMD - ;; - "function2" ) - : $(( CASENO1 += 1 )) - export CASENO1=$CASENO1 - $TESTROOT/cgroup_fj_function2.sh $CASECMD - ;; - "stress" ) - : $(( CASENO2 += 1 )) - export CASENO2=$CASENO2 - $TESTROOT/cgroup_fj_stress.sh $CASECMD - ;; - esac +CASETYPE=$1 +shift +CASECMD=$@ - ret=$? - if [ $ret -eq 0 ]; then - tst_resm TPASS "case$i(`sed -n "$i""p" cgroup_fj_testcases.sh`) PASS" - elif [ $ret -ne 9 ]; then - tst_resm TFAIL "case$i(`sed -n "$i""p" cgroup_fj_testcases.sh`) FAIL" - fi - fi -done +case $CASETYPE in +"function" ) + : $(( CASENO1 += 1 )) + export CASENO1=$CASENO1 + $TESTROOT/cgroup_fj_function.sh $CASECMD + ;; +"function2" ) + : $(( CASENO1 += 1 )) + export CASENO1=$CASENO1 + $TESTROOT/cgroup_fj_function2.sh $CASECMD + ;; +"stress" ) + : $(( CASENO2 += 1 )) + export CASENO2=$CASENO2 + $TESTROOT/cgroup_fj_stress.sh $CASECMD + ;; +esac + +ret=$? +if [ $ret -eq 0 ]; then + tst_resm TPASS "case$i($CASETYPE$CASECMD) PASS" +elif [ $ret -ne 9 ]; then + tst_resm TFAIL "case$i($CASETYPE $CASECMD) FAIL" +fi exit $ret; -- 2.1.4 |
From: Cyril H. <ch...@su...> - 2015-09-08 12:31:16
|
Hi! > diff --git a/testcases/kernel/hotplug/cpu_hotplug/include/cpuhotplug_hotplug.sh b/testcases/kernel/hotplug/cpu_hotplug/include/cpuhotplug_hotplug.sh > index 6920393..48bd814 100644 > --- a/testcases/kernel/hotplug/cpu_hotplug/include/cpuhotplug_hotplug.sh > +++ b/testcases/kernel/hotplug/cpu_hotplug/include/cpuhotplug_hotplug.sh > @@ -169,7 +169,7 @@ get_present_cpus() > # > get_present_cpus_num() > { > - return $(get_present_cpus | wc -w) > + echo $(get_present_cpus | wc -w) I've changed the tab here back to four spaces since rest of the file uses four spaces for indentation and pushed, thanks. -- Cyril Hrubis ch...@su... |
From: Alexey K. <ale...@or...> - 2015-09-08 12:25:28
|
Hi, On 09/08/2015 02:39 PM, xcf733520 wrote: > Hi all, > > I try to run testscript in the directory of /opt/ltp/testscripts, when try networkstress.sh/networktests.sh it show as below, > > ./network.sh: line 5: test_net.sh: No such file or directory test_net.sh script should be in the PATH. Usually, installation directory /opt/ltp/testcases/bin is set to the PATH. Then you can run ./networktests.sh. Alternatively, you can try to set the PATH to networkstress.sh or networktests.sh: $ PATH=/opt/ltp/testcases/bin:$PATH ./networktests.sh Thanks, Alexey |
From: Cyril H. <ch...@su...> - 2015-09-08 11:58:48
|
Hi! > It's necessary for correct cleaning. E.g. open_posix_testsuite > is not cleaned without including these .mk files. However it's > not an error if these files does not exist while cleaning. > > Signed-off-by: Yuriy Kolerov <yur...@sy...> > --- > include/mk/env_pre.mk | 11 +++++++++-- > 1 file changed, 9 insertions(+), 2 deletions(-) > > diff --git a/include/mk/env_pre.mk b/include/mk/env_pre.mk > index f1584a8..a6beb5b 100644 > --- a/include/mk/env_pre.mk > +++ b/include/mk/env_pre.mk > @@ -94,11 +94,18 @@ ifeq ($(srcdir),) > srcdir := . > endif > > -# autotools, *clean, and help don't require config.mk, features.mk, etc... > -ifeq ($(filter autotools %clean .gitignore gitignore.% help,$(MAKECMDGOALS)),) > +# autotools and help don't require config.mk, features.mk, etc... > +ifeq ($(filter autotools .gitignore gitignore.% help,$(MAKECMDGOALS)),) > > +# If config.mk and features.mk does not exist it's not an error for *clean > +# targets. > +ifeq ($(filter %clean,$(MAKECMDGOALS)),) > include $(abs_top_builddir)/include/mk/config.mk > include $(abs_top_builddir)/include/mk/features.mk > +else > +-include $(abs_top_builddir)/include/mk/config.mk > +-include $(abs_top_builddir)/include/mk/features.mk > +endif Hmm, besides including the config.mk this also enables the out-of-tree build checks and make 3.80 compatibility targets. Not that it's apriory wrong but I would rather be more conservative and only include the config.mk and features.mk. One option would be to add the: -include $(abs_top_builddir)/include/mk/config.mk -include $(abs_top_builddir)/include/mk/features.mk before the ifeq that filters out the autotools, clean, etc. targets. What do you think? -- Cyril Hrubis ch...@su... |
From: xcf733520 <xcf...@si...> - 2015-09-08 11:56:18
|
Hi all, I try to run testscript in the directory of /opt/ltp/testscripts, when try networkstress.sh/networktests.sh it show as below, ./network.sh: line 5: test_net.sh: No such file or directory Do them networkstress.sh/networktests.sh run directly? -------------- xcf733520 |