Commit 32f82c01 authored by Len Brown's avatar Len Brown Committed by Len Brown

ACPI irq->gsi naming (Bjorn Helgaas)

parent fb715e7e
...@@ -63,7 +63,7 @@ int acpi_in_debugger; ...@@ -63,7 +63,7 @@ int acpi_in_debugger;
extern char line_buf[80]; extern char line_buf[80];
#endif /*ENABLE_DEBUGGER*/ #endif /*ENABLE_DEBUGGER*/
static int acpi_irq_irq; static unsigned int acpi_irq_irq;
static OSD_HANDLER acpi_irq_handler; static OSD_HANDLER acpi_irq_handler;
static void *acpi_irq_context; static void *acpi_irq_context;
...@@ -241,23 +241,22 @@ acpi_irq(int irq, void *dev_id, struct pt_regs *regs) ...@@ -241,23 +241,22 @@ acpi_irq(int irq, void *dev_id, struct pt_regs *regs)
} }
acpi_status acpi_status
acpi_os_install_interrupt_handler(u32 irq, OSD_HANDLER handler, void *context) acpi_os_install_interrupt_handler(u32 gsi, OSD_HANDLER handler, void *context)
{ {
unsigned int irq;
/* /*
* Ignore the irq from the core, and use the value in our copy of the * Ignore the GSI from the core, and use the value in our copy of the
* FADT. It may not be the same if an interrupt source override exists * FADT. It may not be the same if an interrupt source override exists
* for the SCI. * for the SCI.
*/ */
irq = acpi_fadt.sci_int; gsi = acpi_fadt.sci_int;
if (acpi_gsi_to_irq(gsi, &irq) < 0) {
#if defined(CONFIG_IA64) || defined(CONFIG_PCI_USE_VECTOR) printk(KERN_ERR PREFIX "SCI (ACPI GSI %d) not registered\n",
irq = acpi_irq_to_vector(irq); gsi);
if (irq < 0) {
printk(KERN_ERR PREFIX "SCI (ACPI interrupt %d) not registered\n",
acpi_fadt.sci_int);
return AE_OK; return AE_OK;
} }
#endif
acpi_irq_handler = handler; acpi_irq_handler = handler;
acpi_irq_context = context; acpi_irq_context = context;
if (request_irq(irq, acpi_irq, SA_SHIRQ, "acpi", acpi_irq)) { if (request_irq(irq, acpi_irq, SA_SHIRQ, "acpi", acpi_irq)) {
...@@ -273,9 +272,6 @@ acpi_status ...@@ -273,9 +272,6 @@ acpi_status
acpi_os_remove_interrupt_handler(u32 irq, OSD_HANDLER handler) acpi_os_remove_interrupt_handler(u32 irq, OSD_HANDLER handler)
{ {
if (irq) { if (irq) {
#if defined(CONFIG_IA64) || defined(CONFIG_PCI_USE_VECTOR)
irq = acpi_irq_to_vector(irq);
#endif
free_irq(irq, acpi_irq); free_irq(irq, acpi_irq);
acpi_irq_handler = NULL; acpi_irq_handler = NULL;
acpi_irq_irq = 0; acpi_irq_irq = 0;
......
...@@ -188,7 +188,7 @@ acpi_os_get_physical_address ( ...@@ -188,7 +188,7 @@ acpi_os_get_physical_address (
acpi_status acpi_status
acpi_os_install_interrupt_handler ( acpi_os_install_interrupt_handler (
u32 interrupt_number, u32 gsi,
OSD_HANDLER service_routine, OSD_HANDLER service_routine,
void *context); void *context);
......
...@@ -438,6 +438,7 @@ struct pci_dev; ...@@ -438,6 +438,7 @@ struct pci_dev;
int acpi_pci_irq_enable (struct pci_dev *dev); int acpi_pci_irq_enable (struct pci_dev *dev);
int acpi_pci_irq_init (void); int acpi_pci_irq_init (void);
int acpi_gsi_to_irq (u32 gsi, unsigned int *irq);
struct acpi_pci_driver { struct acpi_pci_driver {
struct acpi_pci_driver *next; struct acpi_pci_driver *next;
......
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