Boot hangs on ips0: resetting adapter, this may take up to 5 minutes

Oleg Sharoiko os at rsu.ru
Mon Mar 27 20:10:34 UTC 2006


On Fri, 24 Mar 2006, John Baldwin wrote:

JB>> I've found an interesting thread on netbsd mailing list. 
JB>> http://mail-index.netbsd.org/port-amd64/2006/03/
JB>> With subject "Re: Bug in x86 ioapic interrupt code for devices with shared 
JB>> interrupts?". May this relate to my problems?
JB>Well, there is one possibly interesting patch for bge in there, (the
JB>one from the linux driver) but I'm not sure if it would really help or
JB>not.

John, can it be possible that interrupts are incorrectly delivered to 
bge_intr? Is it possible that these interrupts are generated by some 
different device?

I've added simple debug out to the bge_intr.

This is from the normal interrupts:

statusword: 0001
bge0: BGE_PCI_PCISTATE: 1210

And this is from interrupt storm:

bge0: statusword: 0000
bge0: BGE_PCI_PCISTATE: 1212

According to linux driver bit 0x02 (called PCISTATE_INT_NOT_ACTIVE) of 
BGE_PCI_PCISTATE register means that device is not generating interrups. 
Here is an extract from linux driver (distributed by broadcom - 
manufacturer of bge cards):

        /* In INTx mode, it is possible for the interrupt to arrive at
         * the CPU before the status block posted prior to the interrupt.
         * Reading the PCI State register will confirm whether the
         * interrupt is ours and will flush the status block.
         */
	if ((sblk->status & SD_STATUS_UPDATED) ||
	    !(tr32(TG3PCI_PCISTATE) & PCISTATE_INT_NOT_ACTIVE)) {
		...
        } else {        /* shared interrupt */
		handled = 0;
        }
out:
        return IRQ_RETVAL(handled);


As I understand in Linux when driver interrupt routine returns 0 it means 
that this interrupt was not for this driver and kernel should handle this 
case. I don't know how to implement this in FreeBSD.

-- 
Oleg Sharoiko.
Software and Network Engineer
Computer Center of Rostov State University.


More information about the freebsd-scsi mailing list