From nobody@FreeBSD.org  Thu Feb  8 14:02:07 2001
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21])
	by hub.freebsd.org (Postfix) with ESMTP id 0751537B699
	for <freebsd-gnats-submit@FreeBSD.org>; Thu,  8 Feb 2001 14:02:07 -0800 (PST)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.11.1/8.11.1) id f18M26j26563;
	Thu, 8 Feb 2001 14:02:06 -0800 (PST)
	(envelope-from nobody)
Message-Id: <200102082202.f18M26j26563@freefall.freebsd.org>
Date: Thu, 8 Feb 2001 14:02:06 -0800 (PST)
From: pscott@cue.net
To: freebsd-gnats-submit@FreeBSD.org
Subject: Fatal trap 12 in kernel mode (swapper) on Compaq Presario
X-Send-Pr-Version: www-1.0

>Number:         24958
>Category:       kern
>Synopsis:       Fatal trap 12 in kernel mode (swapper) on Compaq Presario
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Feb 08 14:10:01 PST 2001
>Closed-Date:    Fri Feb 9 10:28:12 PST 2001
>Last-Modified:  Sat Feb 10 10:00:01 PST 2001
>Originator:     Paul A. Scott
>Release:        4.2-CURRENT
>Organization:
Cue Corporation
>Environment:
na
>Description:
4.2-CURRENT installs without a hitch on Compaq Presario. Even X11 
installs fine with the NVidia TNT2 display adapter. However, after
completing the installation, the machine will not boot the kernel.
This is the GENERIC kernel as delivered on the CDROM.

Receives the following:

Fatal trap 12: page fault while in kernel mode
fault virtual address      = 0x1
fault code                 = supervisor read, page not present
instruction pointer        = 0x8:0xc019fe83
stack pointer              = 0x10:0xc044aec0
frame pointer              = 0x10:0xc044aedc
code segment               = base 0x0, limit 0xfffff, type 0x1b
                           = dpl 0, pres 1, def32 1, gran 1
processor eflags           = interrupt enabled, resume, iopl = 0
current process            = 0 (swapper)
interrupt mask             = net tty bio cam
trap number                = 12
panic: page fault
>How-To-Repeat:
boot from disk after install.
>Fix:


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: des 
State-Changed-When: Fri Feb 9 10:28:12 PST 2001 
State-Changed-Why:  
Try the mailing lists first. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=24958 

From: "Paul A. Scott" <pscott@the-frontier.org>
To: <freebsd-gnats-submit@FreeBSD.org>, <pscott@cue.net>
Cc:  
Subject: Re: kern/24958: Fatal trap 12 in kernel mode (swapper) on Compaq Presario
Date: Fri, 9 Feb 2001 23:08:51 -0800

 More information:
 
 #nm -n kernel | grep c019f
 ...
 c019f7a0 t msginit
 c019f90c T msgsys
 c019f938 t msg_freehdr
 c019f9e0 T msgctl
 c019fbc0 T msgget
 c019fd60 T msgsnd  <----- Here!
 
 #nm --size-sort kernel | egrep "(msgget)|(msgsnd)"
 000001a0 T msgget
 00000400 T msgsnd  <----- Definitely long enough!
 
 #gdb /sys/compile/GENERIC/sysv_msg.o
 (gdb) disas msgsnd
 Dump of assembler code for function msgsnd:
 0x5c0 <msgsnd>: push   %ebp
 0x5c1 <msgsnd+1>:       mov    %esp,%ebp
 0x5c3 <msgsnd+3>:       sub    $0x18,%esp
 0x5c6 <msgsnd+6>:       push   %edi
 0x5c7 <msgsnd+7>:       push   %esi
 0x5c8 <msgsnd+8>:       push   %ebx
 0x5c9 <msgsnd+9>:       mov    0xc(%ebp),%ecx
 ...
 0x6c6 <msgsnd+262>:     call   0x6c7 <msgsnd+263>
 0x6cb <msgsnd+267>:     mov    %eax,0xfffffff0(%ebp)
 0x6ce <msgsnd+270>:     add    $0x10,%esp
 0x6d1 <msgsnd+273>:     test   %ebx,%ebx
 0x6d3 <msgsnd+275>:     je     0x6db <msgsnd+283>
 0x6d5 <msgsnd+277>:     andw   $0xfdff,0x8(%esi)
 0x6db <msgsnd+283>:     cmpl   $0x0,0xfffffff0(%ebp)
 0x6df <msgsnd+287>:     jne    0x94c <msgsnd+908>
 0x6e5 <msgsnd+293>:     cmpl   $0x0,0x20(%esi)     < --- Doesn't match dump!
 0x6e9 <msgsnd+297>:     jne    0x654 <msgsnd+148>
 0x6ef <msgsnd+303>:     mov    $0x52,%eax
 0x6f4 <msgsnd+308>:     jmp    0x9b7 <msgsnd+1015>
 
 A little math:
 
 ( ip = 0xc019fe83 ) - ( msgsnd = 0xc019fd60 ) = 0x0123
 ( msgsnd = 0x05c0 ) + ( 0x0123 ) = 0x06e3  < --- Doesn't match code!
 
 Could be a wild interrupt vector. Can't check for conflicts because
 the userconfig (boot -c) won't work either (pr kern/24957). Will attempt
 to get userconfig to work on console attached to serial port (boot -h).
 More to come . . .
 
 Paul
 
 

