[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 02/12] cpuid: fix over-long lines
From: |
Andre Przywara |
Subject: |
[Qemu-devel] [PATCH 02/12] cpuid: fix over-long lines |
Date: |
Fri, 11 Sep 2009 00:20:47 +0200 |
split lines longer than 80 characters.
Only code formatting changed.
Signed-off-by: Andre Przywara <address@hidden>
---
target-i386/cpuid.c | 25 +++++++++++++++++--------
1 files changed, 17 insertions(+), 8 deletions(-)
diff --git a/target-i386/cpuid.c b/target-i386/cpuid.c
index 0c0c0b7..b610834 100644
--- a/target-i386/cpuid.c
+++ b/target-i386/cpuid.c
@@ -289,8 +289,10 @@ static x86_def_t x86_defs[] = {
.family = 6,
.model = 2,
.stepping = 3,
- .features = PPRO_FEATURES | CPUID_PSE36 | CPUID_VME | CPUID_MTRR |
CPUID_MCA,
- .ext2_features = (PPRO_FEATURES & 0x0183F3FF) | CPUID_EXT2_MMXEXT |
CPUID_EXT2_3DNOW | CPUID_EXT2_3DNOWEXT,
+ .features = PPRO_FEATURES | CPUID_PSE36 | CPUID_VME |
+ CPUID_MTRR | CPUID_MCA,
+ .ext2_features = (PPRO_FEATURES & EXT2_FEATURE_MASK) |
+ CPUID_EXT2_MMXEXT | CPUID_EXT2_3DNOW | CPUID_EXT2_3DNOWEXT,
.xlevel = 0x80000008,
/* XXX: put another string ? */
.model_id = "QEMU Virtual CPU version " QEMU_VERSION,
@@ -373,8 +375,10 @@ static int cpu_x86_find_by_name(x86_def_t *x86_cpu_def,
const char *cpu_model)
char *s = strdup(cpu_model);
char *featurestr, *name = strtok(s, ",");
- uint32_t plus_features = 0, plus_ext_features = 0, plus_ext2_features = 0,
plus_ext3_features = 0;
- uint32_t minus_features = 0, minus_ext_features = 0, minus_ext2_features =
0, minus_ext3_features = 0;
+ uint32_t plus_features = 0, plus_ext_features = 0;
+ uint32_t plus_ext2_features = 0, plus_ext3_features = 0;
+ uint32_t minus_features = 0, minus_ext_features = 0;
+ uint32_t minus_ext2_features = 0, minus_ext3_features = 0;
uint32_t numvalue;
def = NULL;
@@ -400,9 +404,12 @@ static int cpu_x86_find_by_name(x86_def_t *x86_cpu_def,
const char *cpu_model)
while (featurestr) {
char *val;
if (featurestr[0] == '+') {
- add_flagname_to_bitmaps(featurestr + 1, &plus_features,
&plus_ext_features, &plus_ext2_features, &plus_ext3_features);
+ add_flagname_to_bitmaps(featurestr + 1, &plus_features,
+ &plus_ext_features, &plus_ext2_features, &plus_ext3_features);
} else if (featurestr[0] == '-') {
- add_flagname_to_bitmaps(featurestr + 1, &minus_features,
&minus_ext_features, &minus_ext2_features, &minus_ext3_features);
+ add_flagname_to_bitmaps(featurestr + 1,
+ &minus_features, &minus_ext_features,
+ &minus_ext2_features, &minus_ext3_features);
} else if ((val = strchr(featurestr, '='))) {
*val = 0; val++;
if (!strcmp(featurestr, "family")) {
@@ -470,7 +477,8 @@ static int cpu_x86_find_by_name(x86_def_t *x86_cpu_def,
const char *cpu_model)
goto error;
}
} else {
- fprintf(stderr, "feature string `%s' not in format
(+feature|-feature|feature=xyz)\n", featurestr);
+ fprintf(stderr, "feature string `%s' not in format "
+ "(+feature|-feature|feature=xyz)\n", featurestr);
goto error;
}
featurestr = strtok(NULL, ",");
@@ -609,7 +617,8 @@ void cpu_x86_cpuid(CPUX86State *env, uint32_t index,
uint32_t count,
break;
case 1:
*eax = env->cpuid_version;
- *ebx = (env->cpuid_apic_id << 24) | 8 << 8; /* CLFLUSH size in quad
words, Linux wants it. */
+ /* CLFLUSH size in quad words, Linux wants it. */
+ *ebx = (env->cpuid_apic_id << 24) | 8 << 8;
*ecx = env->cpuid_ext_features;
*edx = env->cpuid_features;
if (env->nr_cores * env->nr_threads > 1) {
--
1.6.1.3
- [Qemu-devel] [PATCH 0/12] cpuid: cleanup and some enhancements, Andre Przywara, 2009/09/10
- [Qemu-devel] [PATCH 02/12] cpuid: fix over-long lines,
Andre Przywara <=
- [Qemu-devel] [PATCH 01/12] cpuid: move CPUID functions into separate file, Andre Przywara, 2009/09/10
- [Qemu-devel] [PATCH 03/12] cpuid: replace magic number with named constant, Andre Przywara, 2009/09/10
- [Qemu-devel] [PATCH 05/12] cpuid: moved host_cpuid function and remove prototype, Andre Przywara, 2009/09/10
- [Qemu-devel] [PATCH 04/12] cpuid: fix comments, Andre Przywara, 2009/09/10
- [Qemu-devel] [PATCH 09/12] cpuid: simplify CPUID flag search function, Andre Przywara, 2009/09/10
- [Qemu-devel] [PATCH 06/12] cpuid: add missing CPUID feature flag names, Andre Przywara, 2009/09/10
- [Qemu-devel] [PATCH 11/12] cpuid: add TCG feature bit trimming, Andre Przywara, 2009/09/10