]>
Commit | Line | Data |
---|---|---|
507c6de3 WB |
1 | From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 |
2 | From: Eduardo Habkost <ehabkost@redhat.com> | |
3 | Date: Tue, 9 Jan 2018 13:45:18 -0200 | |
4 | Subject: [PATCH] i386: Add EPYC-IBPB CPU model | |
5 | ||
6 | EPYC-IBPB is a copy of the EPYC CPU model with | |
7 | just CPUID_8000_0008_EBX_IBPB added. | |
8 | ||
9 | Cc: Jiri Denemark <jdenemar@redhat.com> | |
10 | Cc: Tom Lendacky <thomas.lendacky@amd.com> | |
11 | Cc: Brijesh Singh <brijesh.singh@amd.com> | |
12 | Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> | |
13 | Message-Id: <20180109154519.25634-7-ehabkost@redhat.com> | |
14 | Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> | |
15 | --- | |
16 | target/i386/cpu.c | 46 ++++++++++++++++++++++++++++++++++++++++++++++ | |
17 | 1 file changed, 46 insertions(+) | |
18 | ||
19 | diff --git a/target/i386/cpu.c b/target/i386/cpu.c | |
20 | index e977c6c616..95e6a1f122 100644 | |
21 | --- a/target/i386/cpu.c | |
22 | +++ b/target/i386/cpu.c | |
23 | @@ -1967,6 +1967,52 @@ static X86CPUDefinition builtin_x86_defs[] = { | |
24 | .xlevel = 0x8000000A, | |
25 | .model_id = "AMD EPYC Processor", | |
26 | }, | |
27 | + { | |
28 | + .name = "EPYC-IBPB", | |
29 | + .level = 0xd, | |
30 | + .vendor = CPUID_VENDOR_AMD, | |
31 | + .family = 23, | |
32 | + .model = 1, | |
33 | + .stepping = 2, | |
34 | + .features[FEAT_1_EDX] = | |
35 | + CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX | CPUID_CLFLUSH | | |
36 | + CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA | CPUID_PGE | | |
37 | + CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 | CPUID_MCE | | |
38 | + CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE | CPUID_DE | | |
39 | + CPUID_VME | CPUID_FP87, | |
40 | + .features[FEAT_1_ECX] = | |
41 | + CPUID_EXT_RDRAND | CPUID_EXT_F16C | CPUID_EXT_AVX | | |
42 | + CPUID_EXT_XSAVE | CPUID_EXT_AES | CPUID_EXT_POPCNT | | |
43 | + CPUID_EXT_MOVBE | CPUID_EXT_SSE42 | CPUID_EXT_SSE41 | | |
44 | + CPUID_EXT_CX16 | CPUID_EXT_FMA | CPUID_EXT_SSSE3 | | |
45 | + CPUID_EXT_MONITOR | CPUID_EXT_PCLMULQDQ | CPUID_EXT_SSE3, | |
46 | + .features[FEAT_8000_0001_EDX] = | |
47 | + CPUID_EXT2_LM | CPUID_EXT2_RDTSCP | CPUID_EXT2_PDPE1GB | | |
48 | + CPUID_EXT2_FFXSR | CPUID_EXT2_MMXEXT | CPUID_EXT2_NX | | |
49 | + CPUID_EXT2_SYSCALL, | |
50 | + .features[FEAT_8000_0001_ECX] = | |
51 | + CPUID_EXT3_OSVW | CPUID_EXT3_3DNOWPREFETCH | | |
52 | + CPUID_EXT3_MISALIGNSSE | CPUID_EXT3_SSE4A | CPUID_EXT3_ABM | | |
53 | + CPUID_EXT3_CR8LEG | CPUID_EXT3_SVM | CPUID_EXT3_LAHF_LM, | |
54 | + .features[FEAT_8000_0008_EBX] = | |
55 | + CPUID_8000_0008_EBX_IBPB, | |
56 | + .features[FEAT_7_0_EBX] = | |
57 | + CPUID_7_0_EBX_FSGSBASE | CPUID_7_0_EBX_BMI1 | CPUID_7_0_EBX_AVX2 | | |
58 | + CPUID_7_0_EBX_SMEP | CPUID_7_0_EBX_BMI2 | CPUID_7_0_EBX_RDSEED | | |
59 | + CPUID_7_0_EBX_ADX | CPUID_7_0_EBX_SMAP | CPUID_7_0_EBX_CLFLUSHOPT | | |
60 | + CPUID_7_0_EBX_SHA_NI, | |
61 | + /* Missing: XSAVES (not supported by some Linux versions, | |
62 | + * including v4.1 to v4.12). | |
63 | + * KVM doesn't yet expose any XSAVES state save component. | |
64 | + */ | |
65 | + .features[FEAT_XSAVE] = | |
66 | + CPUID_XSAVE_XSAVEOPT | CPUID_XSAVE_XSAVEC | | |
67 | + CPUID_XSAVE_XGETBV1, | |
68 | + .features[FEAT_6_EAX] = | |
69 | + CPUID_6_EAX_ARAT, | |
70 | + .xlevel = 0x8000000A, | |
71 | + .model_id = "AMD EPYC Processor (with IBPB)", | |
72 | + }, | |
73 | }; | |
74 | ||
75 | typedef struct PropValue { | |
76 | -- | |
77 | 2.11.0 | |
78 |