acpi: remove the wrong warning about xpm1a_event_block.bit_width
Subsystems (2)
PATCH 1/1 acpi: remove the wrong warning about xpm1a_event_block.bit_width
Impact: fix warning
it seems there are some merging problems.
that bit_width is already divided by 2. so I got warning from all servers.
also in that case do try to the fallback like comments saying.
Signed-off-by Yinghai Lu <[email protected]>
--- drivers/acpi/acpica/tbfadt.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-)
drivers/acpi/acpica/tbfadt.c +12 -6
@@ -447,13 +447,16 @@ static void acpi_tb_convert_fadt(void)* cannot be relied upon, though. Hence resort to using the v1 length * here (and warn about the inconsistency). */ -if (acpi_gbl_FADT.xpm1a_event_block.bit_width - != acpi_gbl_FADT.pm1_event_length *8 ) +if (acpi_gbl_FADT.xpm1a_event_block.bit_width *2 + != acpi_gbl_FADT.pm1_event_length *8 ) {printk (KERN_WARNING "FADT: " "X_PM1a_EVT_BLK.bit_width (%u) does not match" " PM1_EVT_LEN (%u)\n" , - acpi_gbl_FADT.xpm1a_event_block.bit_width, + acpi_gbl_FADT.xpm1a_event_block.bit_width *2 , acpi_gbl_FADT.pm1_event_length); + pm1_register_byte_width = (u8 )ACPI_DIV_2 (acpi_gbl_FADT.pm1_event_length); + acpi_gbl_FADT.xpm1a_event_block.bit_width = pm1_register_byte_width *8 ; + }/* The PM1A register block is required */
@@ -469,13 +472,16 @@ static void acpi_tb_convert_fadt(void)/* The PM1B register block is optional, ignore if not present */ if (acpi_gbl_FADT.xpm1b_event_block.address) { -if (acpi_gbl_FADT.xpm1b_event_block.bit_width - != acpi_gbl_FADT.pm1_event_length *8 ) +if (acpi_gbl_FADT.xpm1b_event_block.bit_width *2 + != acpi_gbl_FADT.pm1_event_length *8 ) {printk (KERN_WARNING "FADT: " "X_PM1b_EVT_BLK.bit_width (%u) does not match" " PM1_EVT_LEN (%u)\n" , - acpi_gbl_FADT.xpm1b_event_block.bit_width, + acpi_gbl_FADT.xpm1b_event_block.bit_width *2 , acpi_gbl_FADT.pm1_event_length); + pm1_register_byte_width = (u8 )ACPI_DIV_2 (acpi_gbl_FADT.pm1_event_length); + acpi_gbl_FADT.xpm1b_event_block.bit_width = pm1_register_byte_width *8 ; + } acpi_tb_init_generic_address(&acpi_gbl_xpm1b_enable, acpi_gbl_FADT.xpm1b_event_block.space_id, pm1_register_byte_width,
Len Brown
reviewerThis warning is not present in the latest ACPICA branch.
thanks,
Len Brown, Intel Open Source Technology Center