diff options
Diffstat (limited to 'drivers/acpi/utilities/utdebug.c')
-rw-r--r-- | drivers/acpi/utilities/utdebug.c | 38 |
1 files changed, 30 insertions, 8 deletions
diff --git a/drivers/acpi/utilities/utdebug.c b/drivers/acpi/utilities/utdebug.c index a8c350643d57..5ec1cfcc611d 100644 --- a/drivers/acpi/utilities/utdebug.c +++ b/drivers/acpi/utilities/utdebug.c | |||
@@ -517,20 +517,13 @@ acpi_ut_ptr_exit(u32 line_number, | |||
517 | * | 517 | * |
518 | ******************************************************************************/ | 518 | ******************************************************************************/ |
519 | 519 | ||
520 | void acpi_ut_dump_buffer(u8 * buffer, u32 count, u32 display, u32 component_id) | 520 | void acpi_ut_dump_buffer2(u8 * buffer, u32 count, u32 display) |
521 | { | 521 | { |
522 | acpi_native_uint i = 0; | 522 | acpi_native_uint i = 0; |
523 | acpi_native_uint j; | 523 | acpi_native_uint j; |
524 | u32 temp32; | 524 | u32 temp32; |
525 | u8 buf_char; | 525 | u8 buf_char; |
526 | 526 | ||
527 | /* Only dump the buffer if tracing is enabled */ | ||
528 | |||
529 | if (!((ACPI_LV_TABLES & acpi_dbg_level) && | ||
530 | (component_id & acpi_dbg_layer))) { | ||
531 | return; | ||
532 | } | ||
533 | |||
534 | if ((count < 4) || (count & 0x01)) { | 527 | if ((count < 4) || (count & 0x01)) { |
535 | display = DB_BYTE_DISPLAY; | 528 | display = DB_BYTE_DISPLAY; |
536 | } | 529 | } |
@@ -556,6 +549,7 @@ void acpi_ut_dump_buffer(u8 * buffer, u32 count, u32 display, u32 component_id) | |||
556 | } | 549 | } |
557 | 550 | ||
558 | switch (display) { | 551 | switch (display) { |
552 | case DB_BYTE_DISPLAY: | ||
559 | default: /* Default is BYTE display */ | 553 | default: /* Default is BYTE display */ |
560 | 554 | ||
561 | acpi_os_printf("%02X ", buffer[i + j]); | 555 | acpi_os_printf("%02X ", buffer[i + j]); |
@@ -613,3 +607,31 @@ void acpi_ut_dump_buffer(u8 * buffer, u32 count, u32 display, u32 component_id) | |||
613 | 607 | ||
614 | return; | 608 | return; |
615 | } | 609 | } |
610 | |||
611 | /******************************************************************************* | ||
612 | * | ||
613 | * FUNCTION: acpi_ut_dump_buffer | ||
614 | * | ||
615 | * PARAMETERS: Buffer - Buffer to dump | ||
616 | * Count - Amount to dump, in bytes | ||
617 | * Display - BYTE, WORD, DWORD, or QWORD display | ||
618 | * component_iD - Caller's component ID | ||
619 | * | ||
620 | * RETURN: None | ||
621 | * | ||
622 | * DESCRIPTION: Generic dump buffer in both hex and ascii. | ||
623 | * | ||
624 | ******************************************************************************/ | ||
625 | |||
626 | void acpi_ut_dump_buffer(u8 * buffer, u32 count, u32 display, u32 component_id) | ||
627 | { | ||
628 | |||
629 | /* Only dump the buffer if tracing is enabled */ | ||
630 | |||
631 | if (!((ACPI_LV_TABLES & acpi_dbg_level) && | ||
632 | (component_id & acpi_dbg_layer))) { | ||
633 | return; | ||
634 | } | ||
635 | |||
636 | acpi_ut_dump_buffer2(buffer, count, display); | ||
637 | } | ||