Subject: Re: kern/32191: integer divide fault trap caused by the ata driver
To: None <gnats-bugs@NetBSD.org>
From: Manuel Bouyer <bouyer@antioche.eu.org>
List: netbsd-bugs
Date: 11/29/2005 21:18:41
On Tue, Nov 29, 2005 at 03:02:01PM +0000, matthias.christian@tiscali.de wrote:
> >Number:         32191
> >Category:       kern
> >Synopsis:       integer divide fault trap caused by the ata driver
> >Confidential:   no
> >Severity:       serious
> >Priority:       high
> >Responsible:    kern-bug-people
> >State:          open
> >Class:          sw-bug
> >Submitter-Id:   net
> >Arrival-Date:   Tue Nov 29 15:02:00 +0000 2005
> >Originator:     Matthias-Christian Ott
> >Release:        netbsd-3
> >Organization:
> >Environment:
> >Description:
> I get an "integer divide fault trap" caused by the ata driver when booting my computer [0] [1]. See the screenshots for more details.
> 
> [0] http://metawire.org/~matthias-christian-ott/pub/netbsd/netbsd-3/integer-divide-fault-trap-0.jpg
> [1] http://metawire.org/~matthias-christian-ott/pub/netbsd/netbsd-3/integer-divide-fault-trap-1.jpg

Basically wdcprobe1 calls i8254_delay which calls gettick.
The fault is at gettick+0x1c. From gdb this would be write_eflags(ef).
I can't see how this can cause a integer divide fault trap.

Even in i8254_delay I can't see how we could get a divide by 0 here.

-- 
Manuel Bouyer <bouyer@antioche.eu.org>
     NetBSD: 26 ans d'experience feront toujours la difference
--