Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\include\asm\virtext.h Create Date:2022-07-28 08:18:19
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Check if the CPU has SVM support* You can use the 'msg' arg to get a message describing the problem,* if the function returns zero. Simply pass NULL if you are not interested* on the messages; gcc should take care of not generating code for

Proto:static inline int cpu_has_svm(const char **msg)

Type:int

Parameter:

TypeParameterName
const char **msg
84  If CPU vendor != X86_VENDOR_AMD && CPU vendor != X86_VENDOR_HYGON Then
86  If msg Then msg = "not amd or hygon"
88  Return 0
91  If Max extended CPUID function supported: < SVM_CPUID_FUNC Then
92  If msg Then msg = "can't execute cpuid_8000000a"
94  Return 0
97  If Not boot_cpu_has(Secure Virtual Machine ) Then
98  If msg Then msg = "svm not available"
100  Return 0
102  Return 1