On Mon, Jul 06, 2026 at 02:06:42PM +0200, Albert Esteve wrote:
> Currently, test_dmem relies on the dmem_selftest helper module
> and a VM setup that may not have the helper preinstalled.
> This makes automated coverage of dmem charge paths harder in
> virtme-based runs.
> 
> Add tools/testing/selftests/cgroup/vmtest-dmem.sh to provide a
> repeatable VM workflow for dmem tests. The script uses vng --exec
> to run the test directly inside a virtme-ng guest with minimal
> setup.
> 
> The script boots a virtme-ng guest, validates dmem controller
> availability, ensures the dmem helper path is present, and runs
> tools/testing/selftests/cgroup/test_dmem. If the helper is not
> available as a loaded module, it attempts module build/load for
> the running guest kernel before executing the test binary.
> 
> The runner also supports interactive shell mode (-s) and reuses
> the verbosity and KTAP exit-code conventions used by other vmtest
> scripts, so it integrates with existing kselftest workflows.
> 
> vmtest-dmem.sh is placed in TEST_FILES rather than TEST_PROGS so
> it is installed alongside the test suite but not invoked
> automatically by run_kselftest.sh. It requires a VM-capable host
> and is intended to be run manually.
> 
> Signed-off-by: Albert Esteve <[email protected]>

Reviewed-by: Eric Chanudet <[email protected]>

-- 
Eric Chanudet


Reply via email to