Re: [LTP] [PATCH 1/2] ltp_rt_sigaction: SPARC fixes for -O0

2015-08-19 Thread Stanislav Kholmanskikh
On 08/17/2015 04:17 PM, Stanislav Kholmanskikh wrote: > > > On 08/17/2015 03:49 PM, Jan Stancek wrote: >> >> >> >> >> - Original Message - >>> From: "Stanislav Kholmanskikh" >>> To: ltp-list@lists.sourceforge.net >

Re: [LTP] [PATCH 1/2] ltp_rt_sigaction: SPARC fixes for -O0

2015-08-17 Thread Stanislav Kholmanskikh
On 08/17/2015 03:49 PM, Jan Stancek wrote: > > > > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: ltp-list@lists.sourceforge.net >> Cc: "vasily isaenko" >> Sent: Monday, 17 August, 2015 2:13:17 PM >>

[LTP] [PATCH 2/2] containers: allow linking with additional libs

2015-08-17 Thread Stanislav Kholmanskikh
Makefiles in kernel/containers explicitly enumerate all required libraries in LDLIBS. This avoids linking the test cases with additional libraries, whereas all other LTP test cases can be linked this way. Fixed this by using $(LDLIBS) instead of '-lltp'. Signed-off-by: Stanislav Kh

[LTP] [PATCH 1/2] ltp_rt_sigaction: SPARC fixes for -O0

2015-08-17 Thread Stanislav Kholmanskikh
uction we need ('mov ...'). The trick was proposed by Jose E. Marchesi . Signed-off-by: Stanislav Kholmanskikh --- include/lapi/rt_sigaction.h | 20 1 files changed, 12 insertions(+), 8 deletions(-) diff --git a/include/lapi/rt_sigaction.h b/include/lapi/rt_sigactio

Re: [LTP] [PATCH V2] detach_device: Wait until the kernel frees the loop device

2015-06-11 Thread Stanislav Kholmanskikh
On 06/11/2015 02:57 PM, Cyril Hrubis wrote: > Hi! > Acked. > Thank you. Pushed. -- ___ Ltp-list mailing list Ltp-list@lists.sourceforge.net https://lists.sourceforge.net/lists/li

Re: [LTP] [PATCH v2] kernel:flock: Change tst_resm() followed by tst_exit() to tst_brkm()

2015-06-10 Thread Stanislav Kholmanskikh
On 06/10/2015 03:40 PM, Maninder Singh wrote: > As in commit 9fa8ad0 Change tst_resm() followed by tst_exit() to tst_brkm() > > Signed-off-by: Maninder Singh > Signed-off-by: Akhilesh Kumar > --- > testcases/kernel/syscalls/flock/flock01.c | 12 ++-- > testcases/kernel/syscalls/flo

[LTP] [PATCH V2] detach_device: Wait until the kernel frees the loop device

2015-06-10 Thread Stanislav Kholmanskikh
0 close(3) = 0 open("/dev/loop0", O_RDWR) = 3 open("file.img", O_RDWR) = 4 ioctl(3, LOOP_SET_FD, 0x4) = -1 EBUSY (Device or resource busy) So let's wait until the kernel frees the loop device, i.e. when ioctl(LOOP_CLR_FD)

Re: [LTP] [PATCH] detach_device: Wait until the kernel frees the loop device

2015-06-10 Thread Stanislav Kholmanskikh
On 06/10/2015 01:30 PM, Jan Stancek wrote: > > > > > - Original Message - >> From: "Cyril Hrubis" >> To: "Stanislav Kholmanskikh" >> Cc: ltp-list@lists.sourceforge.net, "vasily isaenko" >> , jstan...@redhat.com

Re: [LTP] [PATCH] detach_device: Wait until the kernel frees the loop device

2015-06-10 Thread Stanislav Kholmanskikh
On 06/10/2015 01:08 PM, Cyril Hrubis wrote: > Hi! >> Signed-off-by: Stanislav Kholmanskikh >> --- >> lib/tst_device.c | 17 ++--- >> 1 files changed, 6 insertions(+), 11 deletions(-) >> >> diff --git a/lib/tst_device.c b/lib/tst_de

Re: [LTP] [PATCH 1/1] kernel:flock/flock01.c: Change tst_resm() followed by tst_exit() to tst_brkm()

2015-06-10 Thread Stanislav Kholmanskikh
Hi. On 06/10/2015 10:58 AM, Maninder Singh wrote: > As in commit 9fa8ad0 Change tst_resm() followed by tst_exit() to tst_brkm() > > Signed-off-by: Maninder Singh > Signed-off-by: Akhilesh Kumar > --- > testcases/kernel/syscalls/flock/flock01.c | 12 ++-- > 1 file changed, 2 insertio

Re: [LTP] How to add test case in LTP for my local use

2015-06-10 Thread Stanislav Kholmanskikh
On 06/10/2015 09:56 AM, Pratik Prajapati wrote: > Hi, Hi. > > I want to add a test case for my local use. From > https://github.com/linux-test-project/ltp/wiki/Test-Writing-Guidelines I > get to know how to write a test case but didb't get how to add it. > Please help. For example, you could c

Re: [LTP] [RFC PATCH 5/5] acl_test01: Wait until the loop device is detached

2015-06-10 Thread Stanislav Kholmanskikh
On 06/09/2015 03:50 PM, Cyril Hrubis wrote: > > > I think that we should do: > > detach_device(..) > { > while EBUSY: > ioctl(fd, LOOP_CLR_FD); > > while not error: > ioclt(LOOP_GET_STATUS); > usleep(); > } > > Because if we ignore the return

