Skip to content

ci: tiered toolchain/arch kernel build matrix (gcc+clang, x86_64+arm64) - #45

Merged
adeepn merged 5 commits into
tune_for_jethubfrom
ci/llvm-arm64-matrix
Aug 20, 2026
Merged

ci: tiered toolchain/arch kernel build matrix (gcc+clang, x86_64+arm64)#45
adeepn merged 5 commits into
tune_for_jethubfrom
ci/llvm-arm64-matrix

Conversation

@adeepn

@adeepn adeepn commented Aug 20, 2026

Copy link
Copy Markdown
Member

Tiered kernel matrix:

  • newest longterm, newest stable, fresh (non-rc) mainline, linux-next — full gcc/llvm × x86_64/arm64 square on native per-arch runners;
  • every other line — the single gcc/x86_64 cell as before.

WERROR explicit: on in gcc cells, off in llvm cells for now. arm64 configs force RFKILL=y (tristate RFKILL || !RFKILL = m capped CFG80211 to =m, dropping its exports from vmlinux.symvers). Runner OS labels pinned.

Known-red cells (pre-existing driver breakage, fixed separately): 6.12.101+ set_monitor_channel netdev param; linux-next remain_on_channel/mgmt_tx cookie by value.

adeepn added 4 commits August 20, 2026 10:28
runs-on: [self-hosted, X64] matches any X64 machine in the runner pool,
including the Windows ones, so jobs occasionally landed on a Windows
runner and failed. Pair self-hosted with the explicit OS label instead
(ubuntu-latest for linux x86_64; the pool convention is ubuntu-latest-arm
for linux arm64 and windows-latest for windows).
…/x86_64

Add a toolchain dimension (gcc, llvm) to the kernel matrix. gcc cells are
today's native x86_64 build, unchanged, including the CONFIG_WERROR=y
gate the x86_64 defconfig brings. llvm cells build the same kernels with
LLVM=1 for ARCH=arm64 — the arch the driver actually ships on (JetHub) —
which clang cross-compiles natively, so they double as the matrix's
first arm64 coverage.

Rationale: the recent fixes (#41-#44) all come from clang-only
diagnostic classes (-Wsometimes-uninitialized, -Wuninitialized,
-Wtautological-overlap-compare, -Warray-bounds with
-fstrict-flex-arrays=3) that the gcc-only CI cannot see, so nothing
currently guards them against regressions.

The arm64 defconfig does not set CONFIG_WERROR, deliberately kept that
way for now: clang warning classes stay informational in the summary
tally and only the kernel's default-fatal diagnostics fail the build.
Flip WERROR on in the llvm cells once the clang classes are at zero.

Each toolchain gets its own kernel tree (/tmp/linux-TAG vs -llvm): the
configs differ (CC_IS_CLANG, arm64) and a shared tree would rebuild from
scratch every time the toolchains alternate on a cached runner. This
doubles the matrix cell count and roughly doubles runner disk per tag.
The newest longterm, the newest stable release and linux-next build the
full toolchain/arch square — gcc/x86_64, gcc/arm64, llvm/x86_64,
llvm/arm64 — while every other maintained line keeps its single
gcc/x86_64 cell: its job is catching kernel API breakage, and one
toolchain covers that. A freshly released mainline (no -rc) also gets
the full square for the window before its first stable point release;
an -rc mainline stays in the short tier.

The -Werror gate is now set explicitly instead of relying on which arch
defconfig happens to carry CONFIG_WERROR: gcc cells gate (their warning
classes are at zero), llvm cells stay informational until the clang-only
classes reach zero too.

gcc/arm64 cells cross-compile with aarch64-linux-gnu-. Kernel trees are
cached per toolchain/arch combo; gcc/x86_64 keeps the historical
unsuffixed path so existing caches stay warm.
The arm64 defconfig has RFKILL=m. CFG80211's dependency
"RFKILL || !RFKILL" evaluates to m in tristate arithmetic, so
olddefconfig capped the requested CFG80211=y (and with it MAC80211)
back to =m, their exports never reached vmlinux.symvers, and modpost
failed every arm64 cell with "cfg80211_* undefined".

Reproduced locally: arm64 defconfig + scripts/config --enable CFG80211
+ olddefconfig -> CFG80211=m; with --enable RFKILL it stays =y.
@adeepn adeepn changed the title ci: clang/LLVM arm64 build cells for every matrix kernel + explicit runner OS label ci: tiered toolchain/arch kernel build matrix (gcc+clang, x86_64+arm64) Aug 20, 2026
The runner now comes from the matrix cell ([self-hosted, ubuntu-latest]
for x86_64, [self-hosted, ubuntu-latest-arm] for arm64), so every build
is native: the arm64 vmlinux load moves off the x86_64 runners and the
aarch64 cross toolchain is no longer needed — drop CROSS_COMPILE and the
gcc-aarch64-linux-gnu dependency.

ARCH stays explicit in the env: the driver's Makefile otherwise derives
it from 'uname -m', which yields "aarch64" where kbuild expects
"arm64".
@adeepn
adeepn merged commit 64c2d35 into tune_for_jethub Aug 20, 2026
17 of 22 checks passed
@adeepn
adeepn deleted the ci/llvm-arm64-matrix branch August 20, 2026 10:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant