Commit e268bee
committed
KVM: SVM: Mark VMCB dirty before processing incoming snp_vmsa_gpa
Mark the VMCB dirty, i.e. zero control.clean, prior to handling the new
VMSA. Nothing in the VALID_PAGE() case touches control.clean, and
isolating the VALID_PAGE() code will allow simplifying the overall logic.
Note, the VMCB probably doesn't need to be marked dirty when the VMSA is
invalid, as KVM will disallow running the vCPU in such a state. But it
also doesn't hurt anything.
Reviewed-by: Tom Lendacky <thomas.lendacky@amd.com>
Link: https://lore.kernel.org/r/20250227012541.3234589-9-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>1 parent 4633243 commit e268bee
1 file changed
Lines changed: 6 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3855 | 3855 | | |
3856 | 3856 | | |
3857 | 3857 | | |
| 3858 | + | |
| 3859 | + | |
| 3860 | + | |
| 3861 | + | |
| 3862 | + | |
| 3863 | + | |
3858 | 3864 | | |
3859 | 3865 | | |
3860 | 3866 | | |
| |||
3901 | 3907 | | |
3902 | 3908 | | |
3903 | 3909 | | |
3904 | | - | |
3905 | | - | |
3906 | | - | |
3907 | | - | |
3908 | | - | |
3909 | | - | |
3910 | 3910 | | |
3911 | 3911 | | |
3912 | 3912 | | |
| |||
0 commit comments