[PATCH v2 0/3] Move io-pgtable-arm selftest to KUnit

Jason Gunthorpe jgg at ziepe.ca
Wed Sep 17 12:27:19 PDT 2025


On Wed, Sep 17, 2025 at 07:11:37PM +0000, Mostafa Saleh wrote:
> --------
> - With CONFIG_IOMMU_IO_PGTABLE_LPAE_SELFTEST=y
>   It will automatically run at boot as before this patch series.

I would drop this kconfig, kunit does everything required including
run at boot if you want.

> - Otherwise with CONFIG_IOMMU_IO_PGTABLE_LPAE_SELFTEST=m:
>   1) on module load:
>      Once the module load the self test will run
>      # modprobe io-pgtable-arm-selftests
> 
>   2) debugfs
>      With CONFIG_KUNIT_DEBUGFS=y You can run the test with
>      # echo 1 > /sys/kernel/debug/kunit/io-pgtable-arm-test/run
> 
>   3) Using kunit.py
>      You can also use the helper script which uses Qemu in the background
> 
>      # ./tools/testing/kunit/kunit.py run --build_dir build_kunit_arm64 --arch arm64 \
>        --make_options LLVM=1 --kunitconfig ./kunit/kunitconfig
>       [18:01:09] ============= io-pgtable-arm-test (1 subtest) ==============
>       [18:01:09] [PASSED] arm_lpae_do_selftests
>       [18:01:09] =============== [PASSED] io-pgtable-arm-test ===============
>       [18:01:09] ============================================================

Suggest to include the above instruction in the commit message adding
the kunit so at least it is in the history

Jason



More information about the linux-arm-kernel mailing list