Re: Fatal trap 19: non-maskable interrupt trap while in kernel m

看板DFBSD_kernel作者時間21年前 (2004/11/06 05:01), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串8/24 (看更多)
I think what is going on is that the probe code is unmasking the transmit and receive channel interrupts in order to probe the number of available channels, without first clearing any 'garbage' status pending on those channel(s). Such status might occur from, e.g. the BIOS playing with the firewire controller before booting the system. This could result in an immediate interrupt which crashes the machine before the driver has had a chance to program the interrupt vector. If that is what is going on, then this patch should fix the problem. But it needs to be tested. It doesn't crash my test box but we need to find out if it fixes the reported problem. Gabor, from your latest email it looks like neither NetBSD nor OpenBSD are running a firewire driver, so it is possible that they also have the bug but it isn't being hit. If you have the ability to download an ISO and burn it onto a CD to boot/test the fix I could generate an ISO image for you to try with this patch. It may or may not work but it is worth a shot. -Matt Index: fwohci.c =================================================================== RCS file: /cvs/src/sys/bus/firewire/fwohci.c,v retrieving revision 1.8 diff -u -r1.8 fwohci.c --- fwohci.c 2 Jun 2004 14:42:48 -0000 1.8 +++ fwohci.c 5 Nov 2004 20:11:34 -0000 @@ -613,14 +613,17 @@ } /* Available Isochrounous DMA channel probe */ + OWRITE(sc, OHCI_IT_STATCLR, 0xffffffff); + OWRITE(sc, OHCI_IR_STATCLR, 0xffffffff); OWRITE(sc, OHCI_IT_MASK, 0xffffffff); OWRITE(sc, OHCI_IR_MASK, 0xffffffff); reg = OREAD(sc, OHCI_IT_MASK) & OREAD(sc, OHCI_IR_MASK); OWRITE(sc, OHCI_IT_MASKCLR, 0xffffffff); OWRITE(sc, OHCI_IR_MASKCLR, 0xffffffff); - for (i = 0; i < 0x20; i++) + for (i = 0; i < 0x20; i++) { if ((reg & (1 << i)) == 0) break; + } sc->fc.nisodma = i; device_printf(dev, "No. of Isochronous channel is %d.\n", i); if (i == 0)
文章代碼(AID): #11Y-eX00 (DFBSD_kernel)
討論串 (同標題文章)
完整討論串 (本文為第 8 之 24 篇):
文章代碼(AID): #11Y-eX00 (DFBSD_kernel)