* Bernhard M. Wiedemann (bwiedem...@suse.de) wrote:
> Without this patch, a VM on a Opteron G3 host will have the svm flag, but
> the kvm-amd module fails to load in there, complaining that it needs
> cpuid 0x8000000a
> 
> I have successfully built and tested this for 3+ years in production
> on Opteron G3 servers.
> 
> Signed-off-by: Bernhard M. Wiedemann <bwiedem...@suse.de>
> ---
>  target/i386/cpu.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/target/i386/cpu.c b/target/i386/cpu.c
> index 722c5514d4..df1d81ded8 100644
> --- a/target/i386/cpu.c
> +++ b/target/i386/cpu.c
> @@ -2723,7 +2723,7 @@ static X86CPUDefinition builtin_x86_defs[] = {
>              CPUID_EXT_SSE3,
>          .features[FEAT_8000_0001_EDX] =
>              CPUID_EXT2_LM | CPUID_EXT2_NX | CPUID_EXT2_SYSCALL,
> -        .xlevel = 0x80000008,
> +        .xlevel = 0x8000000A,
>          .model_id = "AMD Opteron 240 (Gen 1 Class Opteron)",
>      },
>      {
> @@ -2745,7 +2745,7 @@ static X86CPUDefinition builtin_x86_defs[] = {
>              CPUID_EXT2_LM | CPUID_EXT2_NX | CPUID_EXT2_SYSCALL,
>          .features[FEAT_8000_0001_ECX] =
>              CPUID_EXT3_SVM | CPUID_EXT3_LAHF_LM,
> -        .xlevel = 0x80000008,
> +        .xlevel = 0x8000000A,
>          .model_id = "AMD Opteron 22xx (Gen 2 Class Opteron)",
>      },
>      {
> @@ -2770,7 +2770,7 @@ static X86CPUDefinition builtin_x86_defs[] = {
>          .features[FEAT_8000_0001_ECX] =
>              CPUID_EXT3_MISALIGNSSE | CPUID_EXT3_SSE4A |
>              CPUID_EXT3_ABM | CPUID_EXT3_SVM | CPUID_EXT3_LAHF_LM,
> -        .xlevel = 0x80000008,
> +        .xlevel = 0x8000000A,
>          .model_id = "AMD Opteron 23xx (Gen 3 Class Opteron)",
>      },
>      {

cc'ing in Bandan and Eduardo,

I suspect these need to have compatibility entries on the machine types
so that old machine types don't notice the improvement.

Dave

> -- 
> 2.16.4
> 
> 
--
Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Reply via email to