VIA C3 identification

Gary Allan dragonfly at gallan.plus.com
Mon May 8 11:12:55 PDT 2006


Hello,

I've added identifying additional VIA processors from FreeBSD. My C3 is 
now named correctly on startup.

Regards
Gary
Index: sys/i386/i386/identcpu.c
===================================================================
RCS file: /home/dcvs/src/sys/i386/i386/identcpu.c,v
retrieving revision 1.9
diff -u -r1.9 identcpu.c
--- sys/i386/i386/identcpu.c	6 Nov 2005 07:28:47 -0000	1.9
+++ sys/i386/i386/identcpu.c	14 Apr 2006 14:08:05 -0000
@@ -529,8 +529,30 @@
 		case 0x580:
 			strcpy(cpu_model, "IDT WinChip 2");
 			break;
+		case 0x660:
+			strcpy(cpu_model, "VIA C3 Samuel");
+			break;
 		case 0x670:
-			strcpy(cpu_model, "VIA C3 Samuel 2");
+			if (cpu_id & 0x8)
+				strcpy(cpu_model, "VIA C3 Ezra");
+			else
+				strcpy(cpu_model, "VIA C3 Samuel 2");
+			break;
+		case 0x680:
+			strcpy(cpu_model, "VIA C3 Ezra-T");
+			break;
+		case 0x690:
+			strcpy(cpu_model, "VIA C3 Nehemiah");
+			do_cpuid(0xc0000000, regs);
+			if (regs[0] == 0xc0000001) {
+				do_cpuid(0xc0000001, regs);
+				if ((cpu_id & 0xf) >= 3)
+					if ((regs[3] & 0x0c) == 0x0c)
+						strcat(cpu_model, "+RNG");
+				if ((cpu_id & 0xf) >= 8)
+					if ((regs[3] & 0xc0) == 0xc0)
+						strcat(cpu_model, "+ACE");
+			}
 			break;
 		default:
 			strcpy(cpu_model, "VIA/IDT Unknown");




More information about the Submit mailing list