Commit 749e32b6 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] ppc64: iseries IRQ fix

From: Stephen Rothwell <sfr@canb.auug.org.au>

This patch lets 2.6.3-rc4 build and boot on an PPC64 iSeries box (at least
for my configuration).  The veth.o bit in the networking Makefile got there
by accident and should be removed anyway ...

There is more to make it work properly (note the "Temporary hack"), but
this gets us closer.
parent 7f4afd7a
...@@ -57,6 +57,7 @@ static hw_irq_controller iSeries_IRQ_handler = { ...@@ -57,6 +57,7 @@ static hw_irq_controller iSeries_IRQ_handler = {
void iSeries_init_irq_desc(irq_desc_t *desc) void iSeries_init_irq_desc(irq_desc_t *desc)
{ {
desc->handler = &iSeries_IRQ_handler;
} }
/* This is called by init_IRQ. set in ppc_md.init_IRQ by iSeries_setup.c */ /* This is called by init_IRQ. set in ppc_md.init_IRQ by iSeries_setup.c */
...@@ -87,22 +88,6 @@ int __init iSeries_allocate_IRQ(HvBusNumber busNumber, ...@@ -87,22 +88,6 @@ int __init iSeries_allocate_IRQ(HvBusNumber busNumber,
#define IRQ_TO_IDSEL(irq) (((((irq) - 1) >> 3) & 7) + 1) #define IRQ_TO_IDSEL(irq) (((((irq) - 1) >> 3) & 7) + 1)
#define IRQ_TO_FUNC(irq) (((irq) - 1) & 7) #define IRQ_TO_FUNC(irq) (((irq) - 1) & 7)
/*
* This is called out of iSeries_scan_slot to assign the EADS slot
* to its IRQ number
*/
int __init iSeries_assign_IRQ(int irq, HvBusNumber busNumber,
HvSubBusNumber subBusNumber, HvAgentId deviceId)
{
irq_desc_t *desc = get_real_irq_desc(irq);
if (desc == NULL)
return -1;
desc->handler = &iSeries_IRQ_handler;
return 0;
}
/* This is called by iSeries_activate_IRQs */ /* This is called by iSeries_activate_IRQs */
static unsigned int iSeries_startup_IRQ(unsigned int irq) static unsigned int iSeries_startup_IRQ(unsigned int irq)
{ {
...@@ -124,6 +109,11 @@ static unsigned int iSeries_startup_IRQ(unsigned int irq) ...@@ -124,6 +109,11 @@ static unsigned int iSeries_startup_IRQ(unsigned int irq)
return 0; return 0;
} }
/*
* Temporary hack
*/
#define get_irq_desc(irq) &irq_desc[(irq)]
/* /*
* This is called out of iSeries_fixup to activate interrupt * This is called out of iSeries_fixup to activate interrupt
* generation for usable slots * generation for usable slots
......
...@@ -406,7 +406,6 @@ static int iSeries_Scan_Bridge_Slot(HvBusNumber Bus, ...@@ -406,7 +406,6 @@ static int iSeries_Scan_Bridge_Slot(HvBusNumber Bus,
/* iSeries_allocate_IRQ.: 0x18.00.12(0xA3) */ /* iSeries_allocate_IRQ.: 0x18.00.12(0xA3) */
Irq = iSeries_allocate_IRQ(Bus, 0, EADsIdSel); Irq = iSeries_allocate_IRQ(Bus, 0, EADsIdSel);
iSeries_assign_IRQ(Irq, Bus, 0, EADsIdSel);
PPCDBG(PPCDBG_BUSWALK, PPCDBG(PPCDBG_BUSWALK,
"PCI:- allocate and assign IRQ 0x%02X.%02X.%02X = 0x%02X\n", "PCI:- allocate and assign IRQ 0x%02X.%02X.%02X = 0x%02X\n",
Bus, 0, EADsIdSel, Irq); Bus, 0, EADsIdSel, Irq);
......
...@@ -315,7 +315,6 @@ void __init iSeries_init_early(void) ...@@ -315,7 +315,6 @@ void __init iSeries_init_early(void)
ppc_md.setup_residual = iSeries_setup_residual; ppc_md.setup_residual = iSeries_setup_residual;
ppc_md.get_cpuinfo = iSeries_get_cpuinfo; ppc_md.get_cpuinfo = iSeries_get_cpuinfo;
ppc_md.init_IRQ = iSeries_init_IRQ; ppc_md.init_IRQ = iSeries_init_IRQ;
ppc_md.init_irq_desc = iSeries_init_irq_desc;
ppc_md.get_irq = iSeries_get_irq; ppc_md.get_irq = iSeries_get_irq;
ppc_md.init = NULL; ppc_md.init = NULL;
......
...@@ -45,7 +45,6 @@ obj-$(CONFIG_SIS190) += sis190.o ...@@ -45,7 +45,6 @@ obj-$(CONFIG_SIS190) += sis190.o
obj-$(CONFIG_SIS900) += sis900.o obj-$(CONFIG_SIS900) += sis900.o
obj-$(CONFIG_YELLOWFIN) += yellowfin.o obj-$(CONFIG_YELLOWFIN) += yellowfin.o
obj-$(CONFIG_ACENIC) += acenic.o obj-$(CONFIG_ACENIC) += acenic.o
obj-$(CONFIG_VETH) += veth.o
obj-$(CONFIG_NATSEMI) += natsemi.o obj-$(CONFIG_NATSEMI) += natsemi.o
obj-$(CONFIG_NS83820) += ns83820.o obj-$(CONFIG_NS83820) += ns83820.o
obj-$(CONFIG_STNIC) += stnic.o 8390.o obj-$(CONFIG_STNIC) += stnic.o 8390.o
......
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