Linux Will Finally Indicate Via /proc/cpuinfo If AMD SVM Virtualization Is Disabled

Written by Michael Larabel in AMD on 2 October 2023 at 03:18 PM EDT. Add A Comment
AMD
Checking for the presence of Intel virtualization (VMX) support and it being enabled can be easily achieved by looking at the flags in /proc/cpuinfo. But to this point AMD virtualization (SVM) has always been shown to user-space via /proc/cpuinfo even when the BIOS/platform has disabled SVM functionality. Finally for Linux 6.7 this oversight is being corrected.

Beginning with the upcoming Linux 6.7 kernel cycle -- though potentially back-ported as a fix to existing kernel series -- is a patch from Red Hat to no longer advertise SVM via /proc/cpuinfo for cases where SVM is disabled in the BIOS. This matches the behavior of Intel VMX not appearing via /proc/cpuinfo either when it's been disabled by the platform/BIOS, which makes it much easier to check if virtualization is available via this convenient and widely-used interface.

AMD SVM in /proc/cpuinfo


This patch by Red Hat's Paolo Bonzini has been queued into TIP's x86/cpu branch ahead of the Linux 6.7 merge window coming up in about one month. For AMD (and Hygon) processors it will now read the appropriate MSR to verify whether SVM has been disabled -- and if so to clear the CPU capability so it won't show in /proc/cpuinfo. Up to now the only indication of AMD SVM being disabled by the BIOS was appearing in the kernel log -- or simply KVM virtualization failing to work. A small but useful change.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week