File tree Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change 29
29
#include <linux/cc_platform.h>
30
30
#include <linux/smp.h>
31
31
#include <linux/string_choices.h>
32
+ #include <linux/mutex.h>
32
33
33
34
#include <asm/apic.h>
34
35
#include <asm/perf_event.h>
@@ -249,6 +250,8 @@ static unsigned long iopm_base;
249
250
250
251
DEFINE_PER_CPU (struct svm_cpu_data , svm_data );
251
252
253
+ static DEFINE_MUTEX (vmcb_dump_mutex );
254
+
252
255
/*
253
256
* Only MSR_TSC_AUX is switched via the user return hook. EFER is switched via
254
257
* the VMCB, and the SYSCALL/SYSENTER MSRs are handled by VMLOAD/VMSAVE.
@@ -3404,6 +3407,8 @@ static void dump_vmcb(struct kvm_vcpu *vcpu)
3404
3407
return ;
3405
3408
}
3406
3409
3410
+ guard (mutex )(& vmcb_dump_mutex );
3411
+
3407
3412
vm_type = sev_snp_guest (vcpu -> kvm ) ? "SEV-SNP" :
3408
3413
sev_es_guest (vcpu -> kvm ) ? "SEV-ES" :
3409
3414
sev_guest (vcpu -> kvm ) ? "SEV" : "SVM" ;
You can’t perform that action at this time.
0 commit comments