RE: [PATCH 1/3] selftests/resctrl: Make resctrl_tests run using kselftest framework

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Reinette

> On 11/10/2021 1:33 AM, Shaopeng Tan wrote:
> > From: "Tan, Shaopeng" <tan.shaopeng@xxxxxxxxxxxxxx>
> >
> > This commit enables kselftest to be built/run in resctrl framework.
> > Build/run resctrl_tests by build/run all tests of kselftest, or by
> > using the "TARGETS" variable on the make command line to specify
> resctrl_tests.
> > To make resctrl_tests run using kselftest framework, this commit
> > modified the Makefile of kernel kselftest set and the Makefile of
> resctrl_tests.
> 
> The above sentence mentions that changes were made to the resctrl selftest
> Makefile but it does not describe what the change accomplish or why they are
> needed. Could you please elaborate?

Before these changes of Makefile, when we run resctrl test,
we need to goto tools/testing/selftests/resctrl/ directory,
run "make" to build executable file "resctrl_tests",
and run "sudo ./resctrl_tests" to execute the test.

With this patch, we can resctrl test in selftest framwork as follow.
Run all tests include resctrl:
 $ make -C tools/testing/selftests run_tests
Run a subset(resctrl) of selftests:
 $ make -C tools/testing/selftests TARGETS=resctrl run_tests

Linux Kernel Selftests :
https://www.kernel.org/doc/html/latest/dev-tools/kselftest.html 

> > To ensure the resctrl_tests finish in limited time, this commit
> > changed the default limited time(45s) to 120 seconds for resctrl_tests
> > by adding "setting" file.
> 
> How is changing the timeout related to the resctrl framework changes? Is it not
> a separate change?

In selftest framwork, the default limited time of all tests is 45 seconds
which is specified by common file tools/testing/selftests/kselftest/runner.sh.
Each test can change the limited time individually by adding a "setting" 
file into its own directory. I changed the limited time of resctrl to120s 
because 45s was not enough in my environment.

Regards,
Shaopeng Tan




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux