aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/resources/rsmisc.c
diff options
context:
space:
mode:
authorBob Moore <robert.moore@intel.com>2006-01-27 16:43:00 -0500
committerLen Brown <len.brown@intel.com>2006-01-31 03:25:09 -0500
commitb8e4d89357fc434618a59c1047cac72641191805 (patch)
treeac97fcc6fdc277c682365900663872c96f2420bd /drivers/acpi/resources/rsmisc.c
parent292dd876ee765c478b27c93cc51e93a558ed58bf (diff)
[ACPI] ACPICA 20060127
Implemented support in the Resource Manager to allow unresolved namestring references within resource package objects for the _PRT method. This support is in addition to the previously implemented unresolved reference support within the AML parser. If the interpreter slack mode is enabled (true on Linux unless acpi=strict), these unresolved references will be passed through to the caller as a NULL package entry. http://bugzilla.kernel.org/show_bug.cgi?id=5741 Implemented and deployed new macros and functions for error and warning messages across the subsystem. These macros are simpler and generate less code than their predecessors. The new macros ACPI_ERROR, ACPI_EXCEPTION, ACPI_WARNING, and ACPI_INFO replace the ACPI_REPORT_* macros. Implemented the acpi_cpu_flags type to simplify host OS integration of the Acquire/Release Lock OSL interfaces. Suggested by Steven Rostedt and Andrew Morton. Fixed a problem where Alias ASL operators are sometimes not correctly resolved. causing AE_AML_INTERNAL http://bugzilla.kernel.org/show_bug.cgi?id=5189 http://bugzilla.kernel.org/show_bug.cgi?id=5674 Fixed several problems with the implementation of the ConcatenateResTemplate ASL operator. As per the ACPI specification, zero length buffers are now treated as a single EndTag. One-length buffers always cause a fatal exception. Non-zero length buffers that do not end with a full 2-byte EndTag cause a fatal exception. Fixed a possible structure overwrite in the AcpiGetObjectInfo external interface. (With assistance from Thomas Renninger) Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/resources/rsmisc.c')
-rw-r--r--drivers/acpi/resources/rsmisc.c28
1 files changed, 17 insertions, 11 deletions
diff --git a/drivers/acpi/resources/rsmisc.c b/drivers/acpi/resources/rsmisc.c
index 83bfe0dd3eba..ed866cf1c6d2 100644
--- a/drivers/acpi/resources/rsmisc.c
+++ b/drivers/acpi/resources/rsmisc.c
@@ -84,9 +84,11 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
84 ACPI_FUNCTION_TRACE("rs_get_resource"); 84 ACPI_FUNCTION_TRACE("rs_get_resource");
85 85
86 if (((acpi_native_uint) resource) & 0x3) { 86 if (((acpi_native_uint) resource) & 0x3) {
87 acpi_os_printf 87 /* Each internal resource struct is expected to be 32-bit aligned */
88 ("**** GET: Misaligned resource pointer: %p Type %2.2X Len %X\n", 88
89 resource, resource->type, resource->length); 89 ACPI_WARNING((AE_INFO,
90 "Misaligned resource pointer (get): %p Type %2.2X Len %X",
91 resource, resource->type, resource->length));
90 } 92 }
91 93
92 /* Extract the resource Length field (does not include header length) */ 94 /* Extract the resource Length field (does not include header length) */
@@ -274,15 +276,16 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
274 break; 276 break;
275 277
276 default: 278 default:
277 acpi_os_printf 279
278 ("*** Invalid conversion sub-opcode\n"); 280 ACPI_ERROR((AE_INFO,
281 "Invalid conversion sub-opcode"));
279 return_ACPI_STATUS(AE_BAD_PARAMETER); 282 return_ACPI_STATUS(AE_BAD_PARAMETER);
280 } 283 }
281 break; 284 break;
282 285
283 default: 286 default:
284 287
285 acpi_os_printf("*** Invalid conversion opcode\n"); 288 ACPI_ERROR((AE_INFO, "Invalid conversion opcode"));
286 return_ACPI_STATUS(AE_BAD_PARAMETER); 289 return_ACPI_STATUS(AE_BAD_PARAMETER);
287 } 290 }
288 291
@@ -486,15 +489,16 @@ acpi_rs_convert_resource_to_aml(struct acpi_resource *resource,
486 break; 489 break;
487 490
488 default: 491 default:
489 acpi_os_printf 492
490 ("*** Invalid conversion sub-opcode\n"); 493 ACPI_ERROR((AE_INFO,
494 "Invalid conversion sub-opcode"));
491 return_ACPI_STATUS(AE_BAD_PARAMETER); 495 return_ACPI_STATUS(AE_BAD_PARAMETER);
492 } 496 }
493 break; 497 break;
494 498
495 default: 499 default:
496 500
497 acpi_os_printf("*** Invalid conversion opcode\n"); 501 ACPI_ERROR((AE_INFO, "Invalid conversion opcode"));
498 return_ACPI_STATUS(AE_BAD_PARAMETER); 502 return_ACPI_STATUS(AE_BAD_PARAMETER);
499 } 503 }
500 504
@@ -523,7 +527,9 @@ if (((aml->irq.flags & 0x09) == 0x00) || ((aml->irq.flags & 0x09) == 0x09)) {
523 * polarity/trigger interrupts are allowed (ACPI spec, section 527 * polarity/trigger interrupts are allowed (ACPI spec, section
524 * "IRQ Format"), so 0x00 and 0x09 are illegal. 528 * "IRQ Format"), so 0x00 and 0x09 are illegal.
525 */ 529 */
526 ACPI_REPORT_ERROR(("Invalid interrupt polarity/trigger in resource list, %X\n", aml->irq.flags)); 530 ACPI_ERROR((AE_INFO,
531 "Invalid interrupt polarity/trigger in resource list, %X",
532 aml->irq.flags));
527 return_ACPI_STATUS(AE_BAD_DATA); 533 return_ACPI_STATUS(AE_BAD_DATA);
528} 534}
529 535
@@ -535,7 +541,7 @@ if (temp8 < 1) {
535} 541}
536 542
537if (resource->data.dma.transfer == 0x03) { 543if (resource->data.dma.transfer == 0x03) {
538 ACPI_REPORT_ERROR(("Invalid DMA.Transfer preference (3)\n")); 544 ACPI_ERROR((AE_INFO, "Invalid DMA.Transfer preference (3)"));
539 return_ACPI_STATUS(AE_BAD_DATA); 545 return_ACPI_STATUS(AE_BAD_DATA);
540} 546}
541#endif 547#endif