summaryrefslogtreecommitdiff
path: root/drivers/acpi/acpica/utdebug.c
diff options
context:
space:
mode:
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>2018-01-18 03:01:07 +0100
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2018-01-18 03:01:07 +0100
commit2a2bafcb3b60f0b5b1cc7b10f21356a8516f192a (patch)
tree589800f95c6c2f5c106fb01414075ac2d5a767eb /drivers/acpi/acpica/utdebug.c
parent90fd94e4aba4ddfb6764c051a6bf9a3f4f26fb50 (diff)
parent3bd93bd76ba6b5588a1b2b9f4f451952c7d8994d (diff)
Merge branch 'acpica'
* acpica: (40 commits) ACPICA: Update version to 20171215 ACPICA: trivial style fix, no functional change ACPICA: Fix a couple memory leaks during package object resolution ACPICA: Recognize the Windows 10 version 1607 and 1703 OSI strings ACPICA: DT compiler: prevent error if optional field at the end of table is not present ACPICA: Rename a global variable, no functional change ACPICA: Create and deploy safe version of strncpy ACPICA: Cleanup the global variables and update comments ACPICA: Debugger: fix slight indentation issue ACPICA: Fix a regression in the acpi_evaluate_object_type() interface ACPICA: Update for a few debug output statements ACPICA: Debug output, no functional change ACPICA: Update information in MAINTAINERS ACPICA: Rename variable to match upstream ACPICA: Update version to 20171110 ACPICA: ACPI 6.2: Additional PPTT flags ACPICA: Update linkage for get mutex name interface ACPICA: Update mutex error messages, no functional change ACPICA: Debugger: add "background" command for method execution ACPICA: Small typo fix, no functional change ...
Diffstat (limited to 'drivers/acpi/acpica/utdebug.c')
-rw-r--r--drivers/acpi/acpica/utdebug.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/drivers/acpi/acpica/utdebug.c b/drivers/acpi/acpica/utdebug.c
index 615a885e2ca3..cff7154b7fee 100644
--- a/drivers/acpi/acpica/utdebug.c
+++ b/drivers/acpi/acpica/utdebug.c
@@ -163,6 +163,9 @@ acpi_debug_print(u32 requested_debug_level,
{
acpi_thread_id thread_id;
va_list args;
+#ifdef ACPI_APPLICATION
+ int fill_count;
+#endif
/* Check if debug output enabled */
@@ -202,10 +205,21 @@ acpi_debug_print(u32 requested_debug_level,
acpi_os_printf("[%u] ", (u32)thread_id);
}
- acpi_os_printf("[%02ld] ", acpi_gbl_nesting_level);
-#endif
+ fill_count = 48 - acpi_gbl_nesting_level -
+ strlen(acpi_ut_trim_function_name(function_name));
+ if (fill_count < 0) {
+ fill_count = 0;
+ }
+
+ acpi_os_printf("[%02ld] %*s",
+ acpi_gbl_nesting_level, acpi_gbl_nesting_level + 1, " ");
+ acpi_os_printf("%s%*s: ",
+ acpi_ut_trim_function_name(function_name), fill_count,
+ " ");
+#else
acpi_os_printf("%-22.22s: ", acpi_ut_trim_function_name(function_name));
+#endif
va_start(args, format);
acpi_os_vprintf(format, args);