diff options
author | Bob Moore <robert.moore@intel.com> | 2013-05-29 21:59:21 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-06-01 15:54:30 -0400 |
commit | e1405ca5ebf1068a0d62afd2fec8f0354038147a (patch) | |
tree | 89ab8b0bb18695e25a23a6e8e8a56997ceb27544 /drivers/acpi/acpica/utxferror.c | |
parent | f6f57f605eecd4f6a9b59b55bf91c50fe7b52186 (diff) |
ACPICA: Add BIOS error interface for predefined name validation support
BIOS error message for errors found in predefined names.
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Acked-by: Len Brown <len.brown@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/acpica/utxferror.c')
-rw-r--r-- | drivers/acpi/acpica/utxferror.c | 51 |
1 files changed, 47 insertions, 4 deletions
diff --git a/drivers/acpi/acpica/utxferror.c b/drivers/acpi/acpica/utxferror.c index 976b6c734fce..61a2c1704ccf 100644 --- a/drivers/acpi/acpica/utxferror.c +++ b/drivers/acpi/acpica/utxferror.c | |||
@@ -82,8 +82,8 @@ extern FILE *acpi_gbl_output_file; | |||
82 | #define ACPI_MSG_EXCEPTION "ACPI Exception: " | 82 | #define ACPI_MSG_EXCEPTION "ACPI Exception: " |
83 | #define ACPI_MSG_WARNING "ACPI Warning: " | 83 | #define ACPI_MSG_WARNING "ACPI Warning: " |
84 | #define ACPI_MSG_INFO "ACPI: " | 84 | #define ACPI_MSG_INFO "ACPI: " |
85 | #define ACPI_MSG_BIOS_ERROR "ACPI BIOS Bug: Error: " | 85 | #define ACPI_MSG_BIOS_ERROR "ACPI BIOS Error (bug): " |
86 | #define ACPI_MSG_BIOS_WARNING "ACPI BIOS Bug: Warning: " | 86 | #define ACPI_MSG_BIOS_WARNING "ACPI BIOS Warning (bug): " |
87 | /* | 87 | /* |
88 | * Common message suffix | 88 | * Common message suffix |
89 | */ | 89 | */ |
@@ -325,7 +325,7 @@ acpi_ut_predefined_warning(const char *module_name, | |||
325 | return; | 325 | return; |
326 | } | 326 | } |
327 | 327 | ||
328 | acpi_os_printf(ACPI_MSG_WARNING "For %s: ", pathname); | 328 | acpi_os_printf(ACPI_MSG_WARNING "%s: ", pathname); |
329 | 329 | ||
330 | va_start(arg_list, format); | 330 | va_start(arg_list, format); |
331 | acpi_os_vprintf(format, arg_list); | 331 | acpi_os_vprintf(format, arg_list); |
@@ -367,7 +367,50 @@ acpi_ut_predefined_info(const char *module_name, | |||
367 | return; | 367 | return; |
368 | } | 368 | } |
369 | 369 | ||
370 | acpi_os_printf(ACPI_MSG_INFO "For %s: ", pathname); | 370 | acpi_os_printf(ACPI_MSG_INFO "%s: ", pathname); |
371 | |||
372 | va_start(arg_list, format); | ||
373 | acpi_os_vprintf(format, arg_list); | ||
374 | ACPI_MSG_SUFFIX; | ||
375 | va_end(arg_list); | ||
376 | } | ||
377 | |||
378 | /******************************************************************************* | ||
379 | * | ||
380 | * FUNCTION: acpi_ut_predefined_bios_error | ||
381 | * | ||
382 | * PARAMETERS: module_name - Caller's module name (for error output) | ||
383 | * line_number - Caller's line number (for error output) | ||
384 | * pathname - Full pathname to the node | ||
385 | * node_flags - From Namespace node for the method/object | ||
386 | * format - Printf format string + additional args | ||
387 | * | ||
388 | * RETURN: None | ||
389 | * | ||
390 | * DESCRIPTION: BIOS error message for predefined names. Messages | ||
391 | * are only emitted the first time a problem with a particular | ||
392 | * method/object is detected. This prevents a flood of | ||
393 | * messages for methods that are repeatedly evaluated. | ||
394 | * | ||
395 | ******************************************************************************/ | ||
396 | |||
397 | void ACPI_INTERNAL_VAR_XFACE | ||
398 | acpi_ut_predefined_bios_error(const char *module_name, | ||
399 | u32 line_number, | ||
400 | char *pathname, | ||
401 | u8 node_flags, const char *format, ...) | ||
402 | { | ||
403 | va_list arg_list; | ||
404 | |||
405 | /* | ||
406 | * Warning messages for this method/object will be disabled after the | ||
407 | * first time a validation fails or an object is successfully repaired. | ||
408 | */ | ||
409 | if (node_flags & ANOBJ_EVALUATED) { | ||
410 | return; | ||
411 | } | ||
412 | |||
413 | acpi_os_printf(ACPI_MSG_BIOS_ERROR "%s: ", pathname); | ||
371 | 414 | ||
372 | va_start(arg_list, format); | 415 | va_start(arg_list, format); |
373 | acpi_os_vprintf(format, arg_list); | 416 | acpi_os_vprintf(format, arg_list); |