diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2024-04-04 14:13:19 +0200 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2024-04-11 19:08:24 +0200 |
commit | 4ebb105e6c6f374fdc4e0302000e9fee1e2f5936 (patch) | |
tree | 6905e8f5ebcccfa3e97d300bb1c5e68f463ab9c9 /arch/x86/kvm/svm/svm.h | |
parent | KVM: x86: Add supported_vm_types to kvm_caps (diff) | |
download | linux-4ebb105e6c6f374fdc4e0302000e9fee1e2f5936.tar.xz linux-4ebb105e6c6f374fdc4e0302000e9fee1e2f5936.zip |
KVM: SEV: introduce to_kvm_sev_info
Suggested-by: Sean Christopherson <seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Message-ID: <20240404121327.3107131-10-pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/x86/kvm/svm/svm.h')
-rw-r--r-- | arch/x86/kvm/svm/svm.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/x86/kvm/svm/svm.h b/arch/x86/kvm/svm/svm.h index 4a1623cacbae..5d5b8ed43db8 100644 --- a/arch/x86/kvm/svm/svm.h +++ b/arch/x86/kvm/svm/svm.h @@ -319,6 +319,11 @@ static __always_inline struct kvm_svm *to_kvm_svm(struct kvm *kvm) return container_of(kvm, struct kvm_svm, kvm); } +static __always_inline struct kvm_sev_info *to_kvm_sev_info(struct kvm *kvm) +{ + return &to_kvm_svm(kvm)->sev_info; +} + static __always_inline bool sev_guest(struct kvm *kvm) { #ifdef CONFIG_KVM_AMD_SEV |