Skip to content
Snippets Groups Projects
Commit 40ab82e0 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki
Browse files

intel_idle: Simplify LAPIC timer reliability checks


The lapic_timer_always_reliable variable really takes only two values
and some arithmetic in intel_idle() related to comparing it with the
target C-state's MWAIT hint value is unnecessary.

Simplify the code by replacing lapic_timer_always_reliable with
a bool variable lapic_timer_always_reliable and dropping the
LAPIC_TIMER_ALWAYS_RELIABLE symbol along with the excess
computations in intel_idle().

While at it, add a comment explaining the branch taken in intel_idle()
if the LAPIC timer is only reliable in C1 and modify the related debug
message in intel_idle_init() accordingly (the modification of this
message in the only expected functional impact of the change made
here).

Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent bb6d3fb3
Branches
Tags v4.17
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment