NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

port-i386/49104: panic in cpu_init() on real i486 processor



>Number:         49104
>Category:       port-i386
>Synopsis:       panic in cpu_init on real i486 processor
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    port-i386-maintainer
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Aug 12 13:55:00 +0000 2014
>Originator:     Jarle Greipsland
>Release:        NetBSD 6.99.47 (source from 2014-07-22)
>Organization:
        
>Environment:
        
        
System: NetBSD darling.urc.uninett.no 6.99.28 NetBSD 6.99.28 (DARLING) #0: Thu 
Jan 2 20:17:15 CET 2014 
jarle%darling.urc.uninett.no@localhost:/usr/obj/sys/arch/i386/compile/DARLING 
i386
Architecture: i386
Machine: i386
>Description:

I tried to boot a 6.99.47 kernel on my trusty old i486 system, but the
kernel paniced early in the autoconf process.

The kernel messages (copied by hand):
...
total memory = 127 MB
avail memory = 121 MB
mainbus0 (root)
cpu0 at mainbus0fatal privileged instruction fault in supervisor mode
trap type 0 code 0 eip c012e570 cs c0490008 eflags 10282 cr2 0 ilevel 8 esp 
c012c543
curlwp 0xc04584c0 pid 0 lid 1 lowest kstack 0xc05022c0
kernel: supervisor trap privileged instruction fault, code=0
stopped in pid 0.1 (system) at netbsd:rcr4: movl %cr4, %eax

A backtrace shows the call stack as (partial):
rcr4 <- cpu_init <- cpu_attach <- config_attach <- "more autoconf goop"

I believe the problem to be the introduction of unconditional calls to
rcr4() in cpu_init() in revision 1.110 of sys/arch/x86/x86/cpu.c.  The
Intel 486 series of processors do not have a CR4 register, and thus
the attempt to read said register causes the processor trap and
subsequent kernel panic.

>How-To-Repeat:
Try to run a current kernel on a real i486 series processor.

>Fix:
        



Home | Main Index | Thread Index | Old Index