Re: [LTP] [PATCH] detach_device: Wait until the kernel frees the loop device

2015-06-10 Thread Stanislav Kholmanskikh
On 06/10/2015 11:11 AM, Stanislav Kholmanskikh wrote: On systems employing the "lazy loop device removal", kernel commit commit a1ecac3b0656a68259927c234e505804d33a7b83 ("loop: Make explicit loop device destruction lazy"), ioctl(LOOP_CLR_FD) may return 0 when the loop d

[LTP] [PATCH] detach_device: Wait until the kernel frees the loop device

2015-06-10 Thread Stanislav Kholmanskikh
op device, i.e. when ioctl(LOOP_CLR_FD) starts failing with ENXIO. Signed-off-by: Stanislav Kholmanskikh --- lib/tst_device.c | 17 ++--- 1 files changed, 6 insertions(+), 11 deletions(-) diff --git a/lib/tst_device.c b/lib/tst_device.c index 3bded53..9a92fc8 100644 --- a/lib/tst_

Re: [LTP] [RFC PATCH 5/5] acl_test01: Wait until the loop device is detached

2015-06-09 Thread Stanislav Kholmanskikh
On 06/09/2015 03:19 PM, Jan Stancek wrote: > > > > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: "Cyril Hrubis" , "Jan Stancek" >> Cc: ltp-list@lists.sourceforge.net, "vasily isaenko" >>

Re: [LTP] [PATCH 2/5] acl_test01: Verify the exit code of the second test case

2015-06-09 Thread Stanislav Kholmanskikh
On 06/09/2015 03:03 PM, Cyril Hrubis wrote: > Hi! >>> We should probably wrap the su into a script that makes sure that the >>> return value is compatible with LTP. Because it may set bogus test >>> return status if su reported anything else than 0 or 1. >> >> Ehm, but -c "$0" will execute the sa

Re: [LTP] [PATCH 2/5] acl_test01: Verify the exit code of the second test case

2015-06-09 Thread Stanislav Kholmanskikh
On 06/09/2015 01:54 PM, Cyril Hrubis wrote: > Hi! >> Now we verify the exit code of the second test case. We did not >> do this previously, and it was a bug. >> >> Signed-off-by: Stanislav Kholmanskikh >> --- >> testcases/kernel/fs/acls/acl_test01 |3

Re: [LTP] [RFC PATCH 5/5] acl_test01: Wait until the loop device is detached

