t; >
> > The "port_specific" fixture is extended with 4 variants defined
> > as a matrix of: sandboxed/not-sandboxed, IPv4/IPv6 network domain,
> > and stream socket. 2 related tests suites are defined:
> > * bind_connect_zero: Tests with port 0 value.
> >
On Wed, Jan 10, 2024 at 03:08:54PM +0800, Hu Yadi wrote:
> From: "Hu.Yadi"
>
> Two issues comes up while building selftest/landlock:
>
> the first one is as to gettid
>
> net_test.c: In function ‘set_service’:
> net_test.c:91:45: warning: implicit declaration of function ‘gettid’; did you
> m
On Wed, Jan 10, 2024 at 03:29:01PM +0800, Hu Yadi wrote:
> From: "Hu.Yadi"
>
> Replace SYS_ with __NR_. Using the __NR_
> notation, provided by UAPI, is useful to build tests on systems without
> the SYS_ definitions.
This looks a lot like that...
https://git.kernel.org/stable/c/87129ef13603ae4
could fix both
changes.
You can append this to the commit message (with the v2 description):
Similar changes: commit 87129ef13603 ("selftests/landlock: Make tests
build with old libc")
Acked-by: Mickaël Salaün
>
> >>
> >> Replace SYS_move_mount with __NR_move_mount
&
nt
>
> Similar changes: commit 87129ef13603 ("selftests/landlock: Make tests build
> with old libc")
>
> Acked-by: Mickaël Salaün
Sorry, it should have been Reviewed-by: Mickaël Salaün
Also, this is maintained by the VFS maintainers. I CCed three relevant
ad
On Thu, Jan 11, 2024 at 02:34:08AM +, Huyadi wrote:
>
> ->On Wed, Jan 10, 2024 at 03:08:54PM +0800, Hu Yadi wrote:
> >> From: "Hu.Yadi"
> >>
> >> Two issues comes up while building selftest/landlock:
> >>
> >> the first one is as to gettid
> >>
> >> net_test.c: In function ‘set_service’:
/20/23 2:17 PM, Mickaël Salaün wrote:
> > Hi Muhammad,
> >
> > Thanks for the report.
> >
> > On Tue, Dec 19, 2023 at 03:38:55PM +0500, Muhammad Usama Anjum wrote:
> >> Hi Konstantin,
> >>
> >> There are some errors being report
On Fri, Jan 12, 2024 at 03:12:45PM +0800, Hu Yadi wrote:
> From: "Hu.Yadi"
>
> Two issues comes up while building selftest/landlock on my side
> (gcc 7.3/glibc-2.28/kernel-4.19)
>
> the first one is as to gettid
>
> net_test.c: In function ‘set_service’:
> net_test.c:91:45: warning: implicit de
00:00]
[00:00:00] Testing complete. Ran 7 tests: passed: 7
Cc: Günther Noack
Cc: Konstantin Meskhidze
Signed-off-by: Mickaël Salaün
---
security/landlock/.kunitconfig | 4 +
security/landlock/Kconfig| 15 ++
security/landlock/com
As for the Qemu command, print the command used to run tests with UML.
Cc: Brendan Higgins
Cc: David Gow
Signed-off-by: Mickaël Salaün
---
tools/testing/kunit/kunit_kernel.py | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/testing/kunit/kunit_kernel.py
b/tools/testing/kunit
On Mon, Jan 15, 2024 at 06:24:09PM +0800, Hu Yadi wrote:
> From: "Hu.Yadi"
>
> Two issues comes up while building selftest/landlock on my side
> (gcc 7.3/glibc-2.28/kernel-4.19)
>
> the first one is as to gettid
>
> net_test.c: In function ‘set_service’:
> net_test.c:91:45: warning: implicit de
On Fri, Jan 19, 2024 at 01:25:06PM +0100, Günther Noack wrote:
> Thank you, this is really nice!
>
> Only tiny style nitpicks here.
>
> Reviewed-by: G�nther Noack
>
> On Thu, Jan 18, 2024 at 12:36:32PM +0100, Micka�l Sala�n wrote:
> > Add the SECURITY_LANDLOCK_KUNIT_TEST option to enable
Thanks, I tweaked a bit and merged this patch in my next branch.
On Tue, Jan 23, 2024 at 02:26:21PM +0800, Hu Yadi wrote:
> From: "Hu.Yadi"
There is an extra "." here, I fixed it. You don't need to add this From
field if it matches your email's From one.
>
> Fixes: a549d055a22e ("selftests/lan
On Tue, Jan 23, 2024 at 12:04:17PM +, Huyadi wrote:
>
> >> Changes v3 -> v2:
> >> - add helper of gettid instead of __NR_gettid
> >> - add gcc/glibc version info in comments Changes v1 -> v2:
> >> - fix whitespace error
> >> - replace SYS_gettid with _NR_gettid
> >>
> >> tools/testing/se
Thanks, it's merged with some fixes:
https://git.kernel.org/mic/c/82852a3cc2152eb7c7b7007b6430faa979b08fad
On Wed, Jan 24, 2024 at 10:29:08AM +0800, Hu Yadi wrote:
> From: "Hu.Yadi"
You might want to fix the extra dot in your name.
>
> Fixes: 04f9070e99a4 ("selftests/landlock: Add tests for ps
It doesn't help to call TH_LOG() for every cap_*() error. Let's only
log errors returned by the kernel, not by libcap specificities.
Signed-off-by: Mickaël Salaün
---
tools/testing/selftests/landlock/common.h | 39 ++-
1 file changed, 9 insertions(+), 30 deletion
et_ambient_cap() and
clear_ambient_cap() helpers.
This makes it possible to run all Landlock tests (including net_test)
with uml-run.sh from https://github.com/landlock-lsm/landlock-test-tools
Cc: Konstantin Meskhidze
Fixes: a549d055a22e ("selftests/landlock: Add network tests")
Hi,
This two patches fix an issue when the user running net_test is not
root. The second patch simplify test error logs.
Regards,
Mickaël Salaün (2):
selftests/landlock: Fix capability for net_test
selftests/landlock: Clean up error logs related to capabilities
tools/testing/selftests
Hi,
This is a long due cleanup to merge TEST_F_FORK() into TEST_F().
This should simplify Jakub's patches by removing the step counter:
https://lore.kernel.org/r/20240220192235.2953484-1-k...@kernel.org
Regards,
Mickaël Salaün (2):
selftests/landlock: Redefine TEST_F() as TEST_F
On Fri, Feb 23, 2024 at 04:02:59PM -0800, Jakub Kicinski wrote:
> On Tue, 20 Feb 2024 11:22:24 -0800 Jakub Kicinski wrote:
> > When running selftests for our subsystem in our CI we'd like all
> > tests to pass. Currently some tests use SKIP for cases they
> > expect to fail, because the kselftest_h
rewry
Signed-off-by: Mickaël Salaün
---
tools/testing/selftests/landlock/common.h | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/tools/testing/selftests/landlock/common.h
b/tools/testing/selftests/landlock/common.h
index 425c5698aea2..0bc15d36971a 100644
--- a/tools/te
_harness.h to print which assert failed").
Replace spaces with tabs in one line of __TEST_F_IMPL().
Cc: Günther Noack
Cc: Jakub Kicinski
Cc: Kees Cook
Cc: Shuah Khan
Cc: Will Drewry
Signed-off-by: Mickaël Salaün
---
tools/testing/selftests/kselftest_harness.h | 56 +-
On Mon, Feb 26, 2024 at 11:04:12AM -0800, Kees Cook wrote:
> On Mon, Feb 26, 2024 at 05:23:35PM +0100, Mickaël Salaün wrote:
> > Remplace Landlock-specific TEST_F_FORK() with an improved TEST_F() which
> > brings four related changes:
> >
> > Run TEST_F()'s tests
t help would be much appreciated!
On Wed, Feb 28, 2024 at 04:59:09PM -0800, Jakub Kicinski wrote:
> From: Mickaël Salaün
>
> Replace Landlock-specific TEST_F_FORK() with an improved TEST_F() which
> brings four related changes:
>
> Run TEST_F()'s tests in a grandchild
On Mon, Mar 04, 2024 at 08:27:50PM +0100, Mickaël Salaün wrote:
> Testing the whole series, I found that some Landlock tests are flaky
> starting with this patch. I tried to not use the longjmp in the
> grandchild but it didn't change. I suspect missing volatiles but I
> didn&
r(variant->file_path, '/');
ASSERT_NE(slash, NULL);
dir_len = (size_t)slash - (size_t)variant->file_path;
On Mon, Mar 04, 2024 at 08:31:49PM +0100, Mickaël Salaün wrote:
> On Mon, Mar 04, 2024 at 08:27:50PM +0100, Mickaël Salaün wrote:
> > Testing the whole se
rint which assert failed").
Replace spaces with tabs in one line of __TEST_F_IMPL().
Cc: Günther Noack
Cc: Shuah Khan
Cc: Will Drewry
Cc: Kees Cook
Cc: Jakub Kicinski
Signed-off-by: Mickaël Salaün
---
v5:
- Fix TEST_SIGNAL() by forwarding grandchild signal to parent.
- By default,
er and simplify Landlock's test
teardowns by removing some umount calls.
See https://lore.kernel.org/r/20240229005920.2407409-1-k...@kernel.org
Regards,
Mickaël Salaün (2):
selftests/landlock: Redefine TEST_F() as TEST_F_FORK()
selftests/harness: Merge TEST_F_FORK() into TEST_F()
too
inski
Signed-off-by: Mickaël Salaün
---
tools/testing/selftests/landlock/common.h | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/tools/testing/selftests/landlock/common.h
b/tools/testing/selftests/landlock/common.h
index e64bbdf0e86e..f40146d40763 100644
--- a/tools/te
On Tue, Mar 05, 2024 at 01:43:14AM -0800, Kees Cook wrote:
> On Mon, Mar 04, 2024 at 03:39:02PM -0800, Jakub Kicinski wrote:
> > On Mon, 4 Mar 2024 15:14:04 -0800 Kees Cook wrote:
> > > > Ugh, I'm guessing vfork() "eats" the signal, IOW grandchild signals,
> > > > child exits? vfork() and signals..
On Tue, Mar 05, 2024 at 04:48:06PM +0100, Przemek Kitszel wrote:
> On 3/5/24 00:04, Jakub Kicinski wrote:
> > On Mon, 4 Mar 2024 22:20:03 + Mark Brown wrote:
> > > On Wed, Feb 28, 2024 at 04:59:07PM -0800, Jakub Kicinski wrote:
> > >
> > > > When running selftests for our subsystem in our CI w
On Tue, Mar 05, 2024 at 05:00:13PM +0100, Mickaël Salaün wrote:
> On Tue, Mar 05, 2024 at 04:48:06PM +0100, Przemek Kitszel wrote:
> > On 3/5/24 00:04, Jakub Kicinski wrote:
> > > On Mon, 4 Mar 2024 22:20:03 + Mark Brown wrote:
> > > > On Wed, Feb 28, 2024 at 04
On Tue, Mar 05, 2024 at 10:06:39AM -0800, Jakub Kicinski wrote:
> On Tue, 5 Mar 2024 17:05:51 +0100 Mickaël Salaün wrote:
> > > I think we have to -- other CIs are now showing the most of seccomp
> > > failing now. (And I can confirm this now -- I had only tested seccomp
>
Always run fixture setup in the grandchild process, and by default also
run the teardown in the same process. However, this change makes it
possible to run the teardown in a parent process when
_metadata->teardown_parent is set to true (e.g. in fixture setup).
Fix TEST_SIGNAL() by forwarding gran
On Tue, Mar 05, 2024 at 12:25:54PM -0800, Jakub Kicinski wrote:
> On Tue, 5 Mar 2024 21:10:29 +0100 Mickaël Salaün wrote:
> > Always run fixture setup in the grandchild process, and by default also
> > run the teardown in the same process. However, this change makes it
> >
On Wed, Mar 06, 2024 at 08:25:45AM +0100, Mickaël Salaün wrote:
> On Tue, Mar 05, 2024 at 12:25:54PM -0800, Jakub Kicinski wrote:
> > On Tue, 5 Mar 2024 21:10:29 +0100 Mickaël Salaün wrote:
> > > Always run fixture setup in the grandchild process, and by default also
> > &
On Tue, Apr 02, 2024 at 01:37:44PM +0530, Saasha Gupta wrote:
> Date: Mon, 2 Apr 2024 19:59:56 +0530
>
> RE: This patch is now properly preformatted.
>
> Landlock LSM, a part of the security subsystem, has some tests in place
> for synthetic filesystems such as tmpfs, proc, sysfs, etc. The goal o
org/r/20240229170409.365386-1-...@digikod.net
Regards,
Mickaël Salaün (7):
kunit: Handle thread creation error
kunit: Fix kthread reference
kunit: Fix timeout message
kunit: Handle test faults
kunit: Fix KUNIT_SUCCESS() calls in iov_iter tests
kunit: Print last test location on fault
kunit
eviewed-by: David Gow
Reviewed-by: Rae Moar
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240408074625.65017-3-...@digikod.net
---
Changes since v2:
* Add Fixes tag as suggested by David.
* Add David's and Rae's Reviewed-by.
Changes since v1:
* Add Kees's Review
ernal error occurred...".
Cc: Brendan Higgins
Cc: Shuah Khan
Reviewed-by: Kees Cook
Reviewed-by: Rae Moar
Reviewed-by: David Gow
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240408074625.65017-2-...@digikod.net
---
Changes since v2:
* Add Rae's and David's R
The exit code is always checked, so let's properly handle the -ETIMEDOUT
error code.
Cc: Brendan Higgins
Cc: Shuah Khan
Reviewed-by: Kees Cook
Reviewed-by: David Gow
Reviewed-by: Rae Moar
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240408074625.65017-4-...@digiko
Fix KUNIT_SUCCESS() calls to pass a test argument.
This is a no-op for now because this macro does nothing, but it will be
required for the next commit.
Cc: Brendan Higgins
Cc: Rae Moar
Cc: Shuah Khan
Reviewed-by: Kees Cook
Reviewed-by: David Gow
Signed-off-by: Mickaël Salaün
Link: https
by: David Gow
Tested-by: Rae Moar
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240408074625.65017-5-...@digikod.net
---
Changes since v3:
* Export kthread_exit() for KUnit tests built as module, as suggested by
David.
Changes since v2:
* s/-EFAULT/-EINTR/ in commit message as s
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240408074625.65017-7-...@digikod.net
---
Changes since v3:
* Improve the try-fault error message as suggested by David.
Changes since v2:
* Extend the commit message according to discussion with David.
Changes
/testing/kunit/kunit.py run --arch arm64 \
--cross_compile=aarch64-linux-gnu- kunit_fault
Cc: Brendan Higgins
Cc: Rae Moar
Cc: Shuah Khan
Reviewed-by: David Gow
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240408074625.65017-8-...@digikod.net
---
Changes since v2:
* Add
4db-5e21-418c-bf9e-9ae2da787...@sirena.org.uk
Fixes: a86f18903db9 ("selftests/harness: Fix interleaved scheduling leading to
race conditions")
Fixes: 24cf65a62266 ("selftests/harness: Share _metadata between forked
processes")
Signed-off-by: Mickaël Salaün
Link: https://lore.kern
I pushed it to my next branch.
Mark, Shuah, and others, please let me know if kselftest and KernelCI
are better with that.
On Fri, Jun 21, 2024 at 08:06:05PM +0200, Mickaël Salaün wrote:
> We cannot use CLONE_VFORK because we also need to wait for the timeout
> signal.
>
> Restore t
:03
+0200)
Fix Kselftests timeout and race condition
--------
Mickaël Salaün (1):
selftests/harness: Fix tests timeout and race condition
tools/testing/selftests/kselftest_harn
imply adapt those
> conditions, and add a dependency on !UML for our new option.
>
> Suggested-by: Guenter Roeck
> Link:
> https://lore.kernel.org/all/928249cc-e027-4f7f-b43f-502f99a1e...@roeck-us.net/
> Fixes: 82b0beff3497 ("kunit: Add tests for fault")
> Signed-off-by: David
FYI, I'm working on this issue.
Regards,
Mickaël
On Fri, Mar 29, 2024 at 10:42:51AM +0800, kernel test robot wrote:
>
>
> Hello,
>
> kernel test robot noticed "kernel-selftests.pidfd.pidfd_setns_test.fail" on:
>
> commit: 0710a1a73fb45033ebb06073e374ab7d44a05f15 ("selftests/harness: Merge
>
rent Linux distributions,
with different mount point configurations.
Cc: Günther Noack
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240426172252.1862930-3-...@digikod.net
---
tools/testing/se
: Mark Brown
Cc: Shuah Khan
Cc: Will Drewry
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240426172252.1862930-5-...@digikod.net
---
tools/testing/selftests/kselftest_harness.h | 15
/harness: Prevent infinite loop due to Assert in
FIXTURE_TEARDOWN")
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240426172252.1862930-4-...@digikod.net
---
tools/testing/selftests/k
tests")
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240426172252.1862930-2-...@digikod.net
---
tools/testing/selftests/pidfd/config | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tools/testing/selftests/pidfd/config
b/tools/testing/selftests/pidfd/config
index f6
b4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240426172252.1862930-6-...@digikod.net
---
tools/testing/selftests/kselftest_harness.h | 88 +--
tools/testing/selftests/landlock/fs_test.c|
_test
- pidfd:pidfd_setns_test
- seccomp:seccomp_bpf
- user_events:abi_test
[1] https://lore.kernel.org/oe-lkp/202403291015.1fcfa957-oliver.s...@intel.com
Regards,
Mickaël Salaün (5):
selftests/pidfd: Fix config for pidfd_setns_test
selftests/landlock: Fix FS tests when run on a private mount point
self
On Fri, Apr 26, 2024 at 12:47:16PM -0700, Kees Cook wrote:
> On Fri, Apr 26, 2024 at 07:22:52PM +0200, Mickaël Salaün wrote:
> > Setting the time namespace with CLONE_NEWTIME returns -EUSERS if the
> > calling thread shares memory with another thread (because of the shared
> >
On Fri, Apr 26, 2024 at 12:38:17PM -0700, Kees Cook wrote:
> On Fri, Apr 26, 2024 at 07:22:49PM +0200, Mickaël Salaün wrote:
> > According to the test environment, the mount point of the test's working
> > directory may be shared or not, which changes the visibility of the
&g
pidfd
- perf_events:remove_on_exec
- pidfd:pidfd_getfd_test
- pidfd:pidfd_setns_test
- seccomp:seccomp_bpf
- user_events:abi_test
[1] https://lore.kernel.org/oe-lkp/202403291015.1fcfa957-oliver.s...@intel.com
Previous version:
v1: https://lore.kernel.org/r/20240426172252.1862930-1-...@digikod.net
Regards,
Mi
rs [1], where mount
points are private.
Cc: Günther Noack
Cc: Shuah Khan
Link: https://github.com/landlock-lsm/landlock-test-tools/pull/4 [1]
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https
90b ("selftests/harness: Prevent infinite loop due to Assert in
FIXTURE_TEARDOWN")
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429130931.2394118-4-...
_metadata to extend expectations to test process's
forks. For instance, this change identified a wrong expectation in
pidfd_setns_test.
Cc: Jakub Kicinski
Cc: Kees Cook
Cc: Shuah Khan
Cc: Will Drewry
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429130931.2394
her Noack
Cc: Kees Cook
Cc: Shuah Khan
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429130931.2394118-6-...@digikod.net
---
Changes since v1:
* Extract change from a bigger patch (suggested by Kees).
---
tools/testing/selftests/landlock/fs_test.c | 57 +-
Replace a wrong EXPECT_GT(self->child_pid_exited, 0) with EXPECT_GE(),
which will be actually tested on the parent and child sides with a
following commit.
Cc: Christian Brauner
Cc: Kees Cook
Cc: Shuah Khan
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429130931.239411
: Mark Brown
Cc: Shuah Khan
Cc: Will Drewry
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429130931.2394118-5-...@digikod.net
---
tools/testing/selftests/kselftest_harness.h | 15
FIXTURE_VARIANT_ADD() types are passed as const pointers to
FIXTURE_TEARDOWN(). Make that explicit by constifying the variants
declarations.
Cc: Kees Cook
Cc: Shuah Khan
Cc: Will Drewry
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429130931.2394118-7-...@digikod.net
Cc: Kees Cook
Cc: Mark Brown
Cc: Shuah Khan
Cc: Will Drewry
Reported-by: kernel test robot
Closes:
https://lore.kernel.org/oe-lkp/202403291015.1fcfa957-oliver.s...@intel.com
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Signed-off-by: Mick
tests")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429130931.2394118-2-...@digikod.net
---
tools/testing/selftests/pidfd/config | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tools/testing/selftests/pidfd/config
b/tools/testing/selftests/pi
On Mon, Apr 29, 2024 at 10:16:47AM -0700, Jakub Kicinski wrote:
> On Mon, 29 Apr 2024 08:52:36 -0700 Kees Cook wrote:
> > > +/* Wait for the child process to end but without sharing memory mapping.
> > > */
> > > +static pid_t __attribute__((__unused__)) clone3_vfork(void)
> >
> > Why "unused"?
930-1-...@digikod.net
v2: https://lore.kernel.org/r/20240429130931.2394118-1-...@digikod.net
Regards,
Mickaël Salaün (9):
selftests/pidfd: Fix config for pidfd_setns_test
selftests/landlock: Fix FS tests when run on a private mount point
selftests/harness: Fix fixture teardown
selftests/harness
: Shuah Khan
Cc: Will Drewry
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429191911.2552580-5-...@digikod.net
---
Changes since v2:
* Replace __attribute__((__unused_
tests")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429191911.2552580-2-...@digikod.net
---
tools/testing/selftests/pidfd/config | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tools/testing/selftests/pidfd/config
b/tools/testing/selftests/pi
FIXTURE_VARIANT_ADD() types are passed as const pointers to
FIXTURE_TEARDOWN(). Make that explicit by constifying the variants
declarations.
Cc: Shuah Khan
Cc: Will Drewry
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429191911.2552580-7
Replace a wrong EXPECT_GT(self->child_pid_exited, 0) with EXPECT_GE(),
which will be actually tested on the parent and child sides with a
following commit.
Cc: Christian Brauner
Cc: Shuah Khan
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.or
_metadata to extend expectations to test process's
forks. For instance, this change identified a wrong expectation in
pidfd_setns_test.
Cc: Jakub Kicinski
Cc: Shuah Khan
Cc: Will Drewry
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429191911.2552
90b ("selftests/harness: Prevent infinite loop due to Assert in
FIXTURE_TEARDOWN")
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429191911.2552580-4-...
c: Mark Brown
Cc: Shuah Khan
Cc: Will Drewry
Reported-by: kernel test robot
Closes:
https://lore.kernel.org/oe-lkp/202403291015.1fcfa957-oliver.s...@intel.com
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Reviewed-by: Kees Cook
Signed-off-by: Mick
her Noack
Cc: Shuah Khan
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240429191911.2552580-6-...@digikod.net
---
Changes since v1:
* Extract change from a bigger patch (suggested by Kees).
---
tools/testing/selftests/landlock/fs_test.c |
rs [1], where mount
points are private.
Cc: Günther Noack
Cc: Shuah Khan
Link: https://github.com/landlock-lsm/landlock-test-tools/pull/4 [1]
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https
, 2024 at 09:19:02PM +0200, Mickaël Salaün wrote:
> Hi,
>
> As reported by Kernel Test Robot [1], some pidfd tests fail. This is
> due to the use of vfork() which introduced some side effects.
> Similarly, while making it more generic, a previous commit made some
> Landlock file
On Tue, Apr 30, 2024 at 08:13:04AM -0700, Jakub Kicinski wrote:
> On Tue, 30 Apr 2024 15:54:38 +0200 Mickaël Salaün wrote:
> > Jakub, can you please review it?
>
> I looked thru it. I don't have the cycles to investigate and suggest
> a better approach but the sprinkling
On Thu, May 02, 2024 at 11:42:29AM GMT, Sean Christopherson wrote:
> +kvm
>
> On Tue, Mar 05, 2024, Mickaël Salaün wrote:
> > On Tue, Mar 05, 2024 at 01:43:14AM -0800, Kees Cook wrote:
> > > On Mon, Mar 04, 2024 at 03:39:02PM -0800, Jakub Kicinski wrote:
> > > &g
930-1-...@digikod.net
v2: https://lore.kernel.org/r/20240429130931.2394118-1-...@digikod.net
v3: https://lore.kernel.org/r/20240429191911.2552580-1-...@digikod.net
Regards,
Mickaël Salaün (10):
selftests/pidfd: Fix config for pidfd_setns_test
selftests/landlock: Fix FS tests when run on a private mount
: Shuah Khan
Cc: Will Drewry
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240502210926.145539-5-...@digikod.net
---
Changes since v2:
* Replace __attribute__((__unused_
rs [1], where mount
points are private.
Cc: Günther Noack
Cc: Shuah Khan
Link: https://github.com/landlock-lsm/landlock-test-tools/pull/4 [1]
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: http
90b ("selftests/harness: Prevent infinite loop due to Assert in
FIXTURE_TEARDOWN")
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240502210926.145539-4-...@digikod
FIXTURE_VARIANT_ADD() types are passed as const pointers to
FIXTURE_TEARDOWN(). Make that explicit by constifying the variants
declarations.
Cc: Shuah Khan
Cc: Will Drewry
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240502210926.145539-7
Replace a wrong EXPECT_GT(self->child_pid_exited, 0) with EXPECT_GE(),
which will be actually tested on the parent and child sides with a
following commit.
Cc: Shuah Khan
Reviewed-by: Kees Cook
Reviewed-by: Christian Brauner
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.or
her Noack
Cc: Shuah Khan
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240502210926.145539-6-...@digikod.net
---
Changes since v1:
* Extract change from a bigger patch (suggested by Kees).
---
tools/testing/selftests/landlock/fs_test.c |
_metadata to extend expectations to test process's
forks. For instance, this change identified a wrong expectation in
pidfd_setns_test.
Cc: Jakub Kicinski
Cc: Shuah Khan
Cc: Will Drewry
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240502210926.145
c: Mark Brown
Cc: Shuah Khan
Cc: Will Drewry
Reported-by: kernel test robot
Closes:
https://lore.kernel.org/oe-lkp/202403291015.1fcfa957-oliver.s...@intel.com
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Reviewed-by: Kees Cook
Signed-off-by: Mick
abtyv...@google.com [1]
Fixes: 0710a1a73fb4 ("selftests/harness: Merge TEST_F_FORK() into TEST_F()")
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240502210926.145539-11-...@digikod.net
---
Changes since v3:
* New patch mainly from Sean Christopherson.
---
tools/te
Kees Cook
Reviewed-by: Christian Brauner
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240502210926.145539-2-...@digikod.net
---
tools/testing/selftests/pidfd/config | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tools/testing/selftests/pidfd/config
b/tools/testing/selft
On Thu, May 02, 2024 at 03:45:22PM GMT, Sean Christopherson wrote:
> On Thu, May 02, 2024, Mickaël Salaün wrote:
> > @@ -462,8 +462,10 @@ static inline pid_t clone3_vfork(void)
> > munmap(teardown, sizeof(*teardown)); \
> > if (self && f
580-1-...@digikod.net
v4: https://lore.kernel.org/r/20240502210926.145539-1-...@digikod.net
Regards,
Mickaël Salaün (10):
selftests/pidfd: Fix config for pidfd_setns_test
selftests/landlock: Fix FS tests when run on a private mount point
selftests/harness: Fix fixture teardown
selftests/harness
: Shuah Khan
Cc: Will Drewry
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240503105820.300927-5-...@digikod.net
---
Changes since v2:
* Replace __attribute__((__unused_
her Noack
Cc: Shuah Khan
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240503105820.300927-6-...@digikod.net
---
Changes since v1:
* Extract change from a bigger patch (suggested by Kees).
---
tools/testing/selftests/landlock/fs_test.c |
Kees Cook
Reviewed-by: Christian Brauner
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240503105820.300927-2-...@digikod.net
---
tools/testing/selftests/pidfd/config | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tools/testing/selftests/pidfd/config
b/tools/testing/selft
FIXTURE_VARIANT_ADD() types are passed as const pointers to
FIXTURE_TEARDOWN(). Make that explicit by constifying the variants
declarations.
Cc: Shuah Khan
Cc: Will Drewry
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: https://lore.kernel.org/r/20240503105820.300927-7
rs [1], where mount
points are private.
Cc: Günther Noack
Cc: Shuah Khan
Link: https://github.com/landlock-lsm/landlock-test-tools/pull/4 [1]
Fixes: 41cca0542d7c ("selftests/harness: Fix TEST_F()'s vfork handling")
Reviewed-by: Kees Cook
Signed-off-by: Mickaël Salaün
Link: http
1 - 100 of 133 matches
Mail list logo