]> git.baikalelectronics.ru Git - kernel.git/commit
ACPI / CPPC: Use 64-bit arithmetic instead of 32-bit
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Tue, 6 Feb 2018 23:36:17 +0000 (17:36 -0600)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 7 Feb 2018 10:15:02 +0000 (11:15 +0100)
commitb8f48251c944c751a0e05c5e5180988f5e6736b7
tree472e39c7427a8e3dd1d29232b06c92140d0227da
parent7b935181c92e7eef02d9892d34e6ffaad33e841f
ACPI / CPPC: Use 64-bit arithmetic instead of 32-bit

Add suffix ULL to constant 500 in order to give the compiler complete
information about the proper arithmetic to use. Notice that this
constant is used in a context that expects an expression of type
u64 (64 bits, unsigned).

The expression NUM_RETRIES * cppc_ss->latency at line 578, which at
preprocessing time translates to 500 * cppc_ss->latency is currently
being evaluated using 32-bit arithmetic.

Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/cppc_acpi.c