From: David E. Box Date: Thu, 5 Feb 2015 07:20:38 +0000 (+0800) Subject: ACPICA: Hardware: Cast GPE enable_mask before storing X-Git-Tag: firefly_0821_release~176^2~2381^2~11^2~5 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=d6c02669b486a7742a27e9f3a7a66148a5a7c248;p=firefly-linux-kernel-4.4.55.git ACPICA: Hardware: Cast GPE enable_mask before storing ACPICA commit 490ec7f7839bf7ee5e8710a34d1d1a78d54a49b6 In function acpi_hw_low_set_gpe(), cast enable_mask to u8 before storing. The mask was read from a 32 bit register but is an 8 bit value. Fixes Visual Studio compiler warning. Link: https://github.com/acpica/acpica/commit/490ec7f7 Signed-off-by: David E. Box Signed-off-by: Bob Moore Signed-off-by: Lv Zheng Signed-off-by: Rafael J. Wysocki --- diff --git a/drivers/acpi/acpica/hwgpe.c b/drivers/acpi/acpica/hwgpe.c index ed85fe7494ae..b7fb00d8e4c1 100644 --- a/drivers/acpi/acpica/hwgpe.c +++ b/drivers/acpi/acpica/hwgpe.c @@ -150,7 +150,7 @@ acpi_hw_low_set_gpe(struct acpi_gpe_event_info *gpe_event_info, u32 action) status = acpi_hw_write(enable_mask, &gpe_register_info->enable_address); if (ACPI_SUCCESS(status) && (action & ACPI_GPE_SAVE_MASK)) { - gpe_register_info->enable_mask = enable_mask; + gpe_register_info->enable_mask = (u8)enable_mask; } return (status); }