Skip to content
This repository was archived by the owner on Jul 18, 2025. It is now read-only.

Commit 173a41d

Browse files
committed
Fix broken IsVTXDisabled detection on AMD CPU
VMX is in FeatureNames, but SVM is in ExtraFeatureNames This meant that detection *always* failed for SVM (AMD) Thanks to user @hilbertxia Signed-off-by: Anders F Björklund <anders.f.bjorklund@gmail.com>
1 parent 61ef47d commit 173a41d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎drivers/virtualbox/vtx_intel.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import "github.com/intel-go/cpuid"
66

77
// IsVTXDisabled checks if VT-x is disabled in the CPU.
88
func (d *Driver) IsVTXDisabled() bool {
9-
if cpuid.HasFeature(cpuid.VMX) || cpuid.HasFeature(cpuid.SVM) {
9+
if cpuid.HasFeature(cpuid.VMX) || cpuid.HasExtraFeature(cpuid.SVM) {
1010
return false
1111
}
1212

0 commit comments

Comments
 (0)