lkml.org 
[lkml]   [2023]   [Jun]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH RFC v9 46/51] KVM: SVM: Add module parameter to enable the SEV-SNP
    Date
    From: Brijesh Singh <brijesh.singh@amd.com>

    Add a module parameter than can be used to enable or disable the SEV-SNP
    feature. Now that KVM contains the support for the SNP set the GHCB
    hypervisor feature flag to indicate that SNP is supported.

    Signed-off-by: Brijesh Singh <brijesh.singh@amd.com>
    Signed-off-by: Ashish Kalra <ashish.kalra@amd.com>
    Signed-off-by: Michael Roth <michael.roth@amd.com>
    ---
    arch/x86/kvm/svm/sev.c | 8 +++++---
    1 file changed, 5 insertions(+), 3 deletions(-)

    diff --git a/arch/x86/kvm/svm/sev.c b/arch/x86/kvm/svm/sev.c
    index 543926fa3200..adbe8c242d81 100644
    --- a/arch/x86/kvm/svm/sev.c
    +++ b/arch/x86/kvm/svm/sev.c
    @@ -54,14 +54,16 @@ module_param_named(sev, sev_enabled, bool, 0444);
    /* enable/disable SEV-ES support */
    static bool sev_es_enabled = true;
    module_param_named(sev_es, sev_es_enabled, bool, 0444);
    +
    +/* enable/disable SEV-SNP support */
    +static bool sev_snp_enabled = true;
    +module_param_named(sev_snp, sev_snp_enabled, bool, 0444);
    #else
    #define sev_enabled false
    #define sev_es_enabled false
    +#define sev_snp_enabled false
    #endif /* CONFIG_KVM_AMD_SEV */

    -/* enable/disable SEV-SNP support */
    -static bool sev_snp_enabled;
    -
    #define AP_RESET_HOLD_NONE 0
    #define AP_RESET_HOLD_NAE_EVENT 1
    #define AP_RESET_HOLD_MSR_PROTO 2
    --
    2.25.1
    \
     
     \ /
      Last update: 2023-06-12 06:55    [W:4.400 / U:0.296 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site