Commit acdb4d24 authored by Andy Grover's avatar Andy Grover

ACPI: Use extended IRQ resource type when setting IRQs on link devices to more

than IRQ 15 (Juan Quintela)
parent 4efd5d18
......@@ -306,6 +306,7 @@ acpi_pci_link_set (
memset(&resource, 0, sizeof(resource));
/* NOTE: PCI interrupts are always level / active_low / shared. */
if (irq <= 15) {
resource.res.id = ACPI_RSTYPE_IRQ;
resource.res.length = sizeof(struct acpi_resource);
resource.res.data.irq.edge_level = ACPI_LEVEL_SENSITIVE;
......@@ -314,6 +315,19 @@ acpi_pci_link_set (
resource.res.data.irq.number_of_interrupts = 1;
resource.res.data.irq.interrupts[0] = irq;
resource.end.id = ACPI_RSTYPE_END_TAG;
}
else {
resource.res.id = ACPI_RSTYPE_EXT_IRQ;
resource.res.length = sizeof(struct acpi_resource);
resource.res.data.extended_irq.producer_consumer = ACPI_CONSUMER;
resource.res.data.extended_irq.edge_level = ACPI_LEVEL_SENSITIVE;
resource.res.data.extended_irq.active_high_low = ACPI_ACTIVE_LOW;
resource.res.data.extended_irq.shared_exclusive = ACPI_SHARED;
resource.res.data.extended_irq.number_of_interrupts = 1;
resource.res.data.extended_irq.interrupts[0] = irq;
/* ignore resource_source, it's optional */
resource.end.id = ACPI_RSTYPE_END_TAG;
}
status = acpi_set_current_resources(link->handle, &buffer);
if (ACPI_FAILURE(status)) {
......
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