diff options
Diffstat (limited to 'drivers/acpi/executer')
-rw-r--r-- | drivers/acpi/executer/exconfig.c | 17 | ||||
-rw-r--r-- | drivers/acpi/executer/exconvrt.c | 12 | ||||
-rw-r--r-- | drivers/acpi/executer/excreate.c | 2 | ||||
-rw-r--r-- | drivers/acpi/executer/exdump.c | 67 | ||||
-rw-r--r-- | drivers/acpi/executer/exfldio.c | 9 | ||||
-rw-r--r-- | drivers/acpi/executer/exmisc.c | 8 | ||||
-rw-r--r-- | drivers/acpi/executer/exprep.c | 8 | ||||
-rw-r--r-- | drivers/acpi/executer/exregion.c | 2 | ||||
-rw-r--r-- | drivers/acpi/executer/exresop.c | 4 | ||||
-rw-r--r-- | drivers/acpi/executer/exstore.c | 6 |
10 files changed, 59 insertions, 76 deletions
diff --git a/drivers/acpi/executer/exconfig.c b/drivers/acpi/executer/exconfig.c index 39d742190584..2a32c843cb4a 100644 --- a/drivers/acpi/executer/exconfig.c +++ b/drivers/acpi/executer/exconfig.c | |||
@@ -53,7 +53,7 @@ ACPI_MODULE_NAME("exconfig") | |||
53 | 53 | ||
54 | /* Local prototypes */ | 54 | /* Local prototypes */ |
55 | static acpi_status | 55 | static acpi_status |
56 | acpi_ex_add_table(acpi_native_uint table_index, | 56 | acpi_ex_add_table(u32 table_index, |
57 | struct acpi_namespace_node *parent_node, | 57 | struct acpi_namespace_node *parent_node, |
58 | union acpi_operand_object **ddb_handle); | 58 | union acpi_operand_object **ddb_handle); |
59 | 59 | ||
@@ -73,7 +73,7 @@ acpi_ex_add_table(acpi_native_uint table_index, | |||
73 | ******************************************************************************/ | 73 | ******************************************************************************/ |
74 | 74 | ||
75 | static acpi_status | 75 | static acpi_status |
76 | acpi_ex_add_table(acpi_native_uint table_index, | 76 | acpi_ex_add_table(u32 table_index, |
77 | struct acpi_namespace_node *parent_node, | 77 | struct acpi_namespace_node *parent_node, |
78 | union acpi_operand_object **ddb_handle) | 78 | union acpi_operand_object **ddb_handle) |
79 | { | 79 | { |
@@ -96,7 +96,8 @@ acpi_ex_add_table(acpi_native_uint table_index, | |||
96 | 96 | ||
97 | /* Install the new table into the local data structures */ | 97 | /* Install the new table into the local data structures */ |
98 | 98 | ||
99 | obj_desc->reference.object = ACPI_CAST_PTR(void, table_index); | 99 | obj_desc->reference.object = ACPI_CAST_PTR(void, |
100 | (unsigned long)table_index); | ||
100 | 101 | ||
101 | /* Add the table to the namespace */ | 102 | /* Add the table to the namespace */ |
102 | 103 | ||
@@ -128,12 +129,12 @@ acpi_ex_load_table_op(struct acpi_walk_state *walk_state, | |||
128 | { | 129 | { |
129 | acpi_status status; | 130 | acpi_status status; |
130 | union acpi_operand_object **operand = &walk_state->operands[0]; | 131 | union acpi_operand_object **operand = &walk_state->operands[0]; |
131 | acpi_native_uint table_index; | ||
132 | struct acpi_namespace_node *parent_node; | 132 | struct acpi_namespace_node *parent_node; |
133 | struct acpi_namespace_node *start_node; | 133 | struct acpi_namespace_node *start_node; |
134 | struct acpi_namespace_node *parameter_node = NULL; | 134 | struct acpi_namespace_node *parameter_node = NULL; |
135 | union acpi_operand_object *ddb_handle; | 135 | union acpi_operand_object *ddb_handle; |
136 | struct acpi_table_header *table; | 136 | struct acpi_table_header *table; |
137 | u32 table_index; | ||
137 | 138 | ||
138 | ACPI_FUNCTION_TRACE(ex_load_table_op); | 139 | ACPI_FUNCTION_TRACE(ex_load_table_op); |
139 | 140 | ||
@@ -280,7 +281,7 @@ acpi_ex_load_op(union acpi_operand_object *obj_desc, | |||
280 | { | 281 | { |
281 | union acpi_operand_object *ddb_handle; | 282 | union acpi_operand_object *ddb_handle; |
282 | struct acpi_table_desc table_desc; | 283 | struct acpi_table_desc table_desc; |
283 | acpi_native_uint table_index; | 284 | u32 table_index; |
284 | acpi_status status; | 285 | acpi_status status; |
285 | u32 length; | 286 | u32 length; |
286 | 287 | ||
@@ -437,7 +438,7 @@ acpi_status acpi_ex_unload_table(union acpi_operand_object *ddb_handle) | |||
437 | { | 438 | { |
438 | acpi_status status = AE_OK; | 439 | acpi_status status = AE_OK; |
439 | union acpi_operand_object *table_desc = ddb_handle; | 440 | union acpi_operand_object *table_desc = ddb_handle; |
440 | acpi_native_uint table_index; | 441 | u32 table_index; |
441 | struct acpi_table_header *table; | 442 | struct acpi_table_header *table; |
442 | 443 | ||
443 | ACPI_FUNCTION_TRACE(ex_unload_table); | 444 | ACPI_FUNCTION_TRACE(ex_unload_table); |
@@ -454,9 +455,9 @@ acpi_status acpi_ex_unload_table(union acpi_operand_object *ddb_handle) | |||
454 | return_ACPI_STATUS(AE_BAD_PARAMETER); | 455 | return_ACPI_STATUS(AE_BAD_PARAMETER); |
455 | } | 456 | } |
456 | 457 | ||
457 | /* Get the table index from the ddb_handle */ | 458 | /* Get the table index from the ddb_handle (acpi_size for 64-bit case) */ |
458 | 459 | ||
459 | table_index = (acpi_native_uint) table_desc->reference.object; | 460 | table_index = (u32) (acpi_size) table_desc->reference.object; |
460 | 461 | ||
461 | /* Invoke table handler if present */ | 462 | /* Invoke table handler if present */ |
462 | 463 | ||
diff --git a/drivers/acpi/executer/exconvrt.c b/drivers/acpi/executer/exconvrt.c index fd954b4ed83d..261d97516d9b 100644 --- a/drivers/acpi/executer/exconvrt.c +++ b/drivers/acpi/executer/exconvrt.c | |||
@@ -288,11 +288,11 @@ acpi_ex_convert_to_ascii(acpi_integer integer, | |||
288 | u16 base, u8 * string, u8 data_width) | 288 | u16 base, u8 * string, u8 data_width) |
289 | { | 289 | { |
290 | acpi_integer digit; | 290 | acpi_integer digit; |
291 | acpi_native_uint i; | 291 | u32 i; |
292 | acpi_native_uint j; | 292 | u32 j; |
293 | acpi_native_uint k = 0; | 293 | u32 k = 0; |
294 | acpi_native_uint hex_length; | 294 | u32 hex_length; |
295 | acpi_native_uint decimal_length; | 295 | u32 decimal_length; |
296 | u32 remainder; | 296 | u32 remainder; |
297 | u8 supress_zeros; | 297 | u8 supress_zeros; |
298 | 298 | ||
@@ -348,7 +348,7 @@ acpi_ex_convert_to_ascii(acpi_integer integer, | |||
348 | 348 | ||
349 | /* hex_length: 2 ascii hex chars per data byte */ | 349 | /* hex_length: 2 ascii hex chars per data byte */ |
350 | 350 | ||
351 | hex_length = (acpi_native_uint) ACPI_MUL_2(data_width); | 351 | hex_length = ACPI_MUL_2(data_width); |
352 | for (i = 0, j = (hex_length - 1); i < hex_length; i++, j--) { | 352 | for (i = 0, j = (hex_length - 1); i < hex_length; i++, j--) { |
353 | 353 | ||
354 | /* Get one hex digit, most significant digits first */ | 354 | /* Get one hex digit, most significant digits first */ |
diff --git a/drivers/acpi/executer/excreate.c b/drivers/acpi/executer/excreate.c index 60e62c4f0577..ad09696d5069 100644 --- a/drivers/acpi/executer/excreate.c +++ b/drivers/acpi/executer/excreate.c | |||
@@ -45,8 +45,6 @@ | |||
45 | #include <acpi/acinterp.h> | 45 | #include <acpi/acinterp.h> |
46 | #include <acpi/amlcode.h> | 46 | #include <acpi/amlcode.h> |
47 | #include <acpi/acnamesp.h> | 47 | #include <acpi/acnamesp.h> |
48 | #include <acpi/acevents.h> | ||
49 | #include <acpi/actables.h> | ||
50 | 48 | ||
51 | #define _COMPONENT ACPI_EXECUTER | 49 | #define _COMPONENT ACPI_EXECUTER |
52 | ACPI_MODULE_NAME("excreate") | 50 | ACPI_MODULE_NAME("excreate") |
diff --git a/drivers/acpi/executer/exdump.c b/drivers/acpi/executer/exdump.c index 74f1b22601b3..2be2e2bf95bf 100644 --- a/drivers/acpi/executer/exdump.c +++ b/drivers/acpi/executer/exdump.c | |||
@@ -580,25 +580,22 @@ void acpi_ex_dump_operand(union acpi_operand_object *obj_desc, u32 depth) | |||
580 | 580 | ||
581 | case ACPI_TYPE_BUFFER: | 581 | case ACPI_TYPE_BUFFER: |
582 | 582 | ||
583 | acpi_os_printf("Buffer len %X @ %p\n", | 583 | acpi_os_printf("Buffer length %.2X @ %p\n", |
584 | obj_desc->buffer.length, | 584 | obj_desc->buffer.length, |
585 | obj_desc->buffer.pointer); | 585 | obj_desc->buffer.pointer); |
586 | 586 | ||
587 | length = obj_desc->buffer.length; | ||
588 | if (length > 64) { | ||
589 | length = 64; | ||
590 | } | ||
591 | |||
592 | /* Debug only -- dump the buffer contents */ | 587 | /* Debug only -- dump the buffer contents */ |
593 | 588 | ||
594 | if (obj_desc->buffer.pointer) { | 589 | if (obj_desc->buffer.pointer) { |
595 | acpi_os_printf("Buffer Contents: "); | 590 | length = obj_desc->buffer.length; |
596 | 591 | if (length > 128) { | |
597 | for (index = 0; index < length; index++) { | 592 | length = 128; |
598 | acpi_os_printf(" %02x", | ||
599 | obj_desc->buffer.pointer[index]); | ||
600 | } | 593 | } |
601 | acpi_os_printf("\n"); | 594 | |
595 | acpi_os_printf | ||
596 | ("Buffer Contents: (displaying length 0x%.2X)\n", | ||
597 | length); | ||
598 | ACPI_DUMP_BUFFER(obj_desc->buffer.pointer, length); | ||
602 | } | 599 | } |
603 | break; | 600 | break; |
604 | 601 | ||
@@ -756,54 +753,42 @@ void acpi_ex_dump_operand(union acpi_operand_object *obj_desc, u32 depth) | |||
756 | * | 753 | * |
757 | * FUNCTION: acpi_ex_dump_operands | 754 | * FUNCTION: acpi_ex_dump_operands |
758 | * | 755 | * |
759 | * PARAMETERS: Operands - Operand list | 756 | * PARAMETERS: Operands - A list of Operand objects |
760 | * interpreter_mode - Load or Exec | 757 | * opcode_name - AML opcode name |
761 | * Ident - Identification | 758 | * num_operands - Operand count for this opcode |
762 | * num_levels - # of stack entries to dump above line | ||
763 | * Note - Output notation | ||
764 | * module_name - Caller's module name | ||
765 | * line_number - Caller's invocation line number | ||
766 | * | 759 | * |
767 | * DESCRIPTION: Dump the object stack | 760 | * DESCRIPTION: Dump the operands associated with the opcode |
768 | * | 761 | * |
769 | ******************************************************************************/ | 762 | ******************************************************************************/ |
770 | 763 | ||
771 | void | 764 | void |
772 | acpi_ex_dump_operands(union acpi_operand_object **operands, | 765 | acpi_ex_dump_operands(union acpi_operand_object **operands, |
773 | acpi_interpreter_mode interpreter_mode, | 766 | const char *opcode_name, u32 num_operands) |
774 | char *ident, | ||
775 | u32 num_levels, | ||
776 | char *note, char *module_name, u32 line_number) | ||
777 | { | 767 | { |
778 | acpi_native_uint i; | ||
779 | |||
780 | ACPI_FUNCTION_NAME(ex_dump_operands); | 768 | ACPI_FUNCTION_NAME(ex_dump_operands); |
781 | 769 | ||
782 | if (!ident) { | 770 | if (!opcode_name) { |
783 | ident = "?"; | 771 | opcode_name = "UNKNOWN"; |
784 | } | ||
785 | |||
786 | if (!note) { | ||
787 | note = "?"; | ||
788 | } | 772 | } |
789 | 773 | ||
790 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, | 774 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, |
791 | "************* Operand Stack Contents (Opcode [%s], %d Operands)\n", | 775 | "**** Start operand dump for opcode [%s], %d operands\n", |
792 | ident, num_levels)); | 776 | opcode_name, num_operands)); |
793 | 777 | ||
794 | if (num_levels == 0) { | 778 | if (num_operands == 0) { |
795 | num_levels = 1; | 779 | num_operands = 1; |
796 | } | 780 | } |
797 | 781 | ||
798 | /* Dump the operand stack starting at the top */ | 782 | /* Dump the individual operands */ |
799 | 783 | ||
800 | for (i = 0; num_levels > 0; i--, num_levels--) { | 784 | while (num_operands) { |
801 | acpi_ex_dump_operand(operands[i], 0); | 785 | acpi_ex_dump_operand(*operands, 0); |
786 | operands++; | ||
787 | num_operands--; | ||
802 | } | 788 | } |
803 | 789 | ||
804 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, | 790 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, |
805 | "************* Operand Stack dump from %s(%d), %s\n", | 791 | "**** End operand dump for [%s]\n", opcode_name)); |
806 | module_name, line_number, note)); | ||
807 | return; | 792 | return; |
808 | } | 793 | } |
809 | 794 | ||
diff --git a/drivers/acpi/executer/exfldio.c b/drivers/acpi/executer/exfldio.c index e336b5dc7a50..9ff9d1f4615d 100644 --- a/drivers/acpi/executer/exfldio.c +++ b/drivers/acpi/executer/exfldio.c | |||
@@ -153,14 +153,15 @@ acpi_ex_setup_region(union acpi_operand_object *obj_desc, | |||
153 | /* | 153 | /* |
154 | * Slack mode only: We will go ahead and allow access to this | 154 | * Slack mode only: We will go ahead and allow access to this |
155 | * field if it is within the region length rounded up to the next | 155 | * field if it is within the region length rounded up to the next |
156 | * access width boundary. | 156 | * access width boundary. acpi_size cast for 64-bit compile. |
157 | */ | 157 | */ |
158 | if (ACPI_ROUND_UP(rgn_desc->region.length, | 158 | if (ACPI_ROUND_UP(rgn_desc->region.length, |
159 | obj_desc->common_field. | 159 | obj_desc->common_field. |
160 | access_byte_width) >= | 160 | access_byte_width) >= |
161 | (obj_desc->common_field.base_byte_offset + | 161 | ((acpi_size) obj_desc->common_field. |
162 | (acpi_native_uint) obj_desc->common_field. | 162 | base_byte_offset + |
163 | access_byte_width + field_datum_byte_offset)) { | 163 | obj_desc->common_field.access_byte_width + |
164 | field_datum_byte_offset)) { | ||
164 | return_ACPI_STATUS(AE_OK); | 165 | return_ACPI_STATUS(AE_OK); |
165 | } | 166 | } |
166 | } | 167 | } |
diff --git a/drivers/acpi/executer/exmisc.c b/drivers/acpi/executer/exmisc.c index cc956a5b5267..731414a581a6 100644 --- a/drivers/acpi/executer/exmisc.c +++ b/drivers/acpi/executer/exmisc.c | |||
@@ -329,8 +329,8 @@ acpi_ex_do_concatenate(union acpi_operand_object *operand0, | |||
329 | 329 | ||
330 | /* Result of two Strings is a String */ | 330 | /* Result of two Strings is a String */ |
331 | 331 | ||
332 | return_desc = acpi_ut_create_string_object((acpi_size) | 332 | return_desc = acpi_ut_create_string_object(((acpi_size) |
333 | (operand0->string. | 333 | operand0->string. |
334 | length + | 334 | length + |
335 | local_operand1-> | 335 | local_operand1-> |
336 | string.length)); | 336 | string.length)); |
@@ -352,8 +352,8 @@ acpi_ex_do_concatenate(union acpi_operand_object *operand0, | |||
352 | 352 | ||
353 | /* Result of two Buffers is a Buffer */ | 353 | /* Result of two Buffers is a Buffer */ |
354 | 354 | ||
355 | return_desc = acpi_ut_create_buffer_object((acpi_size) | 355 | return_desc = acpi_ut_create_buffer_object(((acpi_size) |
356 | (operand0->buffer. | 356 | operand0->buffer. |
357 | length + | 357 | length + |
358 | local_operand1-> | 358 | local_operand1-> |
359 | buffer.length)); | 359 | buffer.length)); |
diff --git a/drivers/acpi/executer/exprep.c b/drivers/acpi/executer/exprep.c index 3a2f8cd4c62a..5d438c32989d 100644 --- a/drivers/acpi/executer/exprep.c +++ b/drivers/acpi/executer/exprep.c | |||
@@ -503,11 +503,11 @@ acpi_status acpi_ex_prep_field_value(struct acpi_create_field_info *info) | |||
503 | */ | 503 | */ |
504 | second_desc = obj_desc->common.next_object; | 504 | second_desc = obj_desc->common.next_object; |
505 | second_desc->extra.aml_start = | 505 | second_desc->extra.aml_start = |
506 | ((union acpi_parse_object *)(info->data_register_node))-> | 506 | ACPI_CAST_PTR(union acpi_parse_object, |
507 | named.data; | 507 | info->data_register_node)->named.data; |
508 | second_desc->extra.aml_length = | 508 | second_desc->extra.aml_length = |
509 | ((union acpi_parse_object *)(info->data_register_node))-> | 509 | ACPI_CAST_PTR(union acpi_parse_object, |
510 | named.length; | 510 | info->data_register_node)->named.length; |
511 | 511 | ||
512 | break; | 512 | break; |
513 | 513 | ||
diff --git a/drivers/acpi/executer/exregion.c b/drivers/acpi/executer/exregion.c index 7cd8bb54fa01..7a41c409ae4d 100644 --- a/drivers/acpi/executer/exregion.c +++ b/drivers/acpi/executer/exregion.c | |||
@@ -156,7 +156,7 @@ acpi_ex_system_memory_space_handler(u32 function, | |||
156 | /* Create a new mapping starting at the address given */ | 156 | /* Create a new mapping starting at the address given */ |
157 | 157 | ||
158 | mem_info->mapped_logical_address = | 158 | mem_info->mapped_logical_address = |
159 | acpi_os_map_memory((acpi_native_uint) address, window_size); | 159 | acpi_os_map_memory((acpi_physical_address) address, window_size); |
160 | if (!mem_info->mapped_logical_address) { | 160 | if (!mem_info->mapped_logical_address) { |
161 | ACPI_ERROR((AE_INFO, | 161 | ACPI_ERROR((AE_INFO, |
162 | "Could not map memory at %8.8X%8.8X, size %X", | 162 | "Could not map memory at %8.8X%8.8X, size %X", |
diff --git a/drivers/acpi/executer/exresop.c b/drivers/acpi/executer/exresop.c index 73e29e566a70..54085f16ec28 100644 --- a/drivers/acpi/executer/exresop.c +++ b/drivers/acpi/executer/exresop.c | |||
@@ -698,5 +698,9 @@ acpi_ex_resolve_operands(u16 opcode, | |||
698 | } | 698 | } |
699 | } | 699 | } |
700 | 700 | ||
701 | ACPI_DUMP_OPERANDS(walk_state->operands, | ||
702 | acpi_ps_get_opcode_name(opcode), | ||
703 | walk_state->num_operands); | ||
704 | |||
701 | return_ACPI_STATUS(status); | 705 | return_ACPI_STATUS(status); |
702 | } | 706 | } |
diff --git a/drivers/acpi/executer/exstore.c b/drivers/acpi/executer/exstore.c index 76c875bc3154..38b55e352495 100644 --- a/drivers/acpi/executer/exstore.c +++ b/drivers/acpi/executer/exstore.c | |||
@@ -343,12 +343,6 @@ acpi_ex_store(union acpi_operand_object *source_desc, | |||
343 | acpi_ut_get_object_type_name(dest_desc), | 343 | acpi_ut_get_object_type_name(dest_desc), |
344 | dest_desc)); | 344 | dest_desc)); |
345 | 345 | ||
346 | ACPI_DUMP_STACK_ENTRY(source_desc); | ||
347 | ACPI_DUMP_STACK_ENTRY(dest_desc); | ||
348 | ACPI_DUMP_OPERANDS(&dest_desc, ACPI_IMODE_EXECUTE, "ExStore", | ||
349 | 2, | ||
350 | "Target is not a Reference or Constant object"); | ||
351 | |||
352 | return_ACPI_STATUS(AE_AML_OPERAND_TYPE); | 346 | return_ACPI_STATUS(AE_AML_OPERAND_TYPE); |
353 | } | 347 | } |
354 | 348 | ||