From: Matthieu Baerts <matttbe@kernel.org>
To: Marcel Holtmann <marcel@holtmann.org>
Cc: ell@lists.linux.dev
Subject: ell: unit tests: sharing memory
Date: Mon, 10 Feb 2025 15:29:59 +0100 [thread overview]
Message-ID: <17dba9d9-6fce-41a6-a136-e47179c6a206@kernel.org> (raw)
Hi Marcel,
Thank you for maintaining and developing ELL!
After some recent changes on ELL side in the Git repository, it is no
longer possible to get mptcpd unit tests passing.
It looks like it is due to commit e0628c4 ("test: Run all test cases in
a forked process to catch exit signals") [1].
On mptcpd side, one series of tests [2] needs to have some shared data
between subtests, e.g. one subtest get an ID from the kernel, and other
subtests will use it later on. Such shared data are currently written in
the "user_data" passed to l_test_add(). There are also some counters in
global variables. Now that each test is executed in a dedicated forked
process, all of this no longer works. Is there a recommended way
specific to ELL to fix this? Or a way to avoid the fork?
I was thinking about using a shared memory with mmap(), but I don't know
well the unit test interface, maybe there is something dedicated to
that, or maybe the breakage was not supposed to happen?
[1] https://git.kernel.org/pub/scm/libs/ell/ell.git/commit/?id=e0628c4
[2] https://github.com/multipath-tcp/mptcpd/blob/main/tests/test-commands.c
Cheers,
Matt
--
Sponsored by the NGI0 Core fund.
reply other threads:[~2025-02-10 14:30 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=17dba9d9-6fce-41a6-a136-e47179c6a206@kernel.org \
--to=matttbe@kernel.org \
--cc=ell@lists.linux.dev \
--cc=marcel@holtmann.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.