2015-06-09 Thread Stanislav Kholmanskikh
On 06/09/2015 01:10 PM, Cyril Hrubis wrote: > Hi! >> If the test is executed on NFS, it may print: >> >> rm: cannot remove `/mnt/ltp-xeJYpESVKz/acltest01.fCogoo4gn0': Directory not >> empty >> >> It seems the following happen: >> >> 1. After 'unmount -d' 'acltest01.fCogoo4gn0/blkext3' is still i

Re: [LTP] [PATCH 1/5] acl_test01: Fixes

2015-06-09 Thread Stanislav Kholmanskikh
Hi. On 06/09/2015 01:00 PM, Cyril Hrubis wrote: > Hi! >> - >> -tst_require_root > > Why do we remove this? The test calls adduser and we need root for that > or don't we? This is because we call 'tst_require_root' twice. The first time is from "FUNCTION MAIN:" and the second time when we exe

[LTP] [RFC PATCH 5/5] acl_test01: Wait until the loop device is detached

2015-06-09 Thread Stanislav Kholmanskikh
n0' directory fails, because it still contains this '.nfs*' file. Intorucing a wait cycle should fix this problem. Signed-off-by: Stanislav Kholmanskikh --- It's a follow up to: http://sourceforge.net/p/ltp/mailman/message/32987268/ Indeed, 'sync' was wro

[LTP] [PATCH 1/5] acl_test01: Fixes

2015-06-09 Thread Stanislav Kholmanskikh
Converted the test case to use tst_tmpdir instead of local juggling with $TMP. When we execute LTP, $PATH includes $LTPROOT/testcases/bin, so there is no reason to set $TCbin explicitly. Therefore, removed $TCbin. Signed-off-by: Stanislav Kholmanskikh --- runtest/admin_tools

[LTP] [PATCH 4/5] tools/apicmd: Add tst_fs_type

2015-06-09 Thread Stanislav Kholmanskikh
Signed-off-by: Stanislav Kholmanskikh --- doc/test-writing-guidelines.txt | 17 + tools/apicmds/.gitignore|1 + tools/apicmds/Makefile |2 +- tools/apicmds/ltpapicmd.c | 17 + 4 files changed, 36 insertions(+), 1 deletions

[LTP] [PATCH 2/5] acl_test01: Verify the exit code of the second test case

2015-06-09 Thread Stanislav Kholmanskikh
Now we verify the exit code of the second test case. We did not do this previously, and it was a bug. Signed-off-by: Stanislav Kholmanskikh --- testcases/kernel/fs/acls/acl_test01 |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/testcases/kernel/fs/acls/acl_test01 b

[LTP] [PATCH 3/5] acl_test01: Hide unnecessary output

2015-06-09 Thread Stanislav Kholmanskikh
The output from 'grep' gives no value, so let's hide it. 'losetup -d' is also not needed, because the loop device is detached by 'umount -d'. Therefore, removed 'losetup -d' to hide warnings like: loop: can't delete device /dev/loop1: N

Re: [LTP] [PATCH V2 2/2] Unmap the futexes backend file in tst_rmdir

2015-05-27 Thread Stanislav Kholmanskikh
On 05/26/2015 01:21 PM, Stanislav Kholmanskikh wrote: > As of now, test cases utilizing tst_checkpoint framework fail on NFS > with similar errors: > > creat07 0 TWARN : tst_tmpdir.c:206: tst_rmdir: > rmobj(/tmpdir/ltp-0IVQPP0NK6/creigi0kV) failed: > remove(/tmp

[LTP] [PATCH V2 2/2] Unmap the futexes backend file in tst_rmdir

2015-05-26 Thread Stanislav Kholmanskikh
keep the futex page mapped while tst_rmdir() is running. Let's unmap it before the actual delete procedure. Signed-off-by: Stanislav Kholmanskikh --- Changes since V1: * renamed 'futex_t *futexes' to 'futex_t *tst_futexes' lib/tst_checkpoint.c | 12 +++- li

[LTP] [PATCH 2/2] Unmap the futexes backend file in tst_rmdir

2015-05-26 Thread Stanislav Kholmanskikh
keep the futex page mapped while tst_rmdir() is running. Let's unmap it before the actual delete procedure. Signed-off-by: Stanislav Kholmanskikh --- lib/tst_checkpoint.c |2 +- lib/tst_tmpdir.c | 11 +++ 2 files changed, 12 insertions(+), 1 deletions(-) diff --git

[LTP] [PATCH 1/2] Move futex_t into a common header

2015-05-26 Thread Stanislav Kholmanskikh
Signed-off-by: Stanislav Kholmanskikh --- include/lapi/futex.h| 24 lib/tst_checkpoint.c|3 +-- testcases/kernel/syscalls/futex/futextest.h |2 +- 3 files changed, 26 insertions(+), 3 deletions(-) create mode

Re: [LTP] [RFC PATCH] tst_checkpoint_destroy

2015-05-26 Thread Stanislav Kholmanskikh
On 05/25/2015 11:51 AM, Cyril Hrubis wrote: > Hi! >> As of now, if we run test cases which use the tst_checkpoint framework on >> NFS, >> they will fail with errors like: >> >> creat07 0 TWARN : tst_tmpdir.c:206: tst_rmdir: >> rmobj(/tmpdir/ltp-0IVQPP0NK6/creigi0kV) failed: >> remove(/t

[LTP] [RFC PATCH] tst_checkpoint_destroy

2015-05-25 Thread Stanislav Kholmanskikh
empty This happens because we keep the futex page mapped while tst_rmdir() is running. So on we need to unmap the page before tst_rmdir(). What do you think about the proposed solution? Thanks. Signed-off-by: Stanislav Kholmanskikh --- include/tst_checkpoint.h |9

Re: [LTP] [PATCH 0/4 v3] (merged) cpuhotplug fixes

2015-04-30 Thread Stanislav Kholmanskikh
ere to use number of present CPUs, rather than all > > Changes in v3: > + use present_mask variable in get_present_cpus > + no special treatment for cpu0 in cpuhotplug03 > + fix cpuhotplug03 to spawn (number of present cpus)*2 processes > + this time whole series has correct version in subje

Re: [LTP] [PATCH 3/4] cpu_hotplug: use hotplug/present cpus functions

2015-04-29 Thread Stanislav Kholmanskikh
On 04/29/2015 05:41 PM, Jan Stancek wrote: > > > > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: "Jan Stancek" , ltp-list@lists.sourceforge.net >> Sent: Wednesday, 29 April, 2015 3:09:06 PM >> Subject: Re:

Re: [LTP] [PATCH 0/4 v2] (merged) cpuhotplug fixes

2015-04-29 Thread Stanislav Kholmanskikh
r sparc64 kernel. To be honest, there is no cpu hotplug (yet), so all this test cases return TCONF ;) > > Regards, > Jan > > > Jan Stancek (1): >cpu_hotplug: use hotplug/present cpus functions > > Stanislav Kholmanskikh (3): >cpuhotplug: use cpu states in cleanu

Re: [LTP] [PATCH 3/4] cpu_hotplug: use hotplug/present cpus functions

2015-04-29 Thread Stanislav Kholmanskikh
On 04/29/2015 02:18 PM, Jan Stancek wrote: > Signed-off-by: Jan Stancek > --- > testcases/kernel/hotplug/cpu_hotplug/functional/cpuhotplug01.sh | 6 +++--- > testcases/kernel/hotplug/cpu_hotplug/functional/cpuhotplug02.sh | 2 +- > testcases/kernel/hotplug/cpu_hotplug/functional/cpuhotplug03.s

Re: [LTP] [PATCH 2/4] cpu_hotplug: add get_hotplug_cpus, get_present_cpus

2015-04-29 Thread Stanislav Kholmanskikh
On 04/29/2015 02:17 PM, Jan Stancek wrote: > From: Stanislav Kholmanskikh > > Signed-off-by: Stanislav Kholmanskikh > Signed-off-by: Jan Stancek > --- > .../cpu_hotplug/include/cpuhotplug_hotplug.sh | 73 > +- > 1 file changed, 70 in

Re: [LTP] [PATCH v2] containers: semctl replaced with semop in sysvipc/sem_comm.c

2015-04-21 Thread Stanislav Kholmanskikh
Hi. On 04/20/2015 01:28 PM, Matus Marhefka wrote: > Hi, > > please consider pushing this reviewed patch. > > Thanks, > Matus Marhefka > > > - Original Message - > From: "Jan Stancek" > To: "Matus Marhefka" > Cc: ltp-list@lists.sourceforge.net > Sent: Thursday, February 26, 2015 2:22:24 P

Re: [LTP] [PATCH] max_map_count: tst_fork() instead of fork()

2015-04-15 Thread Stanislav Kholmanskikh
On 04/15/2015 04:13 PM, Jan Stancek wrote: > > > > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: ltp-list@lists.sourceforge.net >> Cc: "vasily isaenko" >> Sent: Wednesday, 15 April, 2015 11:27:09 AM >>

[LTP] [PATCH] max_map_count: tst_fork() instead of fork()

2015-04-15 Thread Stanislav Kholmanskikh
In order to put output messages in order and remove "duplicates", we need a fflush() before forking and tst_fork() does it. Signed-off-by: Stanislav Kholmanskikh --- testcases/kernel/mem/tunable/max_map_count.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a

Re: [LTP] LTP release

2015-04-14 Thread Stanislav Kholmanskikh
On 04/14/2015 12:19 PM, Cyril Hrubis wrote: > Hi! We have several issues in our sparc64 environment. Need a day or two to figure out whether they are test case issues or problems with our environment. >>> >>> Ok. >>> >> >> Finally, there are only two test case issues: >>* cpuho

Re: [LTP] LTP release

2015-04-13 Thread Stanislav Kholmanskikh
On 04/07/2015 06:27 PM, Cyril Hrubis wrote: > Hi! It's about the time we start to prepare for next release. I will (hopefully) start runing latest git code and look for unexpected failures during this week. Everybody please try to run the latest git code and report any problem

[LTP] [PATCH 1/2] Keep the definition of union semun in one place

2015-04-13 Thread Stanislav Kholmanskikh
Signed-off-by: Stanislav Kholmanskikh --- include/lapi/semun.h | 35 .../kernel/ipc/ipc_stress/semaphore_test_01.c | 13 +--- .../kernel/ipc/ipc_stress/semaphore_test_02.c |7 +--- .../kernel/ipc/ipc_stress

[LTP] [PATCH 2/2] sem_comm: pass a semun union to semctl()

2015-04-13 Thread Stanislav Kholmanskikh
It's required by the semctl() API plus without that the test case may fail on 64-bit Big Endian systems (like sparc64). Signed-off-by: Stanislav Kholmanskikh --- testcases/kernel/containers/sysvipc/sem_comm.c |9 +++-- 1 files changed, 7 insertions(+), 2 deletions(-) diff --

[LTP] [PATCH 3/3] cpuhotplug04.sh: operate only with hotpluggable CPUs

2015-04-08 Thread Stanislav Kholmanskikh
Signed-off-by: Stanislav Kholmanskikh --- .../hotplug/cpu_hotplug/functional/cpuhotplug04.sh | 56 +++ 1 files changed, 32 insertions(+), 24 deletions(-) diff --git a/testcases/kernel/hotplug/cpu_hotplug/functional/cpuhotplug04.sh b/testcases/kernel/hotplug/cpu_hotplug/functional/

[LTP] cpuhotplug fixes

2015-04-08 Thread Stanislav Kholmanskikh
Hi! The current version of cpuhotplug04.sh fails with our sparc64 kernel: Name: cpuhotplug04 Date: Mon Apr 6 14:30:45 EDT 2015 Desc: Does it prevent us from offlining the last CPU? cat: /sys/devices/system/cpu/cpu3/online: No such file or directory /opt/ltp/testcases/bin/cpuhotplug_hotplu

[LTP] [PATCH 1/3] cpuhotplug: use cpu states in cleanup

2015-04-08 Thread Stanislav Kholmanskikh
ff-by: Stanislav Kholmanskikh --- .../hotplug/cpu_hotplug/functional/cpuhotplug01.sh | 11 --- .../hotplug/cpu_hotplug/functional/cpuhotplug03.sh | 12 +--- .../hotplug/cpu_hotplug/functional/cpuhotplug04.sh | 18 +- .../cpu_hotplug/include/cpuhotplug_hotpl

[LTP] [PATCH 2/3] cpu_hotplug: added get_hotplug_cpus, get_hotplug_cpus_num

2015-04-08 Thread Stanislav Kholmanskikh
Signed-off-by: Stanislav Kholmanskikh --- .../cpu_hotplug/include/cpuhotplug_hotplug.sh | 22 1 files changed, 22 insertions(+), 0 deletions(-) diff --git a/testcases/kernel/hotplug/cpu_hotplug/include/cpuhotplug_hotplug.sh b/testcases/kernel/hotplug/cpu_hotplug

Re: [LTP] LTP release

2015-04-07 Thread Stanislav Kholmanskikh
On 04/02/2015 01:09 PM, Cyril Hrubis wrote: > Hi! >> It's about the time we start to prepare for next release. I will >> (hopefully) start runing latest git code and look for unexpected >> failures during this week. Everybody please try to run the latest >> git code and report any problems. > > I'v

Re: [LTP] [PATCH] doc: fix spelling mistakes in manuals

2015-02-16 Thread Stanislav Kholmanskikh
Hi! On 02/16/2015 12:22 PM, Wei,Jiangang wrote: > These mistakes cann't lead to trouble for reading, > but the correct spelling is more better for beginners > to understand it. > > Signed-off-by: Wei,Jiangang Thank you, pushed. --

Re: [LTP] prototyping new library synchronization

2015-02-16 Thread Stanislav Kholmanskikh
Hi! On 02/12/2015 07:59 PM, Cyril Hrubis wrote: > Hi! > Code prototype follows. It uses mutexes and can be used with up to > page_size/sizeof(uint32) pairs. I've checked that it compiles fine and > works back to kernel 2.6.11 compiled in year 2005, which should be more > than enough. > > It uses a

Re: [LTP] [PATCH V2] doc: document tst_run_cmd

2015-02-04 Thread Stanislav Kholmanskikh
On 02/03/2015 07:12 PM, Cyril Hrubis wrote: > Hi! >> Signed-off-by: Stanislav Kholmanskikh >> --- >> Changes since V1: >> * Applied all comments from V1 >> * Added one more const to cmd[] in Example > > Acked. > Thank you for review. tst_run_cm

[LTP] [PATCH V2] doc: document tst_run_cmd

2015-02-03 Thread Stanislav Kholmanskikh
Signed-off-by: Stanislav Kholmanskikh --- Changes since V1: * Applied all comments from V1 * Added one more const to cmd[] in Example doc/test-writing-guidelines.txt | 40 +++ 1 files changed, 40 insertions(+), 0 deletions(-) diff --git a/doc/test

Re: [LTP] [PATCH] doc: document tst_run_cmd

2015-02-03 Thread Stanislav Kholmanskikh
On 02/03/2015 05:35 PM, Cyril Hrubis wrote: > Hi! >> +2.2.20 Executing a file >> +^^^ > > Maybe "Running executables" would be a bit better, as it is the title > looks strange to me. I stole it from 'man 3 execvp' :) No problem:) > >> +[source,c] >> +

[LTP] [PATCH V2 2/2] tst_module: introduce a timeout to unload modules

2015-02-02 Thread Stanislav Kholmanskikh
It may happen, that the first execution of 'rmmod module_name' may fail for some reason (like the module is in use for some short time). Changed tst_module_unload() to execute 'rmmod module_name' multiple times with the total number limited by a timeout. Signed-off-by: St

Re: [LTP] [PATCH 2/2] tst_module: introduce a timeout to unload modules

2015-02-02 Thread Stanislav Kholmanskikh
On 01/26/2015 04:11 PM, Cyril Hrubis wrote: >> @@ -100,6 +153,21 @@ void tst_module_load(void (cleanup_fn)(void), >> >> void tst_module_unload(void (cleanup_fn)(void), const char *mod_name) >> { >> +int i; >> +int loaded; >> + >> const char *const argv[] = { "rmmod", mod_name, NU

[LTP] [PATCH] doc: document tst_run_cmd

2015-02-02 Thread Stanislav Kholmanskikh
Signed-off-by: Stanislav Kholmanskikh --- Sorry for late response. doc/test-writing-guidelines.txt | 27 +++ 1 files changed, 27 insertions(+), 0 deletions(-) diff --git a/doc/test-writing-guidelines.txt b/doc/test-writing-guidelines.txt index 4d70a1b..a0004d8 100644

[LTP] [PATCH 1/2] tst_run_cmd: add an option to pass the program exit code

2015-01-26 Thread Stanislav Kholmanskikh
Added an option to pass the program exit code to the caller. This may be needed if we want to run a program with tst_run_cmd(), but handle failures manually (i.e. not call cleanup). Signed-off-by: Stanislav Kholmanskikh --- include/test.h | 16 ++--- lib

[LTP] [PATCH 2/2] tst_module: introduce a timeout to unload modules

2015-01-26 Thread Stanislav Kholmanskikh
It may happen, that the first execution of 'rmmod module_name' may fail for some reason (like the module is in use for some short time). Changed tst_module_unload() to execute 'rmmod module_name' multiple times with the total number limited by a timeout. Signed-off-by: St

Re: [LTP] [RFC PATCH] Asynchronous module unloading and tst_run_cmd

2015-01-20 Thread Stanislav Kholmanskikh
Hi, and thank you for review. On 01/19/2015 05:52 PM, Cyril Hrubis wrote: > Hi! >> There is one more issue with tbio. :( >> >> Sometimes it may fail with: >> >> ltp_tbio0 TINFO : Device opened successfully >> ltp_tbio1 TPASS : success on LTP_TBIO_ALLOC test >> ltp_tbio2 TPASS :

[LTP] [RFC PATCH] Asynchronous module unloading and tst_run_cmd

2015-01-16 Thread Stanislav Kholmanskikh
n_cmd_fds are acceptable. Thanks! Signed-off-by: Stanislav Kholmanskikh --- include/test.h |8 ++- include/tst_module.h | 11 lib/tst_mkfs.c |2 +- lib/tst_module.c

[LTP] [PATCH V3 2/2] tbio: fixes

2015-01-15 Thread Stanislav Kholmanskikh
* Wait until udev creates /dev/tbio. If udev can not create the node file in a defined timeout, create it manually. * Clean /dev/tbio after test execution, if /dev/tbio was created manually. Signed-off-by: Stanislav Kholmanskikh --- Changes since V2: * Check for the file ten times a second

[LTP] [PATCH V2 2/2] tbio: fixes

2015-01-13 Thread Stanislav Kholmanskikh
* Wait until udev creates /dev/tbio. If udev can not create the node file in a defined timeout, create it manually. * Clean /dev/tbio after test execution, if /dev/tbio was created manually. Signed-off-by: Stanislav Kholmanskikh --- Changes since V1: * implemented a more active waiting

Re: [LTP] [PATCH 2/3] tbio: fixes

2015-01-13 Thread Stanislav Kholmanskikh
Hi! On 01/06/2015 01:18 PM, Cyril Hrubis wrote: > Hi! >> +/* >> + * Wait until udev creates the device node. >> + * If the node is not created, we will create it manually, >> + * see below. >> + */ >> +sleep(5); > > As usually I do not like adding long sleep() into testcase

[LTP] [PATCH 2/3] tbio: fixes

2014-12-19 Thread Stanislav Kholmanskikh
* Introduce a sleep() to wait until udev creates /dev/tbio * Fix typos * Clean /dev/tbio after test execution, if /dev/tbio was created manually. Signed-off-by: Stanislav Kholmanskikh --- .../kernel/device-drivers/tbio/tbio_user/tbio.c| 20 +++- 1 files changed, 15

[LTP] [PATCH 3/3] tbio: fix cmd_len handling

2014-12-19 Thread Stanislav Kholmanskikh
inter->cmd containing a null-terminated string, and inter->cmd_len containing the exact number of bytes to store this string. Signed-off-by: Stanislav Kholmanskikh --- .../device-drivers/tbio/tbio_kernel/ltp_tbio.c | 11 --- .../kernel/device-drivers/tbio/tbio_kernel/tbio.h |2

[LTP] tbio fixes

2014-12-19 Thread Stanislav Kholmanskikh
In some of our environments (x86, x86_64, sparc64) tbio fails, and this series fixes the failures. I tried to introduce minimal changes, because, to be honest, I'm not 100% sure that I understand the block layer very well. So I would be more than happy, if anybody will have a chance to review/test

[LTP] [PATCH 1/3] ltp_tbio.c: fix a possible kernel panic

2014-12-19 Thread Stanislav Kholmanskikh
tbio_open(). Signed-off-by: Stanislav Kholmanskikh --- .../device-drivers/tbio/tbio_kernel/ltp_tbio.c |8 +++- 1 files changed, 3 insertions(+), 5 deletions(-) diff --git a/testcases/kernel/device-drivers/tbio/tbio_kernel/ltp_tbio.c b/testcases/kernel/device-drivers/tbio/tbio_kernel/

Re: [LTP] [PATCH V2] library: add tst_system for wrapper system(3) without SIGCHLD

2014-12-16 Thread Stanislav Kholmanskikh
Hi, George. I've just found that I'm also motivated to have this bug fixed :) Are you planning to send an updated version including Jan's comments? Thanks. PS: I also tested it with access06 test case: without the patch: [root@kholmanskikh access]# LTP_DEV_FS_TYPE=btrfs ./access06 access06

Re: [LTP] [PATCH v2] fix some syscall tests for 16-bit compat testing

2014-11-28 Thread Stanislav Kholmanskikh
On 11/28/2014 11:33 AM, Han Pingtian wrote: > On Mon, Nov 24, 2014 at 05:53:32PM +0300, Stanislav Kholmanskikh wrote: >> Hi. >> >> In general, it looks good. >> >> I have only one comment, that it's possible that the uid/gid values we pass >> to t

Re: [LTP] [PATCH] fix some syscall tests for 16-bit compat testing

2014-11-24 Thread Stanislav Kholmanskikh
d, Nov 19, 2014 at 11:15:54AM +0300, Stanislav Kholmanskikh wrote: >>> Looks like those cases need to be fixed for the 16-bit compat, right? >>> >>> chown0[1-5] fchown0[1-5] lchown03 setresgid0[1-4] setresuid0[1-3,5] >> >> Looks so. >> >> Sorry for

Re: [LTP] chown and 16 bit syscall testing

2014-11-19 Thread Stanislav Kholmanskikh
On 11/13/2014 10:57 AM, Han Pingtian wrote: > On Mon, Nov 10, 2014 at 12:07:20PM +0300, Stanislav Kholmanskikh wrote: >> Hi! >> >> On 10/31/2014 04:39 PM, Han Pingtian wrote: >>> Hey there, >>> >>> I found that looks like all chown test cases will

Re: [LTP] chown and 16 bit syscall testing

2014-11-10 Thread Stanislav Kholmanskikh
Hi! On 10/31/2014 04:39 PM, Han Pingtian wrote: > Hey there, > > I found that looks like all chown test cases will be compiled to 16 bit > compat test case, but they just call chown() something like > > TEST(chown(fname, uid, gid)); > > which won't test if there is a 16 bit chown() syscall. I

[LTP] [PATCH] acl_test01: sync after removal of the loop device

2014-10-22 Thread Stanislav Kholmanskikh
explicit loop device destruction lazy To cope with this test case failure I introduced a 'sync'. And 'losetup -d' seems to be unnecessary, because of 'umount -d' before it Signed-off-by: Stanislav Kholmanskikh --- testcases/kernel/fs/acls/acl_test01 |2 +- 1 files chan

Re: [LTP] [PATCH v3 1/3] fcntl14: dup code clean up

2014-09-29 Thread Stanislav Kholmanskikh
Hi! Patch 3 was pushed. Thank you. On 09/28/2014 06:53 AM, Xiong Zhou wrote: > Hi! > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: "Xiong Zhou" >> Cc: ltp-list@lists.sourceforge.net >> Sent: Friday, September 26,

Re: [LTP] [PATCH v3 1/3] fcntl14: dup code clean up

2014-09-26 Thread Stanislav Kholmanskikh
Hi! On 09/26/2014 07:23 AM, Xiong Zhou wrote: > > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: "Xiong Zhou" >> Cc: ltp-list@lists.sourceforge.net >> Sent: Thursday, September 25, 2014 8:07:26 PM >> Subject: Re

Re: [LTP] [PATCH v3 1/3] fcntl14: dup code clean up

2014-09-25 Thread Stanislav Kholmanskikh
Hi! On 09/25/2014 11:17 AM, Xiong Zhou wrote: > > And block3 description message fix from "mandatory locking" > to "negative whence". > > Signed-off-by: Xiong Zhou > --- Patch 1 and patch 2 of the series are pushed. Btw, patch 2 didn't apply to index correctly with 'git am', I had to manually a

Re: [LTP] [PATCH 1/3] fcntl14: dup code clean up

2014-09-23 Thread Stanislav Kholmanskikh
Hi! On 09/19/2014 10:46 AM, Xiong Zhou wrote: > > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: "Xiong Zhou" , ltp-list@lists.sourceforge.net >> Sent: Thursday, September 11, 2014 10:04:32 PM >> Subject: Re:

Re: [LTP] [PATCH v2 3/3] splice01/tee01/utime: test back on NFS

2014-09-23 Thread Stanislav Kholmanskikh
Hi! On 09/19/2014 10:49 AM, Xiong Zhou wrote: > > Tests splice01 tee01 and utime01/02/03 pass on NFS since 2.6.32 at least. Could you add a kernel version check to the patch, please? I'm sure there are distributions which still use older kernels. For example, with 2.6.18-371.3.1.0.1.el5 and: sp

Re: [LTP] [RFC/PATCH] ltpstress.sh: added cmdline to set the block device

2014-09-22 Thread Stanislav Kholmanskikh
On 09/19/2014 05:20 PM, chru...@suse.cz wrote: > Hi! >> Could anybody help to review this change, please? > > Sorry, I've read the email but forgot to reply the last time. > > Looks good, acked. > Thank you. Pushed. -- M

Re: [LTP] [RFC/PATCH] ltpstress.sh: added cmdline to set the block device

2014-09-15 Thread Stanislav Kholmanskikh
Hi! Could anybody help to review this change, please? Thanks. On 21.08.2014 12:44, Stanislav Kholmanskikh wrote: > I think it's not needed to use set_block_device(), > create_block_device() from runltp, because their logic > is in tst_acquire_device()/tst_release_device() now. >

Re: [LTP] [PATCH 3/3] splice01/tee01/utime: test back on NFS

2014-09-11 Thread Stanislav Kholmanskikh
Hi! On 09/11/2014 02:32 PM, Xiong Zhou wrote: > NFS support splice(2) tee(2) and utime(2) now. I think that 'now' is a bit relative. I.e. for me 'now' can be 2.6.39, but for another guy - 3.16.2 or whatever. My proposal: * if this support came many-many years ago, we just mark the fact in the

Re: [LTP] [PATCH 2/3] fcntl14: only skip test block2 on NFS

2014-09-11 Thread Stanislav Kholmanskikh
tst_resm(TINFO, "Exit block 2"); > + } else > + tst_resm(TINFO, "Skip block 2 on NFS"); It's more a matter of taste, but recently in commit: commit a2d860c854511cccd682ce244636cbb5f4b75d7c Author: Xiong Zhou Date: Tue

Re: [LTP] [PATCH 1/3] fcntl14: dup code clean up

2014-09-11 Thread Stanislav Kholmanskikh
Hi! On 09/11/2014 02:30 PM, Xiong Zhou wrote: > And block3 description message fix from "mandatory locking" > to "negative whence". > > Signed-off-by: Xiong Zhou > --- > testcases/kernel/syscalls/fcntl/fcntl14.c | 36 > +++ > 1 file changed, 13 insertions(+), 23 de

Re: [LTP] [PATCH v4 3/3] fcntl16: Skip fcntl16 test block2 and block3 on NFS

2014-09-09 Thread Stanislav Kholmanskikh
On 09/08/2014 01:12 PM, Stanislav Kholmanskikh wrote: > Hi. > > Could anybody look at the series? > > If there are no objections, I'm going to push it tomorrow. Pushed. > > Thanks. > > On 08/25/2014 12:26 PM, Stanislav Kholmanskikh wrote: >> >>

Re: [LTP] [PATCH v4 3/3] fcntl16: Skip fcntl16 test block2 and block3 on NFS

2014-09-08 Thread Stanislav Kholmanskikh
Hi. Could anybody look at the series? If there are no objections, I'm going to push it tomorrow. Thanks. On 08/25/2014 12:26 PM, Stanislav Kholmanskikh wrote: > > > On 08/22/2014 11:05 AM, Xiong Zhou wrote: >> >> According to nfs(5), NLM supports advisory file lock

Re: [LTP] [PATCH v4 3/3] fcntl16: Skip fcntl16 test block2 and block3 on NFS

2014-08-25 Thread Stanislav Kholmanskikh
no need to resend the patch/series because it can be fixed at commit time. :) Thanks. Reviewed-by: Stanislav Kholmanskikh > testcases/kernel/syscalls/fcntl/fcntl16.c | 27 +-- > 1 file changed, 21 insertions(+), 6 deletions(-) > > diff --git a/testcases/k

Re: [LTP] [PATCH] mmap15: don't fail if mmap returns EINVAL

2014-08-22 Thread Stanislav Kholmanskikh
> or not aligned on a page boundary).", which suggests that both >> ENOMEM and EINVAL should be considered. >> >> Signed-off-by: Jan Stancek > > Acked-by: Wanlong Gao Modern sparc64 kernels return EINVAL as well. Acked-by: Stanislav Kholmanskikh > >> --- >

Re: [LTP] [PATCH v3 1/3] fcntl16: Skip fcntl16 tests on NFS

2014-08-21 Thread Stanislav Kholmanskikh
Hi! On 08/21/2014 08:12 AM, Xiong Zhou wrote: > > According to nfs(5), NLM supports advisory file locks only. So skip > fcntl16 test if NFS. > I've just took a fresh look at fcntl16.c and found that block1 of this test case may be executed on NFS. And, IMHO, this block1 test case is not 100% i

Re: [LTP] [PATCH v3 3/3] diotest4: Skip some diotest4 cases on NFS

2014-08-21 Thread Stanislav Kholmanskikh
On 08/21/2014 08:17 AM, Xiong Zhou wrote: > > According to description of NFS and directIO in open(2), especially > "The Linux NFS client places no alignment restrictions on > O_DIRECT I/O", ignore "odd count"/"non-aligned" read-write FAILs > in diotest4. > > Signed-off-by: Xiong Zhou > --- Loo

Re: [LTP] [PATCH v3 2/3] diotest4: Some code cleanup in diotest4.c

2014-08-21 Thread Stanislav Kholmanskikh
On 08/21/2014 08:14 AM, Xiong Zhou wrote: > > Split dup code cleanup and function change from v2. I suppose this message is directed to the LTP mailing list subscribers and should not be in `git log` after the patch is applied. Therefore put such messages after '---'. One small comment below.

[LTP] [RFC/PATCH] ltpstress.sh: added cmdline to set the block device

2014-08-21 Thread Stanislav Kholmanskikh
I think it's not needed to use set_block_device(), create_block_device() from runltp, because their logic is in tst_acquire_device()/tst_release_device() now. Signed-off-by: Stanislav Kholmanskikh --- testscripts/ltpstress.sh | 13 +++-- 1 files changed, 11 insertions(+), 2 dele

Re: [LTP] [PATCH v2] Skip some dio/fcntl cases on NFS

2014-08-20 Thread Stanislav Kholmanskikh
Hi! Sorry for delay. On 08/12/2014 08:37 AM, Xiong Zhou wrote: > > According to description of NFS and directIO in open(2), especially > "The Linux NFS client places no alignment restrictions on > O_DIRECT I/O", ignore "odd count"/"non-aligned" read-write FAILs > in diotest4. Some dup code clean

Re: [LTP] [PATCH] sparc64 syscall definitions' fixes

2014-08-14 Thread Stanislav Kholmanskikh
On 08/14/2014 03:50 PM, Jan Stancek wrote: > > > > > - Original Message - >> From: "Stanislav Kholmanskikh" >> To: ltp-list@lists.sourceforge.net >> Cc: "vasily isaenko" >> Sent: Thursday, 14 August, 2014 10:30:51 AM >>

[LTP] [PATCH] sparc64 syscall definitions' fixes

2014-08-14 Thread Stanislav Kholmanskikh
1. Changed '__sparc64__' to 'defined(__sparc__) && defined(__arch64__)' 2. Removed non-implemented syscall numbers from sparc64.in (in accordance to linux-stable/arch/sparc/include/uapi/asm/unistd.h) 2. Re-executed regen.sh Signed-off-by: Stanislav Kholmanskikh

Re: [LTP] [PATCH] rt_sigaction.h: define HAVE_SA_RESTORER for most platforms

2014-08-12 Thread Stanislav Kholmanskikh
On 08/12/2014 04:24 PM, chru...@suse.cz wrote: > Hi! >> On some platforms LTP fails to compile, because (struct sigaction) >> doesn't have .sa_restorer member. For example - ia64. >> >> To overcome such failures we employ HAVE_SA_RESTORER define. >> &g

[LTP] [PATCH] rt_sigaction.h: define HAVE_SA_RESTORER for most platforms

2014-08-12 Thread Stanislav Kholmanskikh
On some platforms LTP fails to compile, because (struct sigaction) doesn't have .sa_restorer member. For example - ia64. To overcome such failures we employ HAVE_SA_RESTORER define. Signed-off-by: Stanislav Kholmanskikh --- Verified on SPARC, x86_64, i386. include/lapi/rt_sigaction.h |

Re: [LTP] [PATCH V2 3/3] ltp_rt_sigaction.h: added SPARC support

2014-08-12 Thread Stanislav Kholmanskikh
On 08/12/2014 01:04 PM, chru...@suse.cz wrote: > Hi! >>> I've started to prepare for release and tried to build LTP on as much >>> arch/distro combination I could, for ia64 the rt_sigaction fails with: >>> >>> In file included from rt_sigaction01.c:42: >>> [ 349s] ../../../../include/lapi/rt_sig

Re: [LTP] [PATCH V2 3/3] ltp_rt_sigaction.h: added SPARC support

2014-08-12 Thread Stanislav Kholmanskikh
On 08/11/2014 07:04 PM, chru...@suse.cz wrote: > Hi! Hi! > I've started to prepare for release and tried to build LTP on as much > arch/distro combination I could, for ia64 the rt_sigaction fails with: > > In file included from rt_sigaction01.c:42: > [ 349s] ../../../../include/lapi/rt_sigact

Re: [LTP] [PATCH] diotest4/fcntl16: Skip some dio/fcntl cases on NFS

2014-08-11 Thread Stanislav Kholmanskikh
Hi! On 08/11/2014 10:57 AM, Xiong Zhou wrote: > According to description of NFS and directIO in open(2), especially > "The Linux NFS client places no alignment restrictions on > O_DIRECT I/O", ignore some FAILs in diotest4. > > According to nfs(5), NLM supports advisory file locks only. So skip >

Re: [LTP] More observations on HEAD

2014-07-30 Thread Stanislav Kholmanskikh
On 07/29/2014 02:11 PM, chru...@suse.cz wrote: > Hi! >> Sorry, I overlooked that thread "[PATCH v2 1/2] lib/tst_res.c: introduce >> tst_record_childstatus()" already addresses these issues. > > And it took longer than it should because it require changes in the test > library. > > I've just commi

Re: [LTP] More observations on HEAD

2014-07-25 Thread Stanislav Kholmanskikh
On 07/25/2014 12:03 PM, Stanislav Kholmanskikh wrote: > > > On 07/19/2014 01:35 AM, Joseph Beckenbach wrote: >> Hi, all! > > Hi! > >> >> Feel free to ignore this -- it's an experience report of a cluster of runs >> I've just done agai

  1   2   3   4   5   >