Commit d1409597 authored by Christoph Hellwig's avatar Christoph Hellwig

[PATCH] ia64: simplify SN2 interrupt allocation

Same issues as the dma mapping code, but as SN2 interrupt handling is
totally static and all irqs are allocated on bootup an never freed it's
not a speed issue.

I really wonder what someone has to smoke to call a that expensive
dispatcher just to cast the data structure back to the lowlevel one
directly afterwards...
parent 4861cee9
...@@ -426,7 +426,7 @@ sn_pci_fixup(int arg) ...@@ -426,7 +426,7 @@ sn_pci_fixup(int arg)
struct pci_dev *device_dev = NULL; struct pci_dev *device_dev = NULL;
struct sn_widget_sysdata *widget_sysdata; struct sn_widget_sysdata *widget_sysdata;
struct sn_device_sysdata *device_sysdata; struct sn_device_sysdata *device_sysdata;
pciio_intr_t intr_handle; pcibr_intr_t intr_handle;
int cpuid; int cpuid;
vertex_hdl_t device_vertex; vertex_hdl_t device_vertex;
pciio_intr_line_t lines; pciio_intr_line_t lines;
...@@ -549,17 +549,17 @@ sn_pci_fixup(int arg) ...@@ -549,17 +549,17 @@ sn_pci_fixup(int arg)
(unsigned char *)&lines); (unsigned char *)&lines);
irqpdaindr->curr = device_dev; irqpdaindr->curr = device_dev;
intr_handle = pciio_intr_alloc(device_vertex, NULL, lines, device_vertex); intr_handle = pcibr_intr_alloc(device_vertex, NULL, lines, device_vertex);
irq = intr_handle->pi_irq; irq = intr_handle->bi_irq;
irqpdaindr->device_dev[irq] = device_dev; irqpdaindr->device_dev[irq] = device_dev;
cpuid = intr_handle->pi_cpu; cpuid = intr_handle->bi_cpu;
pciio_intr_connect(intr_handle, (intr_func_t)0, (intr_arg_t)0); pcibr_intr_connect(intr_handle, (intr_func_t)0, (intr_arg_t)0);
device_dev->irq = irq; device_dev->irq = irq;
register_pcibr_intr(irq, (pcibr_intr_t)intr_handle); register_pcibr_intr(irq, intr_handle);
for (idx = 0; idx < PCI_ROM_RESOURCE; idx++) { for (idx = 0; idx < PCI_ROM_RESOURCE; idx++) {
int ibits = ((pcibr_intr_t)intr_handle)->bi_ibits; int ibits = intr_handle->bi_ibits;
int i; int i;
size = device_dev->resource[idx].end - size = device_dev->resource[idx].end -
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment