Thread (21 messages) flat view 21 messages, 3 authors, 2017-07-11

Re: [PATCH 2/5] powernv:idle: Change return type of pnv_probe_idle_states to int

From: Nicholas Piggin <npiggin@gmail.com>
Date: 2017-07-06 15:02:05
Also in: linux-pm, lkml

On Wed,  5 Jul 2017 22:08:13 +0530
"Gautham R. Shenoy" [off-list ref] wrote:
From: "Gautham R. Shenoy" <redacted>

In the current idle initialization code, if there are failures in
pnv_probe_idle_states, then no platform idle state is
enabled. However, since the error is not propagated to the top-level
function pnv_init_idle_states, we continue initialization in this
top-level function even though this will never be used.

Hence change the the return type of pnv_probe_idle_states from void to
int and in case of failures, bail out early on in
pnv_init_idle_states.

Signed-off-by: Gautham R. Shenoy <redacted>
Looks good to me.

Reviewed-by: Nicholas Piggin <npiggin@gmail.com>

I wonder if the warnings are strong enough here to let people know
idle won't be used so power consumption will be high and performance
significantly reduced on SMT machines?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help