<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/tools/testing/selftests/livepatch, branch v5.4</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v5.4</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v5.4'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2019-09-23T14:33:16Z</updated>
<entry>
<title>selftests: livepatch: add missing fragments to config</title>
<updated>2019-09-23T14:33:16Z</updated>
<author>
<name>Anders Roxell</name>
<email>anders.roxell@linaro.org</email>
</author>
<published>2019-08-14T11:16:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=955a0f3310081731a1756a1d7bd742600ee69ffc'/>
<id>urn:sha1:955a0f3310081731a1756a1d7bd742600ee69ffc</id>
<content type='text'>
When generating config with 'make defconfig kselftest-merge' fragment
CONFIG_TEST_LIVEPATCH=m isn't set.

Rework to enable CONFIG_LIVEPATCH and CONFIG_DYNAMIC_DEBUG as well.

Signed-off-by: Anders Roxell &lt;anders.roxell@linaro.org&gt;
Signed-off-by: Shuah Khan &lt;skhan@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>selftests/livepatch: push and pop dynamic debug config</title>
<updated>2019-07-30T21:47:10Z</updated>
<author>
<name>Joe Lawrence</name>
<email>joe.lawrence@redhat.com</email>
</author>
<published>2019-07-18T20:29:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fbb01c52471c8fb4ec2422c0ab26c134bd90bbff'/>
<id>urn:sha1:fbb01c52471c8fb4ec2422c0ab26c134bd90bbff</id>
<content type='text'>
The livepatching self-tests tweak the dynamic debug config to verify
the kernel log during the tests.  Enhance set_dynamic_debug() so that
the config changes are restored when the script exits.

Note this functionality needs to keep in sync with:
  - dynamic_debug input/output formatting
  - functions affected by set_dynamic_debug()

  For example, push_dynamic_debug() transforms:
    kernel/livepatch/transition.c:530 [livepatch]klp_init_transition =_ "'%s': initializing %s transition\012"
  to the following:
    file kernel/livepatch/transition.c line 530 =_

Signed-off-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Tested-by: Petr Mladek &lt;pmladek@suse.com&gt;
Signed-off-by: Shuah Khan &lt;skhan@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>selftests/livepatch: add test skip handling</title>
<updated>2019-07-24T20:17:46Z</updated>
<author>
<name>Joe Lawrence</name>
<email>joe.lawrence@redhat.com</email>
</author>
<published>2019-07-24T20:05:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=527d37e9e575bc0e9024de9b499385e7bb31f1ad'/>
<id>urn:sha1:527d37e9e575bc0e9024de9b499385e7bb31f1ad</id>
<content type='text'>
Add a skip() message function that stops the test, logs an explanation,
and sets the "skip" return code (4).

Before loading a livepatch self-test kernel module, first verify that
we've built and installed it by running a 'modprobe --dry-run'.  This
should catch a few environment issues, including !CONFIG_LIVEPATCH and
!CONFIG_TEST_LIVEPATCH.  In these cases, exit gracefully with the new
skip() function.

Reported-by: Jiri Benc &lt;jbenc@redhat.com&gt;
Suggested-by: Shuah Khan &lt;shuah@kernel.org&gt;
Reviewed-by: Petr Mladek &lt;pmladek@suse.com&gt;
Signed-off-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Signed-off-by: Shuah Khan &lt;skhan@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>selftests/livepatch: Add functions.sh to TEST_PROGS_EXTENDED</title>
<updated>2019-04-15T08:43:21Z</updated>
<author>
<name>Miroslav Benes</name>
<email>mbenes@suse.cz</email>
</author>
<published>2019-04-12T13:37:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=802c2471607919f57d7d1f83f0fddd925309e97c'/>
<id>urn:sha1:802c2471607919f57d7d1f83f0fddd925309e97c</id>
<content type='text'>
Add functions.sh to TEST_PROGS_EXTENDED so that it is installed along
with the rest of the selftests and they can be run.

Originally-by: Shuah Khan &lt;shuah@kernel.org&gt;
Signed-off-by: Miroslav Benes &lt;mbenes@suse.cz&gt;
Acked-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Signed-off-by: Petr Mladek &lt;pmladek@suse.com&gt;
</content>
</entry>
<entry>
<title>selftests/livepatch: use TEST_PROGS for test scripts</title>
<updated>2019-03-27T08:57:46Z</updated>
<author>
<name>Joe Lawrence</name>
<email>joe.lawrence@redhat.com</email>
</author>
<published>2019-03-26T15:26:01Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=abfe3c4560684864f66641438fee3075de098e89'/>
<id>urn:sha1:abfe3c4560684864f66641438fee3075de098e89</id>
<content type='text'>
Adrian reports that 'make -C tools clean' results in removal of the
livepatch selftest shell scripts.

As per the selftest lib.mk file, TEST_PROGS are for test shell scripts,
not TEST_GEN_PROGS.  Adjust the livepatch selftest Makefile accordingly.

Reported-by: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Signed-off-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Tested-by: Adrian Hunter &lt;adrian.hunter@intel.com&gt;
Signed-off-by: Petr Mladek &lt;pmladek@suse.com&gt;
</content>
</entry>
<entry>
<title>livepatch/selftests: use "$@" to preserve argument list</title>
<updated>2019-02-12T09:58:47Z</updated>
<author>
<name>Joe Lawrence</name>
<email>joe.lawrence@redhat.com</email>
</author>
<published>2019-02-08T20:57:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fbb76d579dff4a2e332566dcd1d5979ac92bc34b'/>
<id>urn:sha1:fbb76d579dff4a2e332566dcd1d5979ac92bc34b</id>
<content type='text'>
The livepatch selftest functions.sh library uses "$*" and an
intermediate variable to extract and then pass arguments from function
to function call.  The effect of this combination is that the argument
list is flattened into a single argument.  Sometimes this is benign, but
in cases like __load_mod(), the modprobe invocation will interpret all
the module parameters as a single parameter.

Drop the intermediate variable and use the "$@" special parameter as
described in the bash manual.

Link: https://www.gnu.org/software/bash/manual/bash.html#Special-Parameters
Signed-off-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Reviewed-by: Kamalesh Babulal &lt;kamalesh@linux.vnet.ibm.com&gt;
Acked-by: Miroslav Benes &lt;mbenes@suse.cz&gt;
Signed-off-by: Petr Mladek &lt;pmladek@suse.com&gt;
</content>
</entry>
<entry>
<title>selftests/livepatch: introduce tests</title>
<updated>2019-01-11T19:51:24Z</updated>
<author>
<name>Joe Lawrence</name>
<email>joe.lawrence@redhat.com</email>
</author>
<published>2019-01-09T12:43:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a2818ee4dce575b299d8a7f46b393bc2b02ef1f4'/>
<id>urn:sha1:a2818ee4dce575b299d8a7f46b393bc2b02ef1f4</id>
<content type='text'>
Add a few livepatch modules and simple target modules that the included
regression suite can run tests against:

  - basic livepatching (multiple patches, atomic replace)
  - pre/post (un)patch callbacks
  - shadow variable API

Signed-off-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Signed-off-by: Petr Mladek &lt;pmladek@suse.com&gt;
Tested-by: Miroslav Benes &lt;mbenes@suse.cz&gt;
Tested-by: Alice Ferrazzi &lt;alice.ferrazzi@gmail.com&gt;
Acked-by: Joe Lawrence &lt;joe.lawrence@redhat.com&gt;
Acked-by: Josh Poimboeuf &lt;jpoimboe@redhat.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
</feed>
