Add svm cpuid features to qemu-kvm
cover Add svm cpuid features to qemu-kvm
Hi,
this patch-set adds the svm cpuid feature flags to qemu-kvm. With this patch-set the npt feature-flag can be presented to the guest so that it will use nested-paging when emulated by the host kvm. Please review, comment and/or apply these patches :-)
Thanks,
Joerg
PATCH 1/3 qemu-kvm: Invert svm-flag setting logic
This patch changes the setting logic for the svm bit in qemu-kvm. The bit is now explicitly set on -enable-nesting instead of masked out if the parameter is not supplied.
--- target-i386/cpuid.c | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-)
target-i386/cpuid.c +6 -6
@@ -276,8 +276,8 @@ static x86_def_t builtin_x86_defs[] = { .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_CX16 | CPUID_EXT_POPCNT, .ext2_features = (PPRO_FEATURES &EXT2_FEATURE_MASK ) | CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX, - .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000000A, .model_id = "QEMU Virtual CPU version " QEMU_VERSION, },
@@ -303,8 +303,8 @@ static x86_def_t builtin_x86_defs[] = {CPUID_EXT3_CR8LEG, CPUID_EXT3_MISALIGNSSE, CPUID_EXT3_3DNOWPREFETCH, CPUID_EXT3_OSVW, CPUID_EXT3_IBS */ - .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000001A, .model_id ="AMD Phenom(tm) 9550 Quad-Core Processor" },
@@ -1154,8 +1154,8 @@ void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count,/* disable CPU features that KVM cannot support */ /* svm */ -if (!kvm_nested) - *ecx &= ~CPUID_EXT3_SVM ; +if (kvm_nested) + *ecx |=CPUID_EXT3_SVM ;/* 3dnow */ *edx &= ~0xc0000000 ; }
Signature · 1 line
1.7.0.4
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 36 lines · Joerg Roedel
This patch changes the setting logic for the svm bit in qemu-kvm. The bit is now explicitly set on -enable-nesting instead of masked out if the parameter is not supplied.
Signed-off-by Joerg Roedel <[email protected]>---
target-i386/cpuid.c| 12 ++++++------1 files changed, 6 insertions(+), 6 deletions(-)target-i386/cpuid.c +4
-4@@ -276,8 +276,8 @@ static x86_def_t builtin_x86_defs[] = { .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_CX16 | CPUID_EXT_POPCNT, .ext2_features = (PPRO_FEATURES &EXT2_FEATURE_MASK ) | CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX, - .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000000A, .model_id = "QEMU Virtual CPU version " QEMU_VERSION, },@@ -303,8 +303,8 @@ static x86_def_t builtin_x86_defs[] = {CPUID_EXT3_CR8LEG, CPUID_EXT3_MISALIGNSSE, CPUID_EXT3_3DNOWPREFETCH, CPUID_EXT3_OSVW, CPUID_EXT3_IBS */ - .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000001A, .model_id ="AMD Phenom(tm) 9550 Quad-Core Processor" },
target-i386/cpuid.c void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count, · line 1157
Quoted 6 lines
target-i386/cpuid.c +1
-2@@ -1154,8 +1154,8 @@ void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count,/* disable CPU features that KVM cannot support */ /* svm */ -if (!kvm_nested) - *ecx &= ~CPUID_EXT3_SVM ; +if (kvm_nested)
I think we should get rid of kvm_nested and -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.
Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 41 lines · Alexander Graf
Quoted 38 lines · Joerg Roedel
This patch changes the setting logic for the svm bit in qemu-kvm. The bit is now explicitly set on -enable-nesting instead of masked out if the parameter is not supplied.
Signed-off-by Joerg Roedel <[email protected]>---
target-i386/cpuid.c| 12 ++++++------1 files changed, 6 insertions(+), 6 deletions(-)target-i386/cpuid.c +4
-4@@ -276,8 +276,8 @@ static x86_def_t builtin_x86_defs[] = { .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_CX16 | CPUID_EXT_POPCNT, .ext2_features = (PPRO_FEATURES &EXT2_FEATURE_MASK ) | CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX, - .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000000A, .model_id = "QEMU Virtual CPU version " QEMU_VERSION, },@@ -303,8 +303,8 @@ static x86_def_t builtin_x86_defs[] = {CPUID_EXT3_CR8LEG, CPUID_EXT3_MISALIGNSSE, CPUID_EXT3_3DNOWPREFETCH, CPUID_EXT3_OSVW, CPUID_EXT3_IBS */ - .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000001A, .model_id ="AMD Phenom(tm) 9550 Quad-Core Processor" },@@ -1154,8 +1154,8 @@ void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count,/* disable CPU features that KVM cannot support */
Quoted 8 lines
target-i386/cpuid.c void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count, · line 1157
Quoted 4 lines
target-i386/cpuid.c +1
-2/* svm */ -if (!kvm_nested) - *ecx &= ~CPUID_EXT3_SVM ; +if (kvm_nested)I think we should get rid of
kvm_nestedand -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
I agree that its much nicer for mgmt tools if svm/vmx CPU flags can just be toggled in the normal manner. Might we also want to have a enable/disable nesting flag, so we can mirror the way real hardware lets you disable virt in the BIOS even when the CPU(s) have the vmx/svm flags set ?
Regards,
Daniel
Signature · 4 lines
|: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :| |: http://libvirt.org -o- http://virt-manager.org -o- http://deltacloud.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 49 lines · Daniel P. Berrange
Quoted 48 lines · Alexander Graf
Quoted 36 lines · Joerg Roedel
This patch changes the setting logic for the svm bit in qemu-kvm. The bit is now explicitly set on -enable-nesting instead of masked out if the parameter is not supplied.
Signed-off-by Joerg Roedel <[email protected]>---
target-i386/cpuid.c| 12 ++++++------1 files changed, 6 insertions(+), 6 deletions(-)target-i386/cpuid.c +4
-4@@ -276,8 +276,8 @@ static x86_def_t builtin_x86_defs[] = { .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_CX16 | CPUID_EXT_POPCNT, .ext2_features = (PPRO_FEATURES &EXT2_FEATURE_MASK ) | CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX, - .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features =CPUID_EXT3_LAHF_LM |CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000000A, .model_id = "QEMU Virtual CPU version " QEMU_VERSION, },@@ -303,8 +303,8 @@ static x86_def_t builtin_x86_defs[] = {CPUID_EXT3_CR8LEG, CPUID_EXT3_MISALIGNSSE, CPUID_EXT3_3DNOWPREFETCH, CPUID_EXT3_OSVW, CPUID_EXT3_IBS */ - .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_SVM | - CPUID_EXT3_ABM | CPUID_EXT3_SSE4A, + .ext3_features = CPUID_EXT3_LAHF_LM | CPUID_EXT3_ABM | + CPUID_EXT3_SSE4A, .xlevel = 0x8000001A, .model_id ="AMD Phenom(tm) 9550 Quad-Core Processor" },target-i386/cpuid.c void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count, · line 1157
Quoted 6 lines
target-i386/cpuid.c +1
-2@@ -1154,8 +1154,8 @@ void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count,/* disable CPU features that KVM cannot support */ /* svm */ -if (!kvm_nested) - *ecx &= ~CPUID_EXT3_SVM ; +if (kvm_nested)I think we should get rid of
kvm_nestedand -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.
Quoted 6 lines
Quoted 1 line
Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
I agree that its much nicer for mgmt tools if svm/vmx CPU flags can just be toggled in the normal manner. Might we also want to have a enable/disable nesting flag, so we can mirror the way real hardware lets you disable virt in the BIOS even when the CPU(s) have the vmx/svm flags set ?
I don't see how that's useful. We don't model anything like this in the kvm kernel module, so whatever we expose in user space would not be useful for detection testing. Also I'm fairly sure you either want nesting or you don't :). And if you want nesting, you probably want -cpu host too, since you lose migration anyways.
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 6 lines · Alexander Graf
Quoted 5 lines
I agree that its much nicer for mgmt tools if svm/vmx CPU flags can just be toggled in the normal manner. Might we also want to have a enable/disable nesting flag, so we can mirror the way real hardware lets you disable virt in the BIOS even when the CPU(s) have the vmx/svm flags set ?
I don't see how that's useful. We don't model anything like this in the kvm kernel module, so whatever we expose in user space would not be useful for detection testing. Also I'm fairly sure you either want nesting or you don't :). And if you want nesting, you probably want -cpu host too, since you lose migration anyways.
Why do you lost migration?
Signature · 1 line
error compiling committee.c: too many arguments to function
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 9 lines · Avi Kivity
Quoted 6 lines · Alexander Graf
Quoted 5 lines
I agree that its much nicer for mgmt tools if svm/vmx CPU flags can just be toggled in the normal manner. Might we also want to have a enable/disable nesting flag, so we can mirror the way real hardware lets you disable virt in the BIOS even when the CPU(s) have the vmx/svm flags set ?
I don't see how that's useful. We don't model anything like this in the kvm kernel module, so whatever we expose in user space would not be useful for detection testing. Also I'm fairly sure you either want nesting or you don't :). And if you want nesting, you probably want -cpu host too, since you lose migration anyways.
Why do you lost migration?
Is that part fixed already? Joerg worked so hard on so many things that I lost track of what works and what doesn't :).
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 3 lines · Alexander Graf
Quoted 2 lines
Why do you lost migration?
Is that part fixed already? Joerg worked so hard on so many things that I lost track of what works and what doesn't :).
Was it broken? How?
Signature · 1 line
error compiling committee.c: too many arguments to function
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 6 lines · Avi Kivity
Quoted 3 lines · Alexander Graf
Quoted 2 lines
Why do you lost migration?
Is that part fixed already? Joerg worked so hard on so many things that I lost track of what works and what doesn't :).
Was it broken? How?
When migrating inside l2 context, we're missing information. My idea back then was to force the l1 guest out of l2 context every time we want to migrate, but I'm not sure this has happened. Even then I'm not sure we're transferring the GIF.
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 3 lines · Alexander Graf
Quoted 2 lines
Was it broken? How?
When migrating inside l2 context, we're missing information. My idea back then was to force the l1 guest out of l2 context every time we want to migrate, but I'm not sure this has happened.
I thought that was implemented, but not sure (though it isn't clean architecturally).
Quoted 1 line
Even then I'm not sure we're transferring the GIF.
Argh, we aren't.
Signature · 1 line
error compiling committee.c: too many arguments to function
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 11 lines · Avi Kivity
Quoted 3 lines · Alexander Graf
Quoted 2 lines
Was it broken? How?
When migrating inside l2 context, we're missing information. My idea back then was to force the l1 guest out of l2 context every time we want to migrate, but I'm not sure this has happened.
I thought that was implemented, but not sure (though it isn't clean architecturally).
Quoted 1 line
Even then I'm not sure we're transferring the GIF.
Argh, we aren't.
Migration with nested-svm doesn't work reliably today. But that is on my list.
Joerg
Signature · 5 lines
AMD Operating System Research Center Advanced Micro Devices GmbH Einsteinring 24 85609 Dornach General Managers: Alberto Bozzo, Andrew Bowd Registration: Dornach, Landkr. Muenchen; Registerger. Muenchen, HRB Nr. 43632
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
In reply to Alexander GrafQuoted 4 lines · Alexander Graf
I think we should get rid of
kvm_nestedand -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
I agree, -enable-nesting is redundant with -cpu ,+svm.
Signature · 1 line
error compiling committee.c: too many arguments to function
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 7 lines · Avi Kivity
Quoted 4 lines · Alexander Graf
I think we should get rid of
kvm_nestedand -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
I agree, -enable-nesting is redundant with -cpu ,+svm.
This patchset makes -enable-nesting pratically a synonym for -cpu ,+svm. So we can safely remove -enable-nesting in the future.
Joerg
Signature · 5 lines
AMD Operating System Research Center Advanced Micro Devices GmbH Einsteinring 24 85609 Dornach General Managers: Alberto Bozzo, Andrew Bowd Registration: Dornach, Landkr. Muenchen; Registerger. Muenchen, HRB Nr. 43632
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 11 lines · Joerg
Quoted 7 lines · Avi Kivity
Quoted 4 lines · Alexander Graf
I think we should get rid of
kvm_nestedand -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
I agree, -enable-nesting is redundant with -cpu ,+svm.
This patchset makes -enable-nesting pratically a synonym for -cpu ,+svm. So we can safely remove -enable-nesting in the future.
Why not just not introduce it? :) It's always hard to get rid of legacy.
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 8 lines · Alexander Graf
Quoted 5 lines · Joerg
Quoted 4 lines · Avi Kivity
Quoted 3 lines · Alexander Graf
I think we should get rid of
kvm_nestedand -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.
Quoted 8 lines
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
I agree, -enable-nesting is redundant with -cpu ,+svm.
This patchset makes -enable-nesting pratically a synonym for -cpu ,+svm. So we can safely remove -enable-nesting in the future.
Why not just not introduce it? :) It's always hard to get rid of legacy.
Because its already there? The patches are against qemu-kvm.
Signature · 5 lines
AMD Operating System Research Center Advanced Micro Devices GmbH Einsteinring 24 85609 Dornach General Managers: Alberto Bozzo, Andrew Bowd Registration: Dornach, Landkr. Muenchen; Registerger. Muenchen, HRB Nr. 43632
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
In reply to Roedel, JoergQuoted 11 lines · Joerg
Quoted 7 lines · Avi Kivity
Quoted 4 lines · Alexander Graf
I think we should get rid of
kvm_nestedand -enable-nesting. Instead, we should enable the SVM bit in the "host" and "qemu64" cpu types, but not in "kvm64". This way users are safe to not use nested svm, but can choose to do so if they like.Also, it should be possible to do something like -cpu kvm64,flags=+svm. Without having to mess with -enable-nesting.
I agree, -enable-nesting is redundant with -cpu ,+svm.
This patchset makes -enable-nesting pratically a synonym for -cpu ,+svm. So we can safely remove -enable-nesting in the future.
Oh, because this is for qemu-kvm. Uh - how about a nice little patch that makes things work in qemu.git, leave out the -enable-nesting piece and just keep the -enable-nesting backwards compat patch in qemu-kvm.git - or maybe even remove it there.
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 4 lines · Alexander Graf
Oh, because this is for qemu-kvm. Uh - how about a nice little patch that makes things work in qemu.git, leave out the -enable-nesting piece and just keep the -enable-nesting backwards compat patch in qemu-kvm.git - or maybe even remove it there.
I can do this. Is it better to merge all this stuff into qemu.git instead of qemu-kvm.git? Then I target again for qemu.git.
Joerg
Signature · 5 lines
AMD Operating System Research Center Advanced Micro Devices GmbH Einsteinring 24 85609 Dornach General Managers: Alberto Bozzo, Andrew Bowd Registration: Dornach, Landkr. Muenchen; Registerger. Muenchen, HRB Nr. 43632
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 8 lines · Joerg
Quoted 4 lines · Alexander Graf
Oh, because this is for qemu-kvm. Uh - how about a nice little patch that makes things work in qemu.git, leave out the -enable-nesting piece and just keep the -enable-nesting backwards compat patch in qemu-kvm.git - or maybe even remove it there.
I can do this. Is it better to merge all this stuff into qemu.git instead of qemu-kvm.git? Then I target again for qemu.git.
Yes, please. We're finally moving towards getting rid of qemu-kvm.git :). Or at least degrading it to a staging tree.
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 9 lines · Alexander Graf
Quoted 6 lines · Joerg
Quoted 4 lines · Alexander Graf
Oh, because this is for qemu-kvm. Uh - how about a nice little patch that makes things work in qemu.git, leave out the -enable-nesting piece and just keep the -enable-nesting backwards compat patch in qemu-kvm.git - or maybe even remove it there.
Quoted 5 lines
Quoted 2 lines
I can do this. Is it better to merge all this stuff into qemu.git instead of qemu-kvm.git? Then I target again for qemu.git.
Yes, please. We're finally moving towards getting rid of qemu-kvm.git :). Or at least degrading it to a staging tree.
Who are the maintainers to talk with? Anthony? Anybody else?
Joerg
Signature · 5 lines
AMD Operating System Research Center Advanced Micro Devices GmbH Einsteinring 24 85609 Dornach General Managers: Alberto Bozzo, Andrew Bowd Registration: Dornach, Landkr. Muenchen; Registerger. Muenchen, HRB Nr. 43632
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 10 lines · Joerg
Quoted 9 lines · Alexander Graf
Quoted 6 lines · Joerg
Quoted 4 lines · Alexander Graf
Oh, because this is for qemu-kvm. Uh - how about a nice little patch that makes things work in qemu.git, leave out the -enable-nesting piece and just keep the -enable-nesting backwards compat patch in qemu-kvm.git - or maybe even remove it there.
Quoted 7 lines
Quoted 5 lines
Quoted 2 lines
I can do this. Is it better to merge all this stuff into qemu.git instead of qemu-kvm.git? Then I target again for qemu.git.
Yes, please. We're finally moving towards getting rid of qemu-kvm.git :). Or at least degrading it to a staging tree.
Who are the maintainers to talk with? Anthony? Anybody else?
Anthony, Avi, Marcelo.
Alex
Re: [Qemu-devel] [PATCH 1/3] qemu-kvm: Invert svm-flag setting logic
Quoted 3 lines · Alexander Graf
Quoted 2 lines
Who are the maintainers to talk with? Anthony? Anybody else?
Anthony, Avi, Marcelo.
Post the patches against qemu.git, Marcelo or myself will apply them against a staging branch (uq/master, for "upstream queue for qemu.git master") and ask Anthony to pull.
Signature · 1 line
error compiling committee.c: too many arguments to function
PATCH 2/3 qemu-kvm: Set cpuid definition to 0 before initializing it
In reply to Joerg RoedelThis patch cleans the (stack-allocated) cpuid definition to 0 before actually initializing it.
--- target-i386/cpuid.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
target-i386/cpuid.c +2 -0
@@ -788,6 +788,8 @@ int cpu_x86_register (CPUX86State *env, const char *cpu_model) {x86_def_t def1, *def = &def1; +memset (def,0 ,sizeof (*def)); +if (cpu_x86_find_by_name (def, cpu_model) <0 )return -1 ;if (def->vendor1) {
Signature · 1 line
1.7.0.4
PATCH 3/3 qemu-kvm: Add svm cpuid features
In reply to Joerg RoedelThis patch adds the svm cpuid feature flags to the qemu intialization path.
--- target-i386/cpu.h | 1 + target-i386/cpuid.c | 50 +++++++++++++++++++++++++++++++++++++++++--------- target-i386/kvm.c | 3 +++ 3 files changed, 45 insertions(+), 9 deletions(-)
target-i386/cpu.h +1 -0
@@ -718,6 +718,7 @@ typedef struct CPUX86State {uint8_t has_error_code;uint32_t sipi_vector;uint32_t cpuid_kvm_features; +uint32_t cpuid_svm_features;/* in order to simplify APIC support, we leave this pointer to the user */
target-i386/cpuid.c +41 -9
127 lines not on this page · raw message
target-i386/kvm.c +3 -0
@@ -204,6 +204,9 @@ int kvm_arch_init_vcpu(CPUState *env) 0, R_EDX); env->cpuid_ext3_features &=kvm_arch_get_supported_cpuid (env,0x80000001 ,0 ,R_ECX ); + env->cpuid_kvm_features &=kvm_arch_get_supported_cpuid (env,0x8000000A , +0 ,R_EDX ); + cpuid_i =0 ;
Signature · 1 line
1.7.0.4