public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH] cgroup/cpuctl: clean cpuctl_task_* in case of OOM
@ 2011-09-19  8:57 Jan Stancek
  0 siblings, 0 replies; only message in thread
From: Jan Stancek @ 2011-09-19  8:57 UTC (permalink / raw)
  To: ltp-list

[-- Attachment #1: Type: text/plain, Size: 396 bytes --]


If one of cpuctl_task_* gets killed by OOM, it won't
signal run script with SIGUSR1, and trap action
"killall cpuctl_task_*;" never runs.

Try to kill all left over cpuctl_task_* in cleanup() to be sure,
none are left behind.

Signed-off-by: Jan Stancek <jstancek@redhat.com>
---
  testcases/kernel/controllers/cpuctl/parameters.sh |    2 ++
  1 files changed, 2 insertions(+), 0 deletions(-)



[-- Attachment #2: 0001-cgroup-cpuctl-clean-cpuctl_task_-in-case-of-OOM.patch --]
[-- Type: text/x-patch, Size: 608 bytes --]

diff --git a/testcases/kernel/controllers/cpuctl/parameters.sh b/testcases/kernel/controllers/cpuctl/parameters.sh
index 502944e..5f87695 100755
--- a/testcases/kernel/controllers/cpuctl/parameters.sh
+++ b/testcases/kernel/controllers/cpuctl/parameters.sh
@@ -70,6 +70,8 @@ cleanup ()
         echo "Cleanup called";
 	killall cpuctl_def_task01 1>/dev/null 2>&1;
 	killall cpuctl_def_task02 1>/dev/null 2>&1;
+	killall cpuctl_task_* 1>/dev/null 2>&1;
+	sleep 1
         rm -f cpuctl_task_* 2>/dev/null
 	for task in `cat /dev/cpuctl/group_def/tasks`; do
 		echo $task > /dev/cpuctl/tasks 2>/dev/null 1>&2;


[-- Attachment #3: Type: text/plain, Size: 369 bytes --]

------------------------------------------------------------------------------
BlackBerry&reg; DevCon Americas, Oct. 18-20, San Francisco, CA
Learn about the latest advances in developing for the 
BlackBerry&reg; mobile platform with sessions, labs & more.
See new tools and technologies. Register for BlackBerry&reg; DevCon today!
http://p.sf.net/sfu/rim-devcon-copy1 

[-- Attachment #4: Type: text/plain, Size: 155 bytes --]

_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2011-09-19  8:57 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-19  8:57 [LTP] [PATCH] cgroup/cpuctl: clean cpuctl_task_* in case of OOM Jan Stancek

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