Skip to content

boards/risc-v: add NTFC test for ksmp64 - #20127

Open
imeghar2408-max wants to merge 1 commit into
apache:masterfrom
imeghar2408-max:fix/qemu-rv-kernel-ntfc
Open

boards/risc-v: add NTFC test for ksmp64#20127
imeghar2408-max wants to merge 1 commit into
apache:masterfrom
imeghar2408-max:fix/qemu-rv-kernel-ntfc

Conversation

@imeghar2408-max

@imeghar2408-max imeghar2408-max commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

Assisted-by: GitHub Copilot

Summary

Add NTFC (NuttX Test Framework Configuration) support for the existing RISC-V ksmp64 kernel SMP configuration (rv-virt:ksmp64).

This enables automated CI test coverage for the SMP kernel build, exercising ostest and SMP-specific test cases across 4 harts under QEMU.

Testing

Build

$ ./tools/configure.sh rv-virt:ksmp64
$ make -j$(nproc)

Verified key configuration options:

CONFIG_BUILD_KERNEL=y
CONFIG_ARCH_USE_S_MODE=y
CONFIG_SMP=y
CONFIG_SMP_NCPUS=4
CONFIG_SYSTEM_NSH=y
CONFIG_TESTING_OSTEST=y
CONFIG_TESTING_SMP=y

Kernel application build/import

$ make export -j$(nproc)
$ cd ../apps
$ ./tools/mkimport.sh -z -x ../nuttx/nuttx-export-*.tar.gz
$ make import -j$(nproc)

QEMU SMP boot

$ qemu-system-riscv64 -semihosting -M virt,aclint=on -cpu rv64 -smp 4 -kernel ./nuttx -nographic

Boots cleanly to NSH with all 4 harts recognized by OpenSBI.

NTFC test run

$ NTFCDIR=/tmp/nuttx-ntfc ./tools/testbuild.sh -C -R /tmp/nuttx-ksmp64-testlist

933 tests collected, 3 skipped, exit code 0 — no failures.

Static checks

$ git diff --check
$ ./tools/checkpatch.sh -c -u -m -g "$BASE..HEAD"
$ ./tools/checkpatch.sh -c

All checks pass.

Fixes #20031

Add NTFC configuration for the ksmp64 kernel SMP build so it can
be exercised by the CI test infrastructure.

Assisted-by: GitHub Copilot
Signed-off-by: Megha Rajput <i.meghar.2408@gmail.com>
@github-actions github-actions Bot added Size: S The size of the change in this PR is small Board: risc-v labels Sep 13, 2026
@github-actions

Copy link
Copy Markdown

MemBrowse Memory Report

No memory changes detected for:

@imeghar2408-max

Copy link
Copy Markdown
Contributor Author

CI is currently failing during the NTFC boot wait for the ksmp64 test. The kernel builds successfully and boots locally with 4 HARTs, but CI uses ntfc==0.0.1, whose boot wait appears to be limited to ~5s. Newer NTFC changes add configurable boot_timeout and exec_cwd.

What would be the preferred approach here — update/release NTFC first and then use those options in this PR, or handle it another way?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Board: risc-v Size: S The size of the change in this PR is small

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Add kernel build tests for CI

2 participants