diff options
author | Lin Ming <ming.m.lin@intel.com> | 2009-03-04 01:31:25 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2009-03-26 16:38:23 -0400 |
commit | 5e053e77f233342b56fda419d347fd2c958b9849 (patch) | |
tree | fad2031c0c0c60498f671d99dc9bbaf3a65ac734 /drivers/acpi/acpica | |
parent | 531c633d2be8e79087335a46d3c017ca5837e588 (diff) |
ACPICA: Check for non-zero address before being converted to GAS
Reported-by: FreeBSD community
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/acpica')
-rw-r--r-- | drivers/acpi/acpica/tbfadt.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/acpi/acpica/tbfadt.c b/drivers/acpi/acpica/tbfadt.c index a8191efd9aa6..43fe886b41a2 100644 --- a/drivers/acpi/acpica/tbfadt.c +++ b/drivers/acpi/acpica/tbfadt.c | |||
@@ -618,12 +618,14 @@ static void acpi_tb_setup_fadt_registers(void) | |||
618 | ACPI_ADD_PTR(struct acpi_generic_address, &acpi_gbl_FADT, | 618 | ACPI_ADD_PTR(struct acpi_generic_address, &acpi_gbl_FADT, |
619 | fadt_pm_info_table[i].source); | 619 | fadt_pm_info_table[i].source); |
620 | 620 | ||
621 | acpi_tb_init_generic_address(fadt_pm_info_table[i].target, | 621 | if (source64->address) { |
622 | source64->space_id, | 622 | acpi_tb_init_generic_address(fadt_pm_info_table[i]. |
623 | pm1_register_byte_width, | 623 | target, source64->space_id, |
624 | source64->address + | 624 | pm1_register_byte_width, |
625 | (fadt_pm_info_table[i]. | 625 | source64->address + |
626 | register_num * | 626 | (fadt_pm_info_table[i]. |
627 | pm1_register_byte_width)); | 627 | register_num * |
628 | pm1_register_byte_width)); | ||
629 | } | ||
628 | } | 630 | } |
629 | } | 631 | } |