Lines Matching +full:interrupt +full:- +full:based
6 * Copyright (C) 2005-2009, 2010 Cavium Networks
12 #include <linux/interrupt.h>
15 #include <asm/octeon/cvmx-npi-defs.h>
16 #include <asm/octeon/cvmx-pci-defs.h>
17 #include <asm/octeon/cvmx-npei-defs.h>
18 #include <asm/octeon/cvmx-sli-defs.h>
19 #include <asm/octeon/cvmx-pexp-defs.h>
20 #include <asm/octeon/pci-octeon.h>
23 * Each bit in msi_free_irq_bitmask represents a MSI interrupt that is
49 * arch_setup_msi_irq() - setup MSI IRQs for a device
54 * legacy INT A-D. This routine will allocate multiple interrupts
59 * Return: %0 on success, non-%0 on error.
72 if (desc->pci.msi_attrib.is_msix) in arch_setup_msi_irq()
73 return -EINVAL; in arch_setup_msi_irq()
80 pci_read_config_word(dev, dev->msi_cap + PCI_MSI_FLAGS, &control); in arch_setup_msi_irq()
110 * The IRQs have to be aligned on a power of two based on the in arch_setup_msi_irq()
116 search_mask = (1 << irq_step) - 1; in arch_setup_msi_irq()
120 * bits. This represents an MSI interrupt number that isn't in in arch_setup_msi_irq()
144 panic("arch_setup_msi_irq: Unable to find a free MSI interrupt"); in arch_setup_msi_irq()
153 /* When not using big bar, Bar 0 is based at 128MB */ in arch_setup_msi_irq()
159 /* When using big bar, Bar 0 is based at 0 */ in arch_setup_msi_irq()
164 /* When using PCIe, Bar 0 is based at 0 */ in arch_setup_msi_irq()
170 /* When using PCIe2, Bar 0 is based at 0 */ in arch_setup_msi_irq()
177 msg.data = irq - OCTEON_IRQ_MSI_BIT0; in arch_setup_msi_irq()
182 pci_write_config_word(dev, dev->msi_cap + PCI_MSI_FLAGS, control); in arch_setup_msi_irq()
190 * arch_teardown_msi_irq() - release MSI IRQs for a device
206 "MSI interrupt (%d)", irq); in arch_teardown_msi_irq()
208 irq -= OCTEON_IRQ_MSI_BIT0; in arch_teardown_msi_irq()
224 bitmask = (1 << number_irqs) - 1; in arch_teardown_msi_irq()
229 "interrupt (%d) not in use", irq); in arch_teardown_msi_irq()
247 int msi_number = data->irq - OCTEON_IRQ_MSI_BIT0; in octeon_irq_msi_enable_pcie()
263 int msi_number = data->irq - OCTEON_IRQ_MSI_BIT0; in octeon_irq_msi_disable_pcie()
304 * Called by the interrupt handling code when an MSI interrupt
314 bit--; in __octeon_msi_do_interrupt()
333 * Create octeon_msi_interrupt{0-3} function body
341 * Initializes the MSI interrupt handling code