Re: [PATCH v3 3/3] KVM: arm64: selftests: Check ID regs are immutable after a failed run

From
Lorenzo Stoakes (ARM) <ljs@kernel.org>
Date
2026-09-29 09:57:38
Also in
kvmarm, lkml
Reply to
Fuad Tabba, 2026-09-28
On Mon, Sep 28, 2026 at 05:56:54PM +0100, Fuad Tabba wrote:
Hi Lorenzo,

On Mon, 28 Sep 2026 15:46:51 +0100, "Lorenzo Stoakes (ARM)"
[off-list ref] wrote:
quoted
On Tue, Sep 01, 2026 at 07:18:50PM +0100, Mark Brown wrote:
[...]
quoted
quoted
Assisted-by: Antigravity:gemini-3.1-pro
NIT: we changed the rules for the Assisted-by tag, it only needs to be
'Assisted-by: LLM' now. Not a huge big deal but FYI :>)

https://docs.kernel.org/process/coding-assistants.html
That tag dates from way back when the format was still
AGENT_NAME:MODEL_VERSION :)
Ack yeah it's not a big deal :)
[...]
quoted
quoted
diff --git a/tools/testing/selftests/kvm/arm64/set_id_regs.c b/tools/testing/selftests/kvm/arm64/set_id_regs.c
[...]
quoted
quoted
+static void test_idreg_frozen_after_failed_run(void)
[...]
quoted
quoted
+        /* Creating an in-kernel irqchip would change the ID registers too. */
+        if (kvm_supports_vgic_v3()) {
+                r = __kvm_create_device(vm, KVM_DEV_TYPE_ARM_VGIC_V3);
+                TEST_ASSERT(r < 0 && errno == EBUSY,
+                            "vGIC creation after failed first run: r=%d errno=%d",
+                            r, errno);
I guess in general it's making sure - where there should now be finalisation on
reg setting that this is actually enforced?
Yes. The test exercises each of the userspace-facing checks that 2/3
moves to KVM_ARCH_FLAG_ID_REGS_FINAL: set_id_reg(), set_imp_id_reg()
and kvm_vgic_create().
Great thanks! :)
Thanks,
/fuad
--
Cheers, Lorenzo
Thread (13 messages) 13 messages, 3 authors, last reply 2026-09-29
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help