Skip to content
Commit 0baa91cb authored by Anton Blanchard's avatar Anton Blanchard Committed by Rafael J. Wysocki
Browse files

cpuidle: powernv: Avoid a branch in the core snooze_loop() loop



When in the snooze_loop() we want to take up the least amount of
resources. On my version of gcc (6.3), we end up with an extra
branch because it predicts snooze_timeout_en to be false, whereas it
is almost always true.

Use likely() to avoid the branch and be a little nicer to the
other non idle threads on the core.

Signed-off-by: default avatarAnton Blanchard <anton@samba.org>
Reviewed-by: default avatarVaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent 26eb48a9
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment