Skip to content

Commit

Permalink
ACPICA: Update for some debug output. No functional change
Browse files Browse the repository at this point in the history
ACPICA commit 3a08436fe3bff297a6de162252964e955946c7d3

Improve/simplify some of the debug messages.

Link: https://github.com/acpica/acpica/commit/3a08436f
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Bob Moore authored and Rafael J. Wysocki committed Feb 21, 2018
1 parent d82847a commit 1ef6323
Show file tree
Hide file tree
Showing 11 changed files with 40 additions and 26 deletions.
1 change: 1 addition & 0 deletions drivers/acpi/acpica/dsargs.c
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,7 @@ acpi_status acpi_ds_get_package_arguments(union acpi_operand_object *obj_desc)
status = acpi_ds_execute_arguments(node, node,
obj_desc->package.aml_length,
obj_desc->package.aml_start);

return_ACPI_STATUS(status);
}

Expand Down
4 changes: 2 additions & 2 deletions drivers/acpi/acpica/dsopcode.c
Original file line number Diff line number Diff line change
Expand Up @@ -603,8 +603,8 @@ acpi_ds_eval_data_object_operands(struct acpi_walk_state *walk_state,

if (!op->common.value.arg) {
ACPI_ERROR((AE_INFO,
"Dispatch: Missing child while executing TermArg for %X",
op->common.aml_opcode));
"Missing child while evaluating opcode %4.4X, Op %p",
op->common.aml_opcode, op));
return_ACPI_STATUS(AE_OK);
}

Expand Down
2 changes: 1 addition & 1 deletion drivers/acpi/acpica/dswload.c
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ acpi_ds_load1_begin_op(struct acpi_walk_state *walk_state,
char *path;
u32 flags;

ACPI_FUNCTION_TRACE(ds_load1_begin_op);
ACPI_FUNCTION_TRACE_PTR(ds_load1_begin_op, walk_state->op);

op = walk_state->op;
ACPI_DEBUG_PRINT((ACPI_DB_DISPATCH, "Op=%p State=%p\n", op,
Expand Down
7 changes: 2 additions & 5 deletions drivers/acpi/acpica/exnames.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,13 +174,10 @@ static acpi_status acpi_ex_name_segment(u8 ** in_aml_address, char *name_string)
return_ACPI_STATUS(AE_CTRL_PENDING);
}

ACPI_DEBUG_PRINT((ACPI_DB_LOAD, "Bytes from stream:\n"));

for (index = 0;
(index < ACPI_NAME_SIZE)
&& (acpi_ut_valid_name_char(*aml_address, 0)); index++) {
char_buf[index] = *aml_address++;
ACPI_DEBUG_PRINT((ACPI_DB_LOAD, "%c\n", char_buf[index]));
}

/* Valid name segment */
Expand All @@ -192,9 +189,9 @@ static acpi_status acpi_ex_name_segment(u8 ** in_aml_address, char *name_string)
char_buf[4] = '\0';

if (name_string) {
strcat(name_string, char_buf);
ACPI_DEBUG_PRINT((ACPI_DB_NAMES,
"Appended to - %s\n", name_string));
"Appending NameSeg %s\n", char_buf));
strcat(name_string, char_buf);
} else {
ACPI_DEBUG_PRINT((ACPI_DB_NAMES,
"No Name string - %s\n", char_buf));
Expand Down
7 changes: 6 additions & 1 deletion drivers/acpi/acpica/nsinit.c
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ acpi_status acpi_ns_initialize_devices(u32 flags)
* RETURN: Status
*
* DESCRIPTION: Callback from acpi_walk_namespace. Invoked for every object
* within the namespace.
* within the namespace.
*
* Currently, the only objects that require initialization are:
* 1) Methods
Expand Down Expand Up @@ -400,6 +400,10 @@ acpi_ns_init_one_object(acpi_handle obj_handle,
break;
}

ACPI_DEBUG_PRINT_RAW((ACPI_DB_PARSE,
"%s: Completing resolution of Package elements\n",
ACPI_GET_FUNCTION_NAME));