From: "Paul A. Scott" <pscott@cue.net>
To: "Paul A. Scott" <pscott@the-frontier.org>,
	<freebsd-gnats-submit@FreeBSD.org>, <pscott@cue.net>
Cc:  
Subject: RE: Re: kern/24958: Fatal trap 12 in kernel mode (swapper) on Compaq Presario
Date: Sat, 10 Feb 2001 09:56:15 -0800

 > "Paul A. Scott" <pscott@the-frontier.org> writes:
 >>  #gdb /sys/compile/GENERIC/sysv_msg.o
 
 >This is meaningless unless the kernel that crashed includes this
 >precise object file.
 
 You are correct. But, I compiled and linked the GENERIC kernel to get
 sysv_msg.o and it matches exactly in size the kernel on the CDROM. All the
 offsets in sysv_msg.o also match the offsets in the kernel. It's a good bet
 they're the same. I'll get further into this when I'm back to work on
 Monday.
 
 >This still belongs on the lists, not in a PR.
 
 Why? Seriously, I'd like to know what criteria you use for defining a
 "problem." Let's look at this rationally. I have a brand-new, current
 generation, Compaq Presario right out of the box. With the help of V-com's
 System Commander 2000 boot manager, I installed Windows Me, and Windows/2000
 Server on the box without any problems. Both Microsoft OS's run fine.
 However, after installing FreeBSD 4.2-RELEASE on the box--which actually
 installed without any problems--I boot the kernel and after it probes ppi0
 it panics. Furthermore, I can't even use the userconfig utility because the
 syscons driver
 can't even write to the screen in an age-old standard way.
 
 Lemme see, MS Windows runs, FreeBSD GENERIC doesn't. All devices are
 standard ATA, PCI, and PNP; no ISA or legacy hardware.
 
   * kernel panics after probing ppi0
   * userconfig scrambles screen
 
 Wouldn't you call these problems?
 
 I spent 4 hours searching your precious mailing lists archives. Couldn't
 find anything even close to kern/24957 and kern 24958.
 
 You should know that I've been an avid FreeBSD user--and a minor
 hacker--since the first FreeBSD 1.0 CDROM was delivered. I have a Walnut
 Creek subscription and have installed and used in business--and
 personally--nearly every release through 4.2-RELEASE. In that time, I've
 reported a half-dozen pr reports, all of them received courteous responses,
 and most were fixed in the next release. At one time, I submitted a patch to
 the matcd driver, which made it into the next release. In conf/3354 I
 reported a problem with the syscons driver, which is very similar to
 kern/24957 I'm now reporting, and was e-mailed a fix by a very courteous
 Kazutaka san. Over the past 8 years, I've become quite familiar with
 FreeBSD.
 
 So, with that background, please explain why this isn't a problem, and why
 it doesn't belong in gnats.
 
 Paul
 
 
>Unformatted:
