aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/utilities/utobject.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/utilities/utobject.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/utilities/utobject.c')
-rw-r--r--drivers/acpi/utilities/utobject.c29
1 files changed, 16 insertions, 13 deletions
diff --git a/drivers/acpi/utilities/utobject.c b/drivers/acpi/utilities/utobject.c
index 1b6b21577805..7ee2d1d98071 100644
--- a/drivers/acpi/utilities/utobject.c
+++ b/drivers/acpi/utilities/utobject.c
@@ -177,8 +177,8 @@ union acpi_operand_object *acpi_ut_create_buffer_object(acpi_size buffer_size)
177 177
178 buffer = ACPI_MEM_CALLOCATE(buffer_size); 178 buffer = ACPI_MEM_CALLOCATE(buffer_size);
179 if (!buffer) { 179 if (!buffer) {
180 ACPI_REPORT_ERROR(("Could not allocate size %X\n", 180 ACPI_ERROR((AE_INFO, "Could not allocate size %X",
181 (u32) buffer_size)); 181 (u32) buffer_size));
182 acpi_ut_remove_reference(buffer_desc); 182 acpi_ut_remove_reference(buffer_desc);
183 return_PTR(NULL); 183 return_PTR(NULL);
184 } 184 }
@@ -229,8 +229,8 @@ union acpi_operand_object *acpi_ut_create_string_object(acpi_size string_size)
229 */ 229 */
230 string = ACPI_MEM_CALLOCATE(string_size + 1); 230 string = ACPI_MEM_CALLOCATE(string_size + 1);
231 if (!string) { 231 if (!string) {
232 ACPI_REPORT_ERROR(("Could not allocate size %X\n", 232 ACPI_ERROR((AE_INFO, "Could not allocate size %X",
233 (u32) string_size)); 233 (u32) string_size));
234 acpi_ut_remove_reference(string_desc); 234 acpi_ut_remove_reference(string_desc);
235 return_PTR(NULL); 235 return_PTR(NULL);
236 } 236 }
@@ -312,8 +312,8 @@ void *acpi_ut_allocate_object_desc_dbg(char *module_name,
312 312
313 object = acpi_os_acquire_object(acpi_gbl_operand_cache); 313 object = acpi_os_acquire_object(acpi_gbl_operand_cache);
314 if (!object) { 314 if (!object) {
315 _ACPI_REPORT_ERROR(module_name, line_number, 315 ACPI_ERROR((module_name, line_number,
316 ("Could not allocate an object descriptor\n")); 316 "Could not allocate an object descriptor"));
317 317
318 return_PTR(NULL); 318 return_PTR(NULL);
319 } 319 }
@@ -347,9 +347,9 @@ void acpi_ut_delete_object_desc(union acpi_operand_object *object)
347 /* Object must be an union acpi_operand_object */ 347 /* Object must be an union acpi_operand_object */
348 348
349 if (ACPI_GET_DESCRIPTOR_TYPE(object) != ACPI_DESC_TYPE_OPERAND) { 349 if (ACPI_GET_DESCRIPTOR_TYPE(object) != ACPI_DESC_TYPE_OPERAND) {
350 ACPI_REPORT_ERROR(("%p is not an ACPI Operand object [%s]\n", 350 ACPI_ERROR((AE_INFO,
351 object, 351 "%p is not an ACPI Operand object [%s]", object,
352 acpi_ut_get_descriptor_name(object))); 352 acpi_ut_get_descriptor_name(object)));
353 return_VOID; 353 return_VOID;
354 } 354 }
355 355
@@ -451,7 +451,10 @@ acpi_ut_get_simple_object_size(union acpi_operand_object *internal_object,
451 * Notably, Locals and Args are not supported, but this may be 451 * Notably, Locals and Args are not supported, but this may be
452 * required eventually. 452 * required eventually.
453 */ 453 */
454 ACPI_REPORT_ERROR(("Unsupported Reference opcode=%X in object %p\n", internal_object->reference.opcode, internal_object)); 454 ACPI_ERROR((AE_INFO,
455 "Unsupported Reference opcode=%X in object %p",
456 internal_object->reference.opcode,
457 internal_object));
455 status = AE_TYPE; 458 status = AE_TYPE;
456 break; 459 break;
457 } 460 }
@@ -459,9 +462,9 @@ acpi_ut_get_simple_object_size(union acpi_operand_object *internal_object,
459 462
460 default: 463 default:
461 464
462 ACPI_REPORT_ERROR(("Unsupported type=%X in object %p\n", 465 ACPI_ERROR((AE_INFO, "Unsupported type=%X in object %p",
463 ACPI_GET_OBJECT_TYPE(internal_object), 466 ACPI_GET_OBJECT_TYPE(internal_object),
464 internal_object)); 467 internal_object));
465 status = AE_TYPE; 468 status = AE_TYPE;
466 break; 469 break;
467 } 470 }