@@ -125,32 +125,41 @@ Note that some tests will require root privileges.
125125Install selftests
126126=================
127127
128- You can use the kselftest_install.sh tool to install selftests in the
129- default location, which is tools/testing/selftests/kselftest, or in a
130- user specified location.
128+ You can use the "install" target of "make" (which calls the ` kselftest_install.sh `
129+ tool) to install selftests in the default location (` tools/testing/selftests/kselftest_install `),
130+ or in a user specified location via the ` INSTALL_PATH ` "make" variable .
131131
132132To install selftests in default location::
133133
134- $ cd tools/testing/selftests
135- $ ./kselftest_install.sh
134+ $ make -C tools/testing/selftests install
136135
137136To install selftests in a user specified location::
138137
139- $ cd tools/testing/selftests
140- $ ./kselftest_install.sh install_dir
138+ $ make -C tools/testing/selftests install INSTALL_PATH=/some/other/path
141139
142140Running installed selftests
143141===========================
144142
145- Kselftest install as well as the Kselftest tarball provide a script
146- named " run_kselftest.sh" to run the tests.
143+ Found in the install directory, as well as in the Kselftest tarball,
144+ is a script named ` run_kselftest.sh ` to run the tests.
147145
148146You can simply do the following to run the installed Kselftests. Please
149147note some tests will require root privileges::
150148
151- $ cd kselftest
149+ $ cd kselftest_install
152150 $ ./run_kselftest.sh
153151
152+ To see the list of available tests, the `-l ` option can be used::
153+
154+ $ ./run_kselftest.sh -l
155+
156+ The `-c ` option can be used to run all the tests from a test collection, or
157+ the `-t ` option for specific single tests. Either can be used multiple times::
158+
159+ $ ./run_kselftest.sh -c bpf -c seccomp -t timers:posix_timers -t timer:nanosleep
160+
161+ For other features see the script usage output, seen with the `-h ` option.
162+
154163Packaging selftests
155164===================
156165
@@ -160,9 +169,9 @@ different system. To package selftests, run::
160169 $ make -C tools/testing/selftests gen_tar
161170
162171This generates a tarball in the `INSTALL_PATH/kselftest-packages ` directory. By
163- default, `.gz ` format is used. The tar format can be overridden by specifying
164- a `FORMAT ` make variable. Any value recognized by `tar's auto-compress `_ option
165- is supported, such as::
172+ default, `.gz ` format is used. The tar compression format can be overridden by
173+ specifying a `FORMAT ` make variable. Any value recognized by `tar's auto-compress `_
174+ option is supported, such as::
166175
167176 $ make -C tools/testing/selftests gen_tar FORMAT=.xz
168177
0 commit comments