On 8/6/2026 9:15 AM, Sohil Mehta wrote: > Add a LASS selftest for KVM's handling of CPUID advertisement and > CR4.LASS. Verify that a guest write to CR4.LASS generates #GP, and > leaves CR4 unchanged, when LASS isn't enumerated in the guest's CPUID. > > Extend set_sregs_test to cover CR4.LASS and verify that KVM_SET_SREGS > accepts CR4.LASS when LASS is supported, and rejects it, without > modifying sregs, when it isn't. > > Don't try running with CR4.LASS enabled in the guest or attempt to > trigger LASS violations. Selftests run guest code in the lower half of > the address space at CPL0, so enabling CR4.LASS would make the next > instruction fetch a violation and triple-fault the guest. > > Assisted-by: Claude:claude-opus-5 > Signed-off-by: Sohil Mehta <[email protected]>
Reviewed-by: Binbin Wu <[email protected]>

