From b008b8d7092053fc1f036cfc54dc11740cc424ed Mon Sep 17 00:00:00 2001 From: Matthieu Castet Date: Fri, 25 Mar 2005 12:03:15 -0500 Subject: [ACPI] PNPACPI parse error http://bugzilla.kernel.org/show_bug.cgi?id=3912 Written-by: matthieu castet Acked-by: Shaohua Li Signed-off-by: Len Brown --- drivers/pnp/pnpacpi/rsparser.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'drivers/pnp') diff --git a/drivers/pnp/pnpacpi/rsparser.c b/drivers/pnp/pnpacpi/rsparser.c index dd61e09029b..ae3819ad7cf 100644 --- a/drivers/pnp/pnpacpi/rsparser.c +++ b/drivers/pnp/pnpacpi/rsparser.c @@ -444,6 +444,7 @@ pnpacpi_parse_fixed_mem32_option(struct pnp_option *option, struct acpipnp_parse_option_s { struct pnp_option *option; + struct pnp_option *option_independent; struct pnp_dev *dev; }; @@ -507,7 +508,14 @@ static acpi_status pnpacpi_option_resource(struct acpi_resource *res, parse_data->option = option; break; case ACPI_RSTYPE_END_DPF: - return AE_CTRL_TERMINATE; + /*only one EndDependentFn is allowed*/ + if (!parse_data->option_independent) { + pnp_warn("PnPACPI: more than one EndDependentFn"); + return AE_ERROR; + } + parse_data->option = parse_data->option_independent; + parse_data->option_independent = NULL; + break; default: pnp_warn("PnPACPI: unknown resource type %d", res->id); return AE_ERROR; @@ -525,6 +533,7 @@ acpi_status pnpacpi_parse_resource_option_data(acpi_handle handle, parse_data.option = pnp_register_independent_option(dev); if (!parse_data.option) return AE_ERROR; + parse_data.option_independent = parse_data.option; parse_data.dev = dev; status = acpi_walk_resources(handle, METHOD_NAME__PRS, pnpacpi_option_resource, &parse_data); -- cgit v1.2.3 From c9c3e457de24cca2ca688fa397d93a241f472048 Mon Sep 17 00:00:00 2001 From: David Shaohua Li Date: Fri, 1 Apr 2005 00:07:31 -0500 Subject: [ACPI] PNPACPI vs sound IRQ http://bugme.osdl.org/show_bug.cgi?id=4016 Written-by: David Shaohua Li Acked-by: Adam Belay Signed-off-by: Len Brown --- drivers/pnp/pnpacpi/rsparser.c | 4 ++-- drivers/pnp/pnpbios/rsparser.c | 2 +- drivers/pnp/resource.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'drivers/pnp') diff --git a/drivers/pnp/pnpacpi/rsparser.c b/drivers/pnp/pnpacpi/rsparser.c index ae3819ad7cf..75575f6c349 100644 --- a/drivers/pnp/pnpacpi/rsparser.c +++ b/drivers/pnp/pnpacpi/rsparser.c @@ -160,7 +160,7 @@ static acpi_status pnpacpi_allocated_resource(struct acpi_resource *res, acpi_register_gsi(res->data.irq.interrupts[0], res->data.irq.edge_level, res->data.irq.active_high_low)); - pcibios_penalize_isa_irq(res->data.irq.interrupts[0]); + pcibios_penalize_isa_irq(res->data.irq.interrupts[0], 1); } break; @@ -171,7 +171,7 @@ static acpi_status pnpacpi_allocated_resource(struct acpi_resource *res, acpi_register_gsi(res->data.extended_irq.interrupts[0], res->data.extended_irq.edge_level, res->data.extended_irq.active_high_low)); - pcibios_penalize_isa_irq(res->data.extended_irq.interrupts[0]); + pcibios_penalize_isa_irq(res->data.extended_irq.interrupts[0], 1); } break; case ACPI_RSTYPE_DMA: diff --git a/drivers/pnp/pnpbios/rsparser.c b/drivers/pnp/pnpbios/rsparser.c index 79bce7b7574..9001b6f0204 100644 --- a/drivers/pnp/pnpbios/rsparser.c +++ b/drivers/pnp/pnpbios/rsparser.c @@ -64,7 +64,7 @@ pnpbios_parse_allocated_irqresource(struct pnp_resource_table * res, int irq) } res->irq_resource[i].start = res->irq_resource[i].end = (unsigned long) irq; - pcibios_penalize_isa_irq(irq); + pcibios_penalize_isa_irq(irq, 1); } } diff --git a/drivers/pnp/resource.c b/drivers/pnp/resource.c index 2d1322dd7e1..887ad893934 100644 --- a/drivers/pnp/resource.c +++ b/drivers/pnp/resource.c @@ -102,7 +102,7 @@ int pnp_register_irq_resource(struct pnp_option *option, struct pnp_irq *data) for (i = 0; i < 16; i++) if (test_bit(i, data->map)) - pcibios_penalize_isa_irq(i); + pcibios_penalize_isa_irq(i, 0); } #endif return 0; -- cgit v1.2.3