On Thu, 2024-06-06 at 09:53 -0400, Ryan Sullivan wrote:
> Define a maximum allowable number of pids that can be livepatched in
> test-syscall.sh as with extremely large machines the output from a
> large number of processes overflows the dev/kmsg "expect" buffer in
> the "check_result" function
On Tue, 2024-06-04 at 14:10 -0400, Joe Lawrence wrote:
> On Mon, Jun 03, 2024 at 02:26:19PM -0300, Marcos Paulo de Souza
> wrote:
> > Adapt the current test-livepatch.sh script to account the number of
> > applied livepatches and ensure that an atomic replace livepatch
&g
On Mon, 2024-06-03 at 14:26 -0300, Marcos Paulo de Souza wrote:
> Adapt the current test-livepatch.sh script to account the number of
> applied livepatches and ensure that an atomic replace livepatch
> disables
> all previously applied livepatches.
>
> Signed-off-by: Mar
On Mon, 2024-06-03 at 14:52 +0200, Petr Mladek wrote:
> On Fri 2024-05-31 18:06:48, Marcos Paulo de Souza wrote:
> > On Fri, 2024-05-31 at 15:44 -0400, Joe Lawrence wrote:
> > > On Sat, May 25, 2024 at 11:34:08AM -0300, Marcos Paulo de Souza
> > > wrote:
> > > &
Adapt the current test-livepatch.sh script to account the number of
applied livepatches and ensure that an atomic replace livepatch disables
all previously applied livepatches.
Signed-off-by: Marcos Paulo de Souza
---
Changes since v2:
* Used variables to stop the name of other livepatches
On Fri, 2024-05-31 at 15:44 -0400, Joe Lawrence wrote:
> On Sat, May 25, 2024 at 11:34:08AM -0300, Marcos Paulo de Souza
> wrote:
> > Adapt the current test-livepatch.sh script to account the number of
> > applied livepatches and ensure that an atomic replace livepatch
&g
expect" buffer in
> the "check_result" function and causes a false error.
I believe that 128 threads hammering getpid is good enough :)
Tested-by: Marcos Paulo de Souza
Reviewed-by: Marcos Paulo de Souza
>
> Reported-by: CKI Project
> Signed-off-by: Ryan Sullivan
> -
Adapt the current test-livepatch.sh script to account the number of
applied livepatches and ensure that an atomic replace livepatch disables
all previously applied livepatches.
Signed-off-by: Marcos Paulo de Souza
---
Changes since v1:
* Added checks in the existing test-livepatch.sh instead
On Thu, 2024-03-21 at 10:08 -0400, Joe Lawrence wrote:
> On 3/12/24 08:12, Marcos Paulo de Souza wrote:
> > This new test checks if a livepatch with replace attribute set
> > replaces
> > all previously applied livepatches.
> >
> > Signed-off-by: Marcos Paulo de
This new test checks if a livepatch with replace attribute set replaces
all previously applied livepatches.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/livepatch/Makefile | 3 +-
.../selftests/livepatch/test-atomic-replace.sh | 71 ++
2
On Wed, 28 Feb 2024 15:28:14 -0700 Shuah Khan wrote:
> On 2/28/24 00:21, kernelci.org bot wrote:
> > kselftest/next kselftest-livepatch: 1 runs, 1 regressions
> > (v6.8-rc1-56-g539cd3f4da3f)
> >
> > Regressions Summary
> > ---
> >
> > platform| arch | lab |
On Fri, 23 Feb 2024 21:59:44 -0800 (PST) "kernelci.org bot"
wrote:
> kselftest/next kselftest-livepatch: 1 runs, 1 regressions
> (v6.8-rc1-53-gae638551ab64a)
>
> Regressions Summary
> ---
>
> platform| arch | lab | compiler | defconfig
>
On Wed, 21 Feb 2024 14:17:06 -0300 Marcos Paulo de Souza
wrote:
Shuah, please skip this one. The simplification is not worthy if it causes a new
warning. This reply[1] explains what's going on.
Thanks in advance,
Marcos
[1]:
https://lore.kernel.org/linux-kselftest/20240223161244.17709-1
On Fri, 23 Feb 2024 15:07:20 -0700 Shuah Khan wrote:
> On 2/21/24 15:04, Marcos Paulo de Souza wrote:
> > On Wed, 21 Feb 2024 14:12:00 -0700 Shuah Khan
> > wrote:
> >
> >> On 2/21/24 05:26, Marcos Paulo de Souza wrote:
> >>> On Tue, 20 Feb 20
On Fri, 23 Feb 2024 11:40:00 +0800 Yujie Liu wrote:
> On Wed, Feb 21, 2024 at 09:29:47AM -0300, Marcos Paulo de Souza wrote:
> > On Mon, 19 Feb 2024 15:16:51 +0800 kernel test robot wrote:
> >
> > > Hi Marcos,
> > >
> > > kernel test
On Thu, 22 Feb 2024 09:28:19 +0800 Yujie Liu wrote:
> On Wed, Feb 21, 2024 at 07:04:03PM -0300, Marcos Paulo de Souza wrote:
> > On Wed, 21 Feb 2024 14:12:00 -0700 Shuah Khan
> > wrote:
> >
> > > On 2/21/24 05:26, Marcos Paulo de Souza wrote:
> > > >
On Wed, 21 Feb 2024 14:12:00 -0700 Shuah Khan wrote:
> On 2/21/24 05:26, Marcos Paulo de Souza wrote:
> > On Tue, 20 Feb 2024 17:19:54 -0700 Shuah Khan
> > wrote:
> >
> >> On 2/19/24 06:53, Marcos Paulo de Souza wrote:
> >>> On Mon, 19 Feb
We don't need new targets only to run two make modules and make clean.
We can test if TEST_GEN_MODS_DIR is specified, and then run the
commands.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/lib.mk | 16 +++-
1 file changed, 7 insertions(+), 9 deletions(-)
diff
The directory itself doesn't need have path handling, since it's only to
mean where is the directory that contains modules to be built.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/lib.mk | 3 ---
1 file changed, 3 deletions(-)
diff --git a/tools/testing/selftests/lib.mk b
-by: Marcos Paulo de Souza
---
tools/testing/selftests/livepatch/functions.sh | 13 +
tools/testing/selftests/livepatch/test_modules/Makefile | 6 ++
2 files changed, 19 insertions(+)
diff --git a/tools/testing/selftests/livepatch/functions.sh
b/tools/testing/selftests
Ignore the binary used to test livepatching a syscall.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/livepatch/.gitignore | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/testing/selftests/livepatch/.gitignore
b/tools/testing/selftests/livepatch/.gitignore
new file
-by: Marcos Paulo de Souza
---
Changes in v2:
- Added a new patch to avoid building the modules/running the tests if
kernel-devel is not installed. Resolving an issue reported by the
build bot.
- Reordered the patches, showing the more simple ones first. Besides
patch 0002, all the other three didn't
On Mon, 19 Feb 2024 15:16:51 +0800 kernel test robot wrote:
> Hi Marcos,
>
> kernel test robot noticed the following build warnings:
>
> [auto build test WARNING on 345e8abe4c355bc24bab3f4a5634122e55be8665]
>
> url:
> https://github.com/intel-lab-lkp/linux/commi
On Tue, 20 Feb 2024 17:19:54 -0700 Shuah Khan wrote:
> On 2/19/24 06:53, Marcos Paulo de Souza wrote:
> > On Mon, 19 Feb 2024 09:15:15 -0300 Marcos Paulo de Souza
> > wrote:
> >
> >> On Mon, 19 Feb 2024 14:35:16 +0800 kernel test robot
> >> wrote:
&
On Tue, 20 Feb 2024 17:23:49 +0530 (GMT+05:30) Shresth Prasad
wrote:
> Looking at the function definition now, I do see that the function returns a
> struct pointer but for me the compiler still complains about an implicit
> conversion from int to struct pointer.
>
> Is there any particular
On Sat, 17 Feb 2024 04:21:26 +0530 Shresth Prasad
wrote:
> The function `klp_get_state` returns an `int` value, but the variable
> `loglevel_state` is of type `struct klp_state *` and thus does an
> implicit cast. Explicitly casting these values fixes:
>
> - warning:
On Mon, 19 Feb 2024 09:15:15 -0300 Marcos Paulo de Souza
wrote:
> On Mon, 19 Feb 2024 14:35:16 +0800 kernel test robot wrote:
>
> > Hi Marcos,
> >
> > kernel test robot noticed the following build errors:
> >
> > [auto build test ERROR on 345e
On Mon, 19 Feb 2024 14:35:16 +0800 kernel test robot wrote:
> Hi Marcos,
>
> kernel test robot noticed the following build errors:
>
> [auto build test ERROR on 345e8abe4c355bc24bab3f4a5634122e55be8665]
>
> url:
> https://github.com/intel-lab-lkp/linux/commi
Commit f04a32b2c5b5 ("selftests/bpf: Do not use sign-file as testcase")
removed the TEST_CUSTOM_PROGS assignment, and removed it from being used
on TEST_GEN_FILES. Remove two leftovers from that cleanup.
Found by inspection.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/sel
Ignore the binary used to test livepatching a syscall.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/livepatch/.gitignore | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/testing/selftests/livepatch/.gitignore
b/tools/testing/selftests/livepatch/.gitignore
new file
We don't need new targets only to run two make modules and make clean.
We can test if TEST_GEN_MODS_DIR is specified, and then run the
commands.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/lib.mk | 16 +++-
1 file changed, 7 insertions(+), 9 deletions(-)
diff
The directory itself doesn't need have path handling, since it's only to
mean where is the directory that contains modules to be built.
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/lib.mk | 3 ---
1 file changed, 3 deletions(-)
diff --git a/tools/testing/selftests/lib.mk b
de Souza
---
Marcos Paulo de Souza (3):
selftests: lib.mk: Do not process TEST_GEN_MODS_DIR
selftests: lib.mk: Simplify TEST_GEN_MODS_DIR handling
selftests: livepatch: Add initial .gitignore
tools/testing/selftests/lib.mk | 19 +++
tools/testing
On Mon, 2024-01-22 at 10:15 -0700, Shuah Khan wrote:
> On 1/12/24 10:43, Marcos Paulo de Souza wrote:
> > Add TEST_GEN_MODS_DIR variable for kselftests. It can point to
> > a directory containing kernel modules that will be used by
> > selftest scripts.
> >
> >
On Fri, 2024-01-19 at 14:19 +0100, Alexander Gordeev wrote:
> On Fri, Jan 19, 2024 at 02:11:01PM +0100, Alexander Gordeev wrote:
> > FWIW, for s390 part:
> >
> > Alexander Gordeev
>
> Acked-by: Alexander Gordeev
Thanks Alexandre and Joe for testing and supporting the change.
Shuah, now that
Lawrence
Reviewed-by: Petr Mladek
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/livepatch/Makefile | 4 +-
tools/testing/selftests/livepatch/test-syscall.sh | 53 ++
.../selftests/livepatch/test_klp-call_getpid.c | 44
.../selftests/livepatch
ewed-by: Petr Mladek
Signed-off-by: Marcos Paulo de Souza
---
MAINTAINERS| 1 -
arch/s390/configs/debug_defconfig | 1 -
arch/s390/configs/defconfig| 1 -
lib/Kconfig.debug
r Mladek
Signed-off-by: Marcos Paulo de Souza
---
Documentation/dev-tools/kselftest.rst | 4
tools/testing/selftests/lib.mk| 26 +-
2 files changed, 25 insertions(+), 5 deletions(-)
diff --git a/Documentation/dev-tools/kselftest.rst
b/Documentation/dev-tools
pectations. For the current
approach to be truly system agnostic gen_tar would need to include the module
and program sources to be compiled in the target systems.
Thanks in advance!
Marcos
Signed-off-by: Marcos Paulo de Souza
---
Marcos Paulo de Souza (3):
kselftests: lib.mk: Add TEST_GEN_MODS_DI
On Tue, 2024-01-09 at 12:31 -0700, Shuah Khan wrote:
> On 1/8/24 10:13, Marcos Paulo de Souza wrote:
> > On Wed, 2024-01-03 at 15:09 -0700, Shuah Khan wrote:
>
> > >
> > > Copying source files and object files doesn't sound right. This
> > > isn't
> >
Lawrence
Signed-off-by: Marcos Paulo de Souza
---
tools/testing/selftests/livepatch/Makefile | 4 +-
tools/testing/selftests/livepatch/test-syscall.sh | 53 ++
.../selftests/livepatch/test_klp-call_getpid.c | 44
.../selftests/livepatch/test_modules/Makefile
igned-off-by: Marcos Paulo de Souza
---
MAINTAINERS| 1 -
arch/s390/configs/debug_defconfig | 1 -
arch/s390/configs/defconfig| 1 -
lib/Kconfig.debug | 22
LE is needed because INSTALL_SINGLE_RULE would
copy the entire TEST_GEN_MODS_DIR directory to the destination, even
the files created by Kbuild to compile the modules. The new install
rule copies only the .ko files, as we would expect the gen_tar to work.
Reviewed-by: Joe Lawrence
Signed-off-by: M
he current
approach to be truly system agnostic gen_tar would need to include the module
and program sources to be compiled in the target systems.
Thanks in advance!
Marcos
Signed-off-by: Marcos Paulo de Souza
---
Marcos Paulo de Souza (3):
kselftests: lib.mk: Add TEST_GEN_MODS_DI
On Wed, 2024-01-03 at 15:09 -0700, Shuah Khan wrote:
> On 1/2/24 15:31, Joe Lawrence wrote:
> > On Wed, Dec 20, 2023 at 01:53:12PM -0300, Marcos Paulo de Souza
> > wrote:
> > > Add TEST_GEN_MODS_DIR variable for kselftests. It can point to
> > > a di
wk I had to do some manual
testing to understand that the syntax you used "prints everything after
the $last_dmesg_msg message on dmesg". Either way, it's better then
using 'comm' utility. I tested on my x86_64 VM, and the tests passed as
expected.
LGTM, so
Tested-by: Marcos Paulo
On Wed, 2023-12-20 at 13:53 -0300, Marcos Paulo de Souza wrote:
> Changes in v4:
> * Documented how to compile the livepatch selftests without running
> the
> tests (Joe)
> * Removed the mention to lib/livepatch on MAINTAINERS file, reported
> by
> check
..b76a881d4013
--- /dev/null
+++ b/tools/testing/selftests/livepatch/test-syscall.sh
@@ -0,0 +1,53 @@
+#!/bin/bash
+# SPDX-License-Identifier: GPL-2.0
+# Copyright (C) 2023 SUSE
+# Author: Marcos Paulo de Souza
+
+. $(dirname $0)/functions.sh
+
+MOD_SYSCALL=test_klp_syscall
+
+setup_config
d host.
Note that these modules need not binary compatible with
the kernel built from the same sources. But the same
is true for other packaged selftest binaries.
The entire kernel sources are needed for rebuilding
the selftests on another system.
Signed-off-by: M
tically built before running the tests via
make -C tools/testing/selftests/livepatch/ run_tests
Note that they are _not_ built when running the standalone
tests by calling, for example, ./test-state.sh.
Signed-off-by: Marcos Paulo de Souza
---
Documentation/dev-tools/kselftest.rst | 4
too
!
Marcos
Signed-off-by: Marcos Paulo de Souza
---
Marcos Paulo de Souza (3):
kselftests: lib.mk: Add TEST_GEN_MODS_DIR variable
livepatch: Move tests from lib/livepatch to selftests/livepatch
selftests: livepatch: Test livepatching a heavily called syscall
Documentation
On Mon, 2023-12-18 at 13:47 -0700, Shuah Khan wrote:
> On 12/15/23 13:36, Joe Lawrence wrote:
> > On 12/11/23 16:53, Shuah Khan wrote:
> > > On 12/6/23 07:39, Miroslav Benes wrote:
> > > > Hi,
> > > >
> > > > On Tue, 5 Dec 2023, Shuah Khan wrote:
> > > >
> > > > > On 12/5/23 05:52,
>
> > > > > On Tue, Oct 31, 2023 at 06:10:52PM -0300, Marcos Paulo de
> > > > > Souza
> > > > > wrote:
> > > > > > The modules are being moved from lib/livepatch to
> > > > > > tools/testing/selftest
On Mon, 2023-12-11 at 16:00 +0500, Muhammad Usama Anjum wrote:
> On 12/9/23 7:01 AM, John Hubbard wrote:
> > This reverts commit 9fc96c7c19df ("selftests: error out if kernel
> > header
> > files are not yet built").
> I don't think whole of this commit needs to be reverted. Lets leave
> the
>
On Thu, Nov 30, 2023 at 04:24:26PM -0700, Shuah Khan wrote:
> On 10/31/23 15:10, Marcos Paulo de Souza wrote:
> > The test proves that a syscall can be livepatched. It is interesting
> > because syscalls are called a tricky way. Also the process gets
> > livepatched
Humble ping :)
On Tue, Oct 31, 2023 at 06:10:50PM -0300, Marcos Paulo de Souza wrote:
> This patchset moves the current kernel testing livepatch modules from
> lib/livepatches to tools/testing/selftest/livepatch/test_modules, and compiles
> them as out-of-tree modules befor
eeded for rebuilding
the selftests on another system.
Signed-off-by: Marcos Paulo de Souza
---
arch/s390/configs/debug_defconfig | 1 -
arch/s390/configs/defconfig| 1 -
lib/Kconfig.debug | 22
..b76a881d4013
--- /dev/null
+++ b/tools/testing/selftests/livepatch/test-syscall.sh
@@ -0,0 +1,53 @@
+#!/bin/bash
+# SPDX-License-Identifier: GPL-2.0
+# Copyright (C) 2023 SUSE
+# Author: Marcos Paulo de Souza
+
+. $(dirname $0)/functions.sh
+
+MOD_SYSCALL=test_klp_syscall
+
+setup_config
nel.org
Cc: linux-s...@vger.kernel.org
Cc: live-patch...@vger.kernel.org
Signed-off-by: Marcos Paulo de Souza
Changes in v3:
* Rebased on top of v6.6-rc5
* The commits messages were improved (Thanks Petr!)
* Created TEST_GEN_MODS_DIR variable to point to a directly that contains kernel
modules,
tically built before running the tests via
make -C tools/testing/selftests/livepatch/ run_tests
Note that they are _not_ built when running the standalone
tests by calling, for example, ./test-state.sh.
Signed-off-by: Marcos Paulo de Souza
---
Documentation/dev-tools/kselftest.rst | 4
too
Hi,
while testing a new patch on the livepatch kselftests, I was testing the gen_tar
target and I figured that we only copy the resulting binaries to the final tar
file.
Per the kselftests documentation[1], the gen_tar target is used to package the
tests to run "on different systems". But what
On Fri, Oct 20, 2023 at 06:21:40AM +0200, Nicolas Schier wrote:
> On Thu, Oct 19, 2023 at 03:50:05PM -0300, Marcos Paulo de Souza wrote:
> > On Sat, Oct 14, 2023 at 05:35:55PM +0900, Masahiro Yamada wrote:
> > > On Tue, Oct 10, 2023 at 5:43 AM Marcos Paulo de S
vel_QA.rst
Signed-off-by: Marcos Paulo de Souza
---
Documentation/dev-tools/kselftest.rst | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/Documentation/dev-tools/kselftest.rst
b/Documentation/dev-tools/kselftest.rst
index deede972f254..ab376b316c36 100644
--- a/Documentation
63 matches
Mail list logo