public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH 0/3] add new syscall test for setns(2)
@ 2013-02-05 15:57 Jan Stancek
  2013-02-05 15:57 ` [LTP] [PATCH 1/3] setns: setup directory at kernel/syscalls/setns Jan Stancek
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Jan Stancek @ 2013-02-05 15:57 UTC (permalink / raw)
  To: ltp-list

This patchset adds 2 new syscall tests for setns(2).
Sample output:

setns01     1  TPASS  :  invalid fd exp_errno=9
setns01     2  TPASS  :  regular file fd exp_errno=22
setns01     3  TPASS  :  invalid ns_type exp_errno=22
setns01     4  TPASS  :  mismatch ns_type/fd exp_errno=22
setns01     5  TPASS  :  without CAP_SYS_ADMIN exp_errno=1

setns02     0  TINFO  :  test_newuts
setns02     0  TINFO  :  creating child with clone_flag=0x4000000, ns_flag=0x4000000
setns02     0  TINFO  :  (child) hostnane (inherited from parent): dhcp-27-145.brq.redhat.com
setns02     0  TINFO  :  (child) hostname changed to: setns_dummy_uts
setns02     1  TPASS  :  (child) hostname is different in parent/child
setns02     0  TINFO  :  (child) attemping to switch ns back to parent ns
setns02     0  TINFO  :  (child) hostname: dhcp-27-145.brq.redhat.com
setns02     2  TPASS  :  (child) hostname now as expected
setns02     1  TPASS  :  child finished succesfully
setns02     0  TINFO  :  creating child with clone_flag=0x4000000, ns_flag=0x0
setns02     0  TINFO  :  (child) hostnane (inherited from parent): dhcp-27-145.brq.redhat.com
setns02     0  TINFO  :  (child) hostname changed to: setns_dummy_uts
setns02     2  TPASS  :  (child) hostname is different in parent/child
setns02     0  TINFO  :  (child) attemping to switch ns back to parent ns
setns02     0  TINFO  :  (child) hostname: dhcp-27-145.brq.redhat.com
setns02     3  TPASS  :  (child) hostname now as expected
setns02     2  TPASS  :  child finished succesfully
setns02     0  TINFO  :  test_newipc
setns02     0  TINFO  :  creating child with clone_flag=0x8000000, ns_flag=0x8000000
setns02     3  TPASS  :  (child) shmat failed as expected: errno=EINVAL(22): Invalid argument
setns02     0  TINFO  :  (child) attemping to switch ns back to parent ns
setns02     4  TPASS  :  (child) shmat suceeded
setns02     3  TPASS  :  child finished succesfully
setns02     0  TINFO  :  creating child with clone_flag=0x8000000, ns_flag=0x0
setns02     4  TPASS  :  (child) shmat failed as expected: errno=EINVAL(22): Invalid argument
setns02     0  TINFO  :  (child) attemping to switch ns back to parent ns
setns02     5  TPASS  :  (child) shmat suceeded
setns02     4  TPASS  :  child finished succesfully

Jan Stancek (3):
  setns: setup directory at kernel/syscalls/setns
  setns: add new syscall test setns01
  setns: add new syscall test setns02

 runtest/syscalls                          |    3 +
 testcases/kernel/syscalls/.gitignore      |    2 +
 testcases/kernel/syscalls/setns/Makefile  |   22 +++
 testcases/kernel/syscalls/setns/setns.h   |   41 +++++
 testcases/kernel/syscalls/setns/setns01.c |  245 +++++++++++++++++++++++++++++
 testcases/kernel/syscalls/setns/setns02.c |  231 +++++++++++++++++++++++++++
 6 files changed, 544 insertions(+), 0 deletions(-)
 create mode 100644 testcases/kernel/syscalls/setns/Makefile
 create mode 100644 testcases/kernel/syscalls/setns/setns.h
 create mode 100644 testcases/kernel/syscalls/setns/setns01.c
 create mode 100644 testcases/kernel/syscalls/setns/setns02.c


------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013 
and get the hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

end of thread, other threads:[~2013-02-06  9:07 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-05 15:57 [LTP] [PATCH 0/3] add new syscall test for setns(2) Jan Stancek
2013-02-05 15:57 ` [LTP] [PATCH 1/3] setns: setup directory at kernel/syscalls/setns Jan Stancek
2013-02-06  8:44   ` Wanlong Gao
2013-02-05 15:57 ` [LTP] [PATCH 2/3] setns: add new syscall test setns01 Jan Stancek
2013-02-06  7:05   ` Wanlong Gao
2013-02-06  8:48     ` Wanlong Gao
2013-02-06  8:57       ` Jan Stancek
2013-02-06  9:07         ` Wanlong Gao
2013-02-05 15:57 ` [LTP] [PATCH 3/3] setns: add new syscall test setns02 Jan Stancek
2013-02-06  8:44   ` Wanlong Gao

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