On Tue, Oct 08, 2019 at 03:55:46PM +0100, Alan Maguire wrote: > Documentation should describe how to build kunit and tests as > modules. > > Signed-off-by: Alan Maguire <alan.maguire@xxxxxxxxxx> > Signed-off-by: Knut Omang <knut.omang@xxxxxxxxxx> > > --- > Documentation/dev-tools/kunit/faq.rst | 3 ++- > Documentation/dev-tools/kunit/index.rst | 3 +++ > Documentation/dev-tools/kunit/usage.rst | 16 ++++++++++++++++ > 3 files changed, 21 insertions(+), 1 deletion(-) [...] > diff --git a/Documentation/dev-tools/kunit/usage.rst b/Documentation/dev-tools/kunit/usage.rst > index c6e6963..fa0f03f 100644 > --- a/Documentation/dev-tools/kunit/usage.rst > +++ b/Documentation/dev-tools/kunit/usage.rst > @@ -539,6 +539,22 @@ Interspersed in the kernel logs you might see the following: > > Congratulations, you just ran a KUnit test on the x86 architecture! > > +In a similar manner, kunit and kunit tests can also be built as modules, > +so if you wanted to run tests in this way you might add the following config > +options to your ``.config``: > + > +.. code-block:: none > + > + CONFIG_KUNIT=m > + CONFIG_KUNIT_EXAMPLE_TEST=m This doesn't appear to be properly tabbed. > +Once the kernel is built and installed, a simple > + > +.. code-block:: bash > + modprobe example-test > + > +...will run the tests. > + > Writing new tests for other architectures > ----------------------------------------- > > -- > 1.8.3.1 >