powernv/cpuidle: Parse dt idle properties into global structure
authorAkshay Adiga <akshay.adiga@linux.vnet.ibm.com>
Thu, 5 Jul 2018 11:40:21 +0000 (17:10 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 31 Jul 2018 09:56:44 +0000 (19:56 +1000)
commit9c7b185ab2fe313b4426bf55da3624bef71f342b
tree60a19672ec4a83fcfab6cc08231936f9b6e3087c
parent6edc22fc9cbb80fdf929df3e5b912d8c42e0ff3a
powernv/cpuidle: Parse dt idle properties into global structure

Device-tree parsing happens twice, once while deciding idle state to be
used for hotplug and once during cpuidle init. Hence, parsing the device
tree and caching it will reduce code duplication. Parsing code has been
moved to pnv_parse_cpuidle_dt() from pnv_probe_idle_states(). In addition
to the properties in the device tree the number of available states is
also required.

Signed-off-by: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com>
Reviewed-by: Nicholas Piggin <npiggin@gmail.com>
Reviewed-by: Gautham R. Shenoy <ego@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/cpuidle.h
arch/powerpc/platforms/powernv/idle.c