Bug 8355 - Intel: backport KVM LAM from v6.8
Summary: Intel: backport KVM LAM from v6.8
Status: RESOLVED FIXED
Alias: None
Product: ANCK 6.6 Dev
Classification: ANCK
Component: X86 (show other bugs) X86
Version: unspecified
Hardware: x86_64 Linux
: P3-Medium S3-normal
Target Milestone: ---
Assignee: Guanjun
QA Contact: shuming
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-02-28 10:34 UTC by zhiquan1-li
Modified: 2025-01-16 09:16 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description zhiquan1-li intel_group 2024-02-28 10:34:51 UTC
Summary
-------
KVM x86 support for virtualizing Linear Address Masking (LAM)

Add KVM support for Linear Address Masking (LAM).  LAM tweaks the canonicality
checks for most virtual address usage in 64-bit mode, such that only the most
significant bit of the untranslated address bits must match the polarity of the
last translated address bit.  This allows software to use ignored, untranslated
address bits for metadata, e.g. to efficiently tag pointers for address
sanitization.

Commit list
------------
183bdd161c2b KVM: x86: Use KVM-governed feature framework to track "LAM enabled"
703d794cb8cb KVM: x86: Advertise and enable LAM (user and supervisor)
3098e6eca88e KVM: x86: Virtualize LAM for user pointer
93d1c9f498a7 KVM: x86: Virtualize LAM for supervisor pointer
b39bd520a60c KVM: x86: Untag addresses for LAM emulation where applicable
37a41847b770 KVM: x86: Introduce get_untagged_addr() in kvm_x86_ops and call it in emulator
9c8021d4ae85 KVM: x86: Remove kvm_vcpu_is_illegal_gpa()
2c49db455ee2 KVM: x86: Add & use kvm_vcpu_is_legal_cr3() to check CR3's legality
a130066f7400 KVM: x86/mmu: Drop non-PA bits when getting GFN for guest's PGD
538ac9a92d66 KVM: x86: Add X86EMUL_F_INVLPG and pass it in em_invlpg()
3963c52df422 KVM: x86: Add an emulation flag for implicit system access
7b0dd9430cf0 KVM: x86: Consolidate flags for __linearize()

References
----------
[GIT PULL] KVM: x86: LAM support for 6.8
https://lore.kernel.org/kvm/20240104193303.3175844-4-seanjc@google.com/
Comment 1 小龙 admin 2024-02-29 22:28:38 UTC
The PR Link: https://gitee.com/anolis/cloud-kernel/pulls/2805
Comment 2 zhiquan1-li intel_group 2025-01-16 09:16:07 UTC
Merged