/*
* Resolve all named references in package objects (and all
* sub-packages). This action has been deferred until the entire
Expand All @@ -409,6 +413,7 @@ acpi_ns_init_one_object(acpi_handle obj_handle,
status = acpi_ut_walk_package_tree(obj_desc, NULL,
acpi_ds_init_package_element,
NULL);

obj_desc->package.flags |= AOPOBJ_DATA_VALID;
break;

Expand Down
3 changes: 3 additions & 0 deletions drivers/acpi/acpica/nsnames.c
Original file line number Diff line number Diff line change
Expand Up @@ -354,6 +354,9 @@ char *acpi_ns_get_normalized_pathname(struct acpi_namespace_node *node,
(void)acpi_ns_build_normalized_path(node, name_buffer, size,
no_trailing);

ACPI_DEBUG_PRINT_RAW((ACPI_DB_NAMES, "%s: Path \"%s\"\n",
ACPI_GET_FUNCTION_NAME, name_buffer));

return_PTR(name_buffer);
}

Expand Down
9 changes: 6 additions & 3 deletions drivers/acpi/acpica/nsparse.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,10 @@ acpi_ns_execute_table(u32 table_index, struct acpi_namespace_node *start_node)
goto cleanup;
}

ACPI_DEBUG_PRINT((ACPI_DB_PARSE,
"Create table code block: %p\n", method_obj));
ACPI_DEBUG_PRINT_RAW((ACPI_DB_PARSE,
"%s: Create table pseudo-method for [%4.4s] @%p, method %p\n",
ACPI_GET_FUNCTION_NAME, table->signature, table,
method_obj));

method_obj->method.aml_start = aml_start;
method_obj->method.aml_length = aml_length;
Expand Down Expand Up @@ -265,7 +267,8 @@ acpi_ns_parse_table(u32 table_index, struct acpi_namespace_node *start_node)
ACPI_FUNCTION_TRACE(ns_parse_table);

if (acpi_gbl_parse_table_as_term_list) {
ACPI_DEBUG_PRINT((ACPI_DB_PARSE, "**** Start load pass\n"));
ACPI_DEBUG_PRINT((ACPI_DB_PARSE,
"**** Start table execution pass\n"));

status = acpi_ns_execute_table(table_index, start_node);
if (ACPI_FAILURE(status)) {
Expand Down
4 changes: 2 additions & 2 deletions drivers/acpi/acpica/psloop.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ acpi_ps_get_arguments(struct acpi_walk_state *walk_state,
}

ACPI_DEBUG_PRINT((ACPI_DB_PARSE,
"Final argument count: %u pass %u\n",
"Final argument count: %8.8X pass %u\n",
walk_state->arg_count,
walk_state->pass_number));

Expand Down Expand Up @@ -581,7 +581,7 @@ acpi_status acpi_ps_parse_loop(struct acpi_walk_state *walk_state)
/* Check for arguments that need to be processed */

ACPI_DEBUG_PRINT((ACPI_DB_PARSE,
"Parseloop: argument count: %u\n",
"Parseloop: argument count: %8.8X\n",
walk_state->arg_count));

if (walk_state->arg_count) {
Expand Down
2 changes: 1 addition & 1 deletion drivers/acpi/acpica/psparse.c
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ acpi_status acpi_ps_parse_aml(struct acpi_walk_state *walk_state)
walk_state->parser_state.aml_size));

if (!walk_state->parser_state.aml) {
return_ACPI_STATUS(AE_NULL_OBJECT);
return_ACPI_STATUS(AE_BAD_ADDRESS);
}

/* Create and initialize a new thread state */
Expand Down
7 changes: 4 additions & 3 deletions drivers/acpi/acpica/utcache.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,9 +269,10 @@ void *acpi_os_acquire_object(struct acpi_memory_list *cache)
cache->current_depth--;

ACPI_MEM_TRACKING(cache->hits++);
ACPI_DEBUG_PRINT((ACPI_DB_EXEC,
"Object %p from %s cache\n", object,
cache->list_name));
ACPI_DEBUG_PRINT_RAW((ACPI_DB_EXEC,
"%s: Object %p from %s cache\n",
ACPI_GET_FUNCTION_NAME, object,
cache->list_name));

status = acpi_ut_release_mutex(ACPI_MTX_CACHES);
if (ACPI_FAILURE(status)) {
Expand Down
20 changes: 12 additions & 8 deletions drivers/acpi/acpica/utdelete.c
Original file line number Diff line number Diff line change
Expand Up @@ -332,8 +332,10 @@ static void acpi_ut_delete_internal_obj(union acpi_operand_object *object)

/* Now the object can be safely deleted */

ACPI_DEBUG_PRINT((ACPI_DB_ALLOCATIONS, "Deleting Object %p [%s]\n",
object, acpi_ut_get_object_type_name(object)));
ACPI_DEBUG_PRINT_RAW((ACPI_DB_ALLOCATIONS,
"%s: Deleting Object %p [%s]\n",
ACPI_GET_FUNCTION_NAME, object,
acpi_ut_get_object_type_name(object)));

acpi_ut_delete_object_desc(object);
return_VOID;
Expand Down Expand Up @@ -444,9 +446,10 @@ acpi_ut_update_ref_count(union acpi_operand_object *object, u32 action)
object));
}

ACPI_DEBUG_PRINT((ACPI_DB_ALLOCATIONS,
"Obj %p Type %.2X Refs %.2X [Decremented]\n",
object, object->common.type, new_count));
ACPI_DEBUG_PRINT_RAW((ACPI_DB_ALLOCATIONS,
"%s: Obj %p Type %.2X Refs %.2X [Decremented]\n",
ACPI_GET_FUNCTION_NAME, object,
object->common.type, new_count));

/* Actually delete the object on a reference count of zero */

Expand Down Expand Up @@ -747,9 +750,10 @@ void acpi_ut_remove_reference(union acpi_operand_object *object)
return;
}

ACPI_DEBUG_PRINT((ACPI_DB_ALLOCATIONS,
"Obj %p Current Refs=%X [To Be Decremented]\n",
object, object->common.reference_count));
ACPI_DEBUG_PRINT_RAW((ACPI_DB_ALLOCATIONS,
"%s: Obj %p Current Refs=%X [To Be Decremented]\n",
ACPI_GET_FUNCTION_NAME, object,
object->common.reference_count));

/*
* Decrement the reference count, and only actually delete the object
Expand Down

0 comments on commit 1ef6323

Please sign in to comment.