[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <op.2lkm90y3wjvjmi@hhuan26-mobl.amr.corp.intel.com>
Date: Mon, 01 Apr 2024 17:55:02 -0500
From: "Haitao Huang" <haitao.huang@...ux.intel.com>
To: "Jarkko Sakkinen" <jarkko@...nel.org>
Cc: anakrish@...rosoft.com, bp@...en8.de, cgroups@...r.kernel.org,
chrisyan@...rosoft.com, dave.hansen@...ux.intel.com, hpa@...or.com,
kai.huang@...el.com, kristen@...ux.intel.com, linux-kernel@...r.kernel.org,
linux-sgx@...r.kernel.org, mikko.ylinen@...ux.intel.com, mingo@...hat.com,
mkoutny@...e.com, seanjc@...gle.com, sohil.mehta@...el.com,
tglx@...utronix.de, tim.c.chen@...ux.intel.com, tj@...nel.org, x86@...nel.org,
yangjie@...rosoft.com, zhanb@...rosoft.com, zhiquan1.li@...el.com
Subject: Re: [PATCH] selftests/sgx: Improve cgroup test scripts
On Mon, 01 Apr 2024 09:22:21 -0500, Jarkko Sakkinen <jarkko@...nel.org>
wrote:
> On Sun Mar 31, 2024 at 8:44 PM EEST, Haitao Huang wrote:
>> Make cgroup test scripts ash compatible.
>> Remove cg-tools dependency.
>> Add documentation for functions.
>>
>> Tested with busybox on Ubuntu.
>>
>> Signed-off-by: Haitao Huang <haitao.huang@...ux.intel.com>
>
> I'll run this next week on good old NUC7. Thank you.
>
> I really wish that either (hopefully both) Intel or AMD would bring up
> for developers home use meant platform to develop on TDX and SNP. It is
> a shame that the latest and greatest is from 2018.
>
> BR, Jarkko
>
Argh, missed a few changes for v2 cgroup:
--- a/tools/testing/selftests/sgx/run_epc_cg_selftests.sh
+++ b/tools/testing/selftests/sgx/run_epc_cg_selftests.sh
@@ -15,6 +15,8 @@ CG_MEM_ROOT=/sys/fs/cgroup
CG_V1=0
if [ ! -d "/sys/fs/cgroup/misc" ]; then
echo "# cgroup V2 is in use."
+ echo "+misc" > $CG_MISC_ROOT/cgroup.subtree_control
+ echo "+memory" > $CG_MEM_ROOT/cgroup.subtree_control
else
echo "# cgroup V1 is in use."
CG_MISC_ROOT=/sys/fs/cgroup/misc
@@ -26,6 +28,11 @@ mkdir -p $CG_MISC_ROOT/$TEST_CG_SUB2
mkdir -p $CG_MISC_ROOT/$TEST_CG_SUB3
mkdir -p $CG_MISC_ROOT/$TEST_CG_SUB4
+if [ $CG_V1 -eq 0 ]; then
+echo "+misc" > $CG_MISC_ROOT/$TEST_ROOT_CG/cgroup.subtree_control
+echo "+misc" > $CG_MISC_ROOT/$TEST_CG_SUB1/cgroup.subtree_control
+fi
Powered by blists - more mailing lists