linux/drivers/cpuidle/governors
Rafael J. Wysocki a802ea9645 cpuidle: Check the sign of index in cpuidle_reflect()
Avoid calling the governor's ->reflect method if the state index
passed to cpuidle_reflect() is negative.

This allows the analogous check to be dropped from menu_reflect(),
so do that too, and ensures that arbitrary error codes can be
passed to cpuidle_reflect() as the index with no adverse
consequences.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
2015-05-04 22:53:28 +02:00
..
ladder.c cpuidle: ladder: Better idle duration measurement without using CPUIDLE_FLAG_TIME_INVALID 2014-12-17 02:26:28 +01:00
Makefile
menu.c cpuidle: Check the sign of index in cpuidle_reflect() 2015-05-04 22:53:28 +02:00