Commit 1014e334 authored by Pat Gefre's avatar Pat Gefre Committed by David Mosberger

[PATCH] ia64: SN2 fix

Move HW interrupt register init. to the proper place
and don't force an interrupt if the IRQ is disabled
or in progress.
parent b4c39b30
...@@ -529,7 +529,11 @@ hub_dmaaddr_drain( vertex_hdl_t vhdl, ...@@ -529,7 +529,11 @@ hub_dmaaddr_drain( vertex_hdl_t vhdl,
void void
hub_provider_startup(vertex_hdl_t hubv) hub_provider_startup(vertex_hdl_t hubv)
{ {
hubinfo_t hubinfo;
hubinfo_get(hubv, &hubinfo);
hub_pio_init(hubv); hub_pio_init(hubv);
intr_init_vecblk(nasid_to_cnodeid(hubinfo->h_nasid));
} }
/* /*
......
...@@ -813,11 +813,6 @@ sn_pci_init (void) ...@@ -813,11 +813,6 @@ sn_pci_init (void)
*/ */
sgi_master_io_infr_init(); sgi_master_io_infr_init();
for (cnode = 0; cnode < numnodes; cnode++) {
extern void intr_init_vecblk(cnodeid_t);
intr_init_vecblk(cnode);
}
sn_init_cpei_timer(); sn_init_cpei_timer();
#ifdef CONFIG_PROC_FS #ifdef CONFIG_PROC_FS
......
...@@ -40,6 +40,7 @@ ...@@ -40,6 +40,7 @@
static void force_interrupt(int irq); static void force_interrupt(int irq);
extern void pcibr_force_interrupt(pcibr_intr_t intr); extern void pcibr_force_interrupt(pcibr_intr_t intr);
extern int sn_force_interrupt_flag; extern int sn_force_interrupt_flag;
struct irq_desc * sn_irq_desc(unsigned int irq);
struct sn_intr_list_t { struct sn_intr_list_t {
struct sn_intr_list_t *next; struct sn_intr_list_t *next;
...@@ -101,6 +102,8 @@ sn_end_irq(unsigned int irq) ...@@ -101,6 +102,8 @@ sn_end_irq(unsigned int irq)
int nasid; int nasid;
int ivec; int ivec;
unsigned long event_occurred; unsigned long event_occurred;
irq_desc_t *desc = sn_irq_desc(irq);
unsigned int status = desc->status;
ivec = irq & 0xff; ivec = irq & 0xff;
if (ivec == SGI_UART_VECTOR) { if (ivec == SGI_UART_VECTOR) {
...@@ -115,7 +118,8 @@ sn_end_irq(unsigned int irq) ...@@ -115,7 +118,8 @@ sn_end_irq(unsigned int irq)
} }
__clear_bit(ivec, (volatile void *)pda->sn_in_service_ivecs); __clear_bit(ivec, (volatile void *)pda->sn_in_service_ivecs);
if (sn_force_interrupt_flag) if (sn_force_interrupt_flag)
force_interrupt(irq); if (!(status & (IRQ_DISABLED | IRQ_INPROGRESS)))
force_interrupt(irq);
} }
static void static void
......
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