Add basic i386 support for VIA Nano processors.

This commit is contained in:
Jung-uk Kim 2009-01-12 22:01:49 +00:00
parent a13c2422da
commit e9e4425092
3 changed files with 23 additions and 4 deletions

View File

@ -678,9 +678,17 @@ i686_mem_drvinit(void *unused)
return;
if ((cpu_id & 0xf00) != 0x600 && (cpu_id & 0xf00) != 0xf00)
return;
if (cpu_vendor_id != CPU_VENDOR_INTEL &&
cpu_vendor_id != CPU_VENDOR_AMD)
switch (cpu_vendor_id) {
case CPU_VENDOR_INTEL:
case CPU_VENDOR_AMD:
break;
case CPU_VENDOR_CENTAUR:
if (cpu_exthigh >= 0x80000008)
break;
/* FALLTHROUGH */
default:
return;
}
mem_range_softc.mr_op = &i686_mrops;
}
SYSINIT(i686memdev, SI_SUB_DRIVERS, SI_ORDER_FIRST, i686_mem_drvinit, NULL);

View File

@ -606,6 +606,9 @@ printcpuinfo(void)
case 0x6d0:
strcpy(cpu_model, "VIA C7 Esther");
break;
case 0x6f0:
strcpy(cpu_model, "VIA Nano");
break;
default:
strcpy(cpu_model, "VIA/IDT Unknown");
}
@ -856,6 +859,9 @@ printcpuinfo(void)
);
}
if (cpu_vendor_id == CPU_VENDOR_CENTAUR)
print_via_padlock_info();
if ((cpu_feature & CPUID_HTT) &&
cpu_vendor_id == CPU_VENDOR_AMD)
cpu_feature &= ~CPUID_HTT;
@ -879,6 +885,11 @@ printcpuinfo(void)
I386_CPU_MODEL(cpu_id) >= 0x3))
tsc_is_invariant = 1;
break;
case CPU_VENDOR_CENTAUR:
if (I386_CPU_FAMILY(cpu_id) == 0x6 &&
I386_CPU_MODEL(cpu_id) >= 0xf)
tsc_is_invariant = 1;
break;
}
if (tsc_is_invariant)
printf("\n TSC: P-state invariant");
@ -915,8 +926,6 @@ printcpuinfo(void)
printf("\n CPU cache: write-through mode");
#endif
}
if (cpu_vendor_id == CPU_VENDOR_CENTAUR)
print_via_padlock_info();
/* Avoid ugly blank lines: only print newline when we have to. */
if (*cpu_vendor || cpu_id)
@ -1568,6 +1577,7 @@ print_via_padlock_info(void)
return;
case 0x6a0:
case 0x6d0:
case 0x6f0:
break;
default:
return;

View File

@ -686,6 +686,7 @@ initializecpu(void)
/* fall through. */
case 0x6a0:
case 0x6d0:
case 0x6f0:
init_via();
break;
default: