diff options
| author | Sasha Levin <sashal@kernel.org> | 2026-10-25 21:21:28 -0400 |
|---|---|---|
| committer | Marc Zyngier <maz@kernel.org> | 2026-10-26 10:25:53 +0000 |
| commit | a4be8d69698b11d976c122be2d32bb72b8a52809 (patch) | |
| tree | 2bf85ad6fa9b229f164baecb9dea41ec23593186 /scripts/basic/split-include.c | |
| parent | 0fa4e506a054702d03d46aac9272a37f820fc2e5 (diff) | |
| download | linux-a4be8d69698b11d976c122be2d32bb72b8a52809.tar.gz linux-a4be8d69698b11d976c122be2d32bb72b8a52809.zip | |
KVM: arm64: selftests: Skip unwritable ID fields in the failed-run test
test_idreg_frozen_after_failed_run() checks that changing a feature ID
register after a failed first KVM_RUN is rejected with -EBUSY, and does
so for every field of every register in test_regs.
On a host without AArch32 support at EL0, KVM treats the AArch32 ID
registers as RAZ/WI: aa32_id_visibility() returns REG_RAZ | REG_USER_WI,
and kvm_sys_reg_set_user() ignores the write and returns 0 before
set_id_reg() checks whether the ID registers are final. The test then
fails on the first such register:
arm64/set_id_regs.c:870: r < 0 && errno == EBUSY
ID_DFR0_EL1_PerfMon write after failed first run: r=0 errno=16
KernelCI hits this on every run on an AArch64 only GB300 host.
Only a field that userspace can change can be frozen, and KVM reports
these registers as not writable in KVM_ARM_GET_REG_WRITABLE_MASKS. Skip
the fields that the writable mask does not cover. test_vm_ftr_id_regs()
already requires the mask to cover every other field in test_regs, so
this only drops the fields KVM never lets userspace change. Whether KVM
accepts writes to fields it reports as not writable is a separate
question from finalization.
Fixes: 00e309933879 ("KVM: arm64: selftests: Check ID regs are immutable after a failed run")
Link: https://d.kernelci.org/test/maestro:6adcad0c55fda50760800a00
Signed-off-by: Sasha Levin <sashal@kernel.org>
Reviewed-by: Fuad Tabba <fuad.tabba@linux.dev>
Tested-by: Fuad Tabba <fuad.tabba@linux.dev>
Link: https://patch.msgid.link/20261026012128.2270251-1-sashal@kernel.org
Signed-off-by: Marc Zyngier <maz@kernel.org>
Diffstat (limited to 'scripts/basic/split-include.c')
0 files changed, 0 insertions, 0 deletions
