Skip to content
Commit 1e85591d authored by Kamalesh Babulal's avatar Kamalesh Babulal Committed by Tejun Heo
Browse files

kselftest/cgroup: Add cleanup() to test_cpuset_prs.sh



Install a cleanup function using the trap command for signals EXIT,
SIGINT, SIGQUIT and SIGABRT.  The cleanup function will perform:
1. Online the CPUs that were made offline during the test.
2. Removing the cgroups created.
3. Restoring the original /sys/kernel/debug/sched/verbose value,
   currently it's left turned on, irrespective of the original
   configuration value.

the test performs steps 1 and 2, on the successful runs, but not during
all of the failed runs.  With the cleanup(), the system will perform all
three steps during failed/passed test runs.

Signed-off-by: default avatarKamalesh Babulal <kamalesh.babulal@oracle.com>
Acked-by: default avatarWaiman Long <longman@redhat.com>
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
parent 7fd4da9c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment