Skip to content

Commit c5b41a6

Browse files
suryasaimadhuH. Peter Anvin
authored andcommitted
x86, cpu: Convert Cyrix coma bug detection
... to the new facility. Signed-off-by: Borislav Petkov <bp@suse.de> Link: http://lkml.kernel.org/r/1363788448-31325-5-git-send-email-bp@alien8.de Signed-off-by: H. Peter Anvin <hpa@zytor.com>
1 parent 93a829e commit c5b41a6

4 files changed

Lines changed: 5 additions & 4 deletions

File tree

‎arch/x86/include/asm/cpufeature.h‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,7 @@
224224

225225
#define X86_BUG_F00F X86_BUG(0) /* Intel F00F */
226226
#define X86_BUG_FDIV X86_BUG(1) /* FPU FDIV */
227+
#define X86_BUG_COMA X86_BUG(2) /* Cyrix 6x86 coma */
227228

228229
#if defined(__KERNEL__) && !defined(__ASSEMBLY__)
229230

‎arch/x86/include/asm/processor.h‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,6 @@ struct cpuinfo_x86 {
9191
/* Problems on some 486Dx4's and old 386's: */
9292
char hard_math;
9393
char rfu;
94-
char coma_bug;
9594
char pad0;
9695
#else
9796
/* Number of 4K pages in DTLB/ITLB combined(in pages): */

‎arch/x86/kernel/cpu/cyrix.c‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ static void __cpuinit init_cyrix(struct cpuinfo_x86 *c)
249249
/* Emulate MTRRs using Cyrix's ARRs. */
250250
set_cpu_cap(c, X86_FEATURE_CYRIX_ARR);
251251
/* 6x86's contain this bug */
252-
c->coma_bug = 1;
252+
set_cpu_bug(c, X86_BUG_COMA);
253253
break;
254254

255255
case 4: /* MediaGX/GXm or Geode GXM/GXLV/GX1 */
@@ -317,7 +317,8 @@ static void __cpuinit init_cyrix(struct cpuinfo_x86 *c)
317317
/* Enable MMX extensions (App note 108) */
318318
setCx86_old(CX86_CCR7, getCx86_old(CX86_CCR7)|1);
319319
} else {
320-
c->coma_bug = 1; /* 6x86MX, it has the bug. */
320+
/* A 6x86MX - it has the bug. */
321+
set_cpu_bug(c, X86_BUG_COMA);
321322
}
322323
tmp = (!(dir0_lsn & 7) || dir0_lsn & 1) ? 2 : 0;
323324
Cx86_cb[tmp] = cyrix_model_mult2[dir0_lsn & 7];

‎arch/x86/kernel/cpu/proc.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ static void show_cpuinfo_misc(struct seq_file *m, struct cpuinfo_x86 *c)
3636
"wp\t\t: %s\n",
3737
static_cpu_has_bug(X86_BUG_FDIV) ? "yes" : "no",
3838
static_cpu_has_bug(X86_BUG_F00F) ? "yes" : "no",
39-
c->coma_bug ? "yes" : "no",
39+
static_cpu_has_bug(X86_BUG_COMA) ? "yes" : "no",
4040
c->hard_math ? "yes" : "no",
4141
c->hard_math ? "yes" : "no",
4242
c->cpuid_level,

0 commit comments

Comments
 (0)