Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Apr 2011 06:51:32 -0500
From:      Bret Ketchum <bcketchum@gmail.com>
To:        freebsd-drivers@freebsd.org
Subject:   Re: MSI interrupts.
Message-ID:  <BANLkTik0UuF%2BaktSWAqg-StsDbfqNKHCmw@mail.gmail.com>
In-Reply-To: <BANLkTim9WWQDjAJsHNNDRTN%2BnTXbxAonFA@mail.gmail.com>
References:  <BANLkTim9WWQDjAJsHNNDRTN%2BnTXbxAonFA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
    As an experiment I made align equal to count in apic_alloc_vectors to
mimic the way MSIX vectors are assigned and all my issue went away..

On Tue, Apr 12, 2011 at 8:16 AM, Bret Ketchum <bcketchum@gmail.com> wrote:

>
>     I've a roll-your-own driver for FreeBSD 8.x that uses MSI interrupts
> for PCI-E HBAs where one or more will be installed in a off-the-shelf amd64
> pizza box. The driver is using bus_setup_intr() and depending upon the slots
> the HBAs are install I see log messages from apic_alloc_vectors(), for
> example:
>
> Apr 12 06:44:15 mfsbsd kernel: xxxpci10: attempting to allocate 1 MSI
> vectors (16 supported)
> Apr 12 06:44:15 mfsbsd kernel: APIC: Couldn't find APIC vectors for 1 IRQs
> Apr 12 06:44:15 mfsbsd kernel: ioapic1: routing intpin 13 (PCI IRQ 37) to
> lapic 0 vector 59
>
>     Using vmstat -ia:
>
> interrupt                          total       rate
> irq37: xxxpci10                       74          0
>
>     The problem appears to be that HBA interrupts are not being delivered
> to the driver. If I swap cards around in slots I can eliminate the message
> and:
>
> Apr 12 06:44:15 mfsbsd kernel: msi: routing MSI IRQ 266 to local APIC 0
> vector 80
>
>     And interrupts appear to be delivered properly. Before I dive in, can
> anyone explain this behavior?
>
>     Thanks in advance.
>
>     Dr.
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BANLkTik0UuF%2BaktSWAqg-StsDbfqNKHCmw>