[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 01/11] target-i386: Add ECX information to FeatureWor
From: |
Andreas Färber |
Subject: |
[Qemu-devel] [PULL 01/11] target-i386: Add ECX information to FeatureWordInfo |
Date: |
Mon, 6 May 2013 22:43:21 +0200 |
From: Eduardo Habkost <address@hidden>
FEAT_7_0_EBX uses ECX as input, so we have to take that into account
when reporting feature word values.
Signed-off-by: Eduardo Habkost <address@hidden>
Signed-off-by: Andreas Färber <address@hidden>
---
target-i386/cpu.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/target-i386/cpu.c b/target-i386/cpu.c
index 9f2adad..0f92469 100644
--- a/target-i386/cpu.c
+++ b/target-i386/cpu.c
@@ -152,8 +152,10 @@ static const char *cpuid_7_0_ebx_feature_name[] = {
typedef struct FeatureWordInfo {
const char **feat_names;
- uint32_t cpuid_eax; /* Input EAX for CPUID */
- int cpuid_reg; /* R_* register constant */
+ uint32_t cpuid_eax; /* Input EAX for CPUID */
+ bool cpuid_needs_ecx; /* CPUID instruction uses ECX as input */
+ uint32_t cpuid_ecx; /* Input ECX value for CPUID */
+ int cpuid_reg; /* output register (R_* constant) */
} FeatureWordInfo;
static FeatureWordInfo feature_word_info[FEATURE_WORDS] = {
@@ -187,7 +189,9 @@ static FeatureWordInfo feature_word_info[FEATURE_WORDS] = {
},
[FEAT_7_0_EBX] = {
.feat_names = cpuid_7_0_ebx_feature_name,
- .cpuid_eax = 7, .cpuid_reg = R_EBX,
+ .cpuid_eax = 7,
+ .cpuid_needs_ecx = true, .cpuid_ecx = 0,
+ .cpuid_reg = R_EBX,
},
};
--
1.8.1.4
- [Qemu-devel] [PULL for-1.5 00/11] QOM CPUState patch queue 2013-05-06, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 01/11] target-i386: Add ECX information to FeatureWordInfo,
Andreas Färber <=
- [Qemu-devel] [PULL 02/11] target-i386: Use FeatureWord loop on filter_features_for_kvm(), Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 04/11] target-i386: Introduce X86CPU::filtered_features field, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 05/11] target-i386: Add "filtered-features" property to X86CPU, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 08/11] target-i386: Emulate X86CPU subclasses for global properties, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 03/11] target-i386: Add "feature-words" property to X86CPU, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 06/11] qdev: Let qdev_prop_parse() pass through Error, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 07/11] qdev: Introduce qdev_prop_set_globals_for_type(), Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 09/11] target-i386: Change CPUID model of 486 to 8, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 10/11] target-i386: Introduce generic CPUID feature compat function, Andreas Färber, 2013/05/06
- [Qemu-devel] [PULL 11/11] target-i386: n270 can MOVBE, Andreas Färber, 2013/05/06