diff options
| author | Bruce Evans <bde@FreeBSD.org> | 1996-05-01 08:31:21 +0000 |
|---|---|---|
| committer | Bruce Evans <bde@FreeBSD.org> | 1996-05-01 08:31:21 +0000 |
| commit | 0f99c703ec513df6f98a7cb383f042ff095f7eee (patch) | |
| tree | f5bc32a5c4089798c72f1023566484cf1323f0a2 | |
| parent | 5e26fb6fdf46965fedb4f7ebdecf13f42c80a424 (diff) | |
Notes
| -rw-r--r-- | sys/amd64/amd64/machdep.c | 17 | ||||
| -rw-r--r-- | sys/i386/i386/machdep.c | 17 |
2 files changed, 6 insertions, 28 deletions
diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c index bf14b68d89f2..03cf8642a5ec 100644 --- a/sys/amd64/amd64/machdep.c +++ b/sys/amd64/amd64/machdep.c @@ -35,7 +35,7 @@ * SUCH DAMAGE. * * from: @(#)machdep.c 7.4 (Berkeley) 6/3/91 - * $Id: machdep.c,v 1.183 1996/04/25 06:20:10 phk Exp $ + * $Id: machdep.c,v 1.184 1996/04/26 13:47:39 phk Exp $ */ #include "npx.h" @@ -245,6 +245,7 @@ cpu_startup(dummy) * Good {morning,afternoon,evening,night}. */ printf(version); + cpu_class = i386_cpus[cpu].cpu_class; startrtclock(); identifycpu(); printf("real memory = %d (%dK bytes)\n", ptoa(Maxmem), ptoa(Maxmem) / 1024); @@ -491,20 +492,8 @@ static void identifycpu() { printf("CPU: "); - if (cpu >= 0 - && cpu < (sizeof i386_cpus/sizeof(struct cpu_nameclass))) { - cpu_class = i386_cpus[cpu].cpu_class; - strncpy(cpu_model, i386_cpus[cpu].cpu_name, sizeof cpu_model); - } else { - printf("unknown cpu type %d\n", cpu); - panic("startup: bad cpu id"); - } + strncpy(cpu_model, i386_cpus[cpu].cpu_name, sizeof cpu_model); -#if defined(I586_CPU) || defined(I686_CPU) - if (cpu_class == CPUCLASS_586 || cpu_class == CPUCLASS_686) { - calibrate_cyclecounter(); - } -#endif #if defined(I486_CPU) || defined(I586_CPU) || defined(I686_CPU) if (!strcmp(cpu_vendor,"GenuineIntel")) { if ((cpu_id & 0xf00) > 3) { diff --git a/sys/i386/i386/machdep.c b/sys/i386/i386/machdep.c index bf14b68d89f2..03cf8642a5ec 100644 --- a/sys/i386/i386/machdep.c +++ b/sys/i386/i386/machdep.c @@ -35,7 +35,7 @@ * SUCH DAMAGE. * * from: @(#)machdep.c 7.4 (Berkeley) 6/3/91 - * $Id: machdep.c,v 1.183 1996/04/25 06:20:10 phk Exp $ + * $Id: machdep.c,v 1.184 1996/04/26 13:47:39 phk Exp $ */ #include "npx.h" @@ -245,6 +245,7 @@ cpu_startup(dummy) * Good {morning,afternoon,evening,night}. */ printf(version); + cpu_class = i386_cpus[cpu].cpu_class; startrtclock(); identifycpu(); printf("real memory = %d (%dK bytes)\n", ptoa(Maxmem), ptoa(Maxmem) / 1024); @@ -491,20 +492,8 @@ static void identifycpu() { printf("CPU: "); - if (cpu >= 0 - && cpu < (sizeof i386_cpus/sizeof(struct cpu_nameclass))) { - cpu_class = i386_cpus[cpu].cpu_class; - strncpy(cpu_model, i386_cpus[cpu].cpu_name, sizeof cpu_model); - } else { - printf("unknown cpu type %d\n", cpu); - panic("startup: bad cpu id"); - } + strncpy(cpu_model, i386_cpus[cpu].cpu_name, sizeof cpu_model); -#if defined(I586_CPU) || defined(I686_CPU) - if (cpu_class == CPUCLASS_586 || cpu_class == CPUCLASS_686) { - calibrate_cyclecounter(); - } -#endif #if defined(I486_CPU) || defined(I586_CPU) || defined(I686_CPU) if (!strcmp(cpu_vendor,"GenuineIntel")) { if ((cpu_id & 0xf00) > 3) { |
