lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1460417755-18201-16-git-send-email-avagin@openvz.org>
Date:	Mon, 11 Apr 2016 16:35:55 -0700
From:	Andrey Vagin <avagin@...nvz.org>
To:	linux-kernel@...r.kernel.org
Cc:	Andrey Vagin <avagin@...nvz.org>, Oleg Nesterov <oleg@...hat.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Cyrill Gorcunov <gorcunov@...nvz.org>,
	Pavel Emelyanov <xemul@...allels.com>,
	Roger Luethi <rl@...lgate.ch>, Arnd Bergmann <arnd@...db.de>,
	Arnaldo Carvalho de Melo <acme@...nel.org>,
	David Ahern <dsahern@...il.com>,
	Andy Lutomirski <luto@...capital.net>,
	Pavel Odintsov <pavel.odintsov@...il.com>
Subject: [PATCH 15/15] test: check that task_diag can dump all thread of one process

Signed-off-by: Andrey Vagin <avagin@...nvz.org>
---
 tools/testing/selftests/task_diag/_run.sh | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/tools/testing/selftests/task_diag/_run.sh b/tools/testing/selftests/task_diag/_run.sh
index 559f02a..d2e8544 100755
--- a/tools/testing/selftests/task_diag/_run.sh
+++ b/tools/testing/selftests/task_diag/_run.sh
@@ -10,11 +10,15 @@ nchildren=`./task_diag_all children --pid 1 | grep 'pid.*tgid.*ppid.*comm fork$'
 
 ./task_diag_all one --pid 1 --cred
 
+( exec -a fork_thread ./fork 1 1234 )
+pid=`pidof fork_thread`
+ntaskthreads=`./task_diag_all thread --maps --cred --smaps --pid $pid |  grep 'pid.*tgid.*ppid.*comm' | wc -l`
 killall -9 fork
 
 [ "$nthreads"     -eq 10000 ] &&
 [ "$nprocesses"   -eq 1000  ] &&
 [ "$nchildren"    -eq 1000  ] &&
+[ "$ntaskthreads" -eq 1234  ] &&
 true ||  {
 	echo "Unexpected number of tasks $nthreads:$nprocesses" 1>&2
 	exit 1
-- 
2.5.5

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