powernv/cpuidle: Fix idle states all being marked invalid

Commit 9c7b185ab2 ("powernv/cpuidle: Parse dt idle properties into
global structure") parses dt idle states into structs, but never marks
them valid. This results in all idle states being lost.

Fixes: 9c7b185ab2 ("powernv/cpuidle: Parse dt idle properties into global structure")
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Acked-by: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
This commit is contained in:
Nicholas Piggin 2018-08-03 01:39:51 +10:00 committed by Michael Ellerman
parent b87b9cf493
commit 3127692deb
1 changed files with 2 additions and 1 deletions

View File

@ -651,11 +651,12 @@ static int __init pnv_power9_idle_init(void)
&state->psscr_mask,
state->flags);
if (err) {
state->valid = false;
report_invalid_psscr_val(state->psscr_val, err);
continue;
}
state->valid = true;
if (max_residency_ns < state->residency_ns) {
max_residency_ns = state->residency_ns;
pnv_deepest_stop_psscr_val = state->psscr_val;