On 8/6/2026 9:15 AM, Sohil Mehta wrote:
> From: Zeng Guang <[email protected]>
> 
> Add a VMX implementation of the is_lass_violation() hook to let KVM
> detect Linear Address Space Separation (LASS) violations on linear
> addresses generated during emulation. LASS uses bit 63 of the linear
> address to determine which half of the address space is being targeted,
> and reports a violation when that half doesn't match the current
> privilege level.
> 
> Note, LASS takes effect only in IA-32e mode; it is ignored in legacy
> mode. LASS enforcement for supervisor-mode data accesses additionally
> requires SMAP to be enabled, and is suppressed for explicit accesses
> when RFLAGS.AC=1.
> 
> Enforce LASS violations on emulated instruction fetches and data
> accesses, including implicit supervisor accesses, so that the mode-based
> protections are applied before paging. Also enforce LASS on the linear
> addresses consumed by emulated VMX and SGX ENCLS instructions.
> 
> Linear addresses used for TLB invalidation (INVLPG, INVPCID, and
> INVVPID) and branch targets are not subject to LASS enforcement.
> 
> Signed-off-by: Zeng Guang <[email protected]>
> Signed-off-by: Binbin Wu <[email protected]>
> Signed-off-by: Sohil Mehta <[email protected]>

Reviewed-by: Binbin Wu <[email protected]>



Reply via email to