On Mon, Jun 23, 2025 at 10:20 PM, Ross Burton wrote:
On 21 Jun 2025, at 08:31, Dixit Parmar via lists.openembedded.org <dixitparmar19=gmail.com@lists.openembedded.org> wrote:
Kernel module specific oe test cases requires a test kernel
module package to work with. Added selftest-hello-mod
derived from meta-skeleton/recipes-kernel/hello-mod.
Is there meant to be an actual test case to follow this up?
Yes, it's here https://lists.openembedded.org/g/openembedded-core/message/218013 - please review this too ;)
There’s already a kernel module in oeqa under meta/lib/oeqa/runtime/files/hellomod.c, I’ve previously tried adding more test cases around them (for SDKs not selftest though):

https://git.yoctoproject.org/poky-contrib/log/?h=ross/module

Maybe instead of duplicating the kernel module more we move the source and Makefile into meta/lib/oeqa/files/kmodule/ and then the tests can easily use them, and the recipe could set SRC_URI to ${COREBASE}/lib/oeqa/files/kmodule/hellomod.c.
I created a new recipe with the corresponding source files with the idea of having an independent self-test package for hello-mod. This is included in the meta-selftest so it can be used for other kernel module-related test cases in the future. I can modify it to point to the source and Makefile outside of the package if you recommend, though.
Cheers,
Ross