summaryrefslogtreecommitdiffstats
path: root/hw/slw.c
Commit message (Collapse)AuthorAgeFilesLines
...
* slw: Add winkle to cpuidle states in device treeShreyas B. Prabhu2014-07-301-39/+101
| | | | | | | | | | Clean up current implementation of adding idle states to device tree, to make it more generic. Add winkle to list of cpu-idle states if slw image is intact. Signed-off-by: Shreyas B. Prabhu <shreyas@linux.vnet.ibm.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
* slw: Enable fast sleep and deep winkle while initializing coreShreyas B. Prabhu2014-07-301-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Power8 hardware supports deep idle states like sleep and winkle. Both sleep and winkle have fast/deep modes. Behaviour of each mode - Fast sleep Stop clocks to Core and L2 cache. Drop Core & L2 voltage to retention. Leave shared L3 cache running Deep sleep Power OFF the core and private L2 cache. Leave shared L3 cache running. Fast winkle Stop clocks to entire chiplet. Drop chiplet voltage to retention. Deep winkle Power OFF the entire chiplet. Requires restore/re-init to wakeup. PM GP1 register allows us to select fast/deep modes for sleep and winkle. Currently we are setting PM GP1 register to use fast sleep and fast winkle. Change it such that, sleep will use fast mode and winkle will use deep mode. With deep winkle enabled, hotplug framework in kernel can send cores to winkle when cpus are offlined. Signed-off-by: Shreyas B. Prabhu <shreyas@linux.vnet.ibm.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
* sleep: Add workarounds for fast sleepVaidyanathan Srinivasan2014-07-301-1/+88
| | | | | | | | | | | | | | | | | Add OPAL calls to setup xscom before and after sleep V1:https://w3-01.ibm.com/stg/linux/ltc/mailinglists/pipermail/sapphire/2014-July/003170.html Changes in V2: 1.Store L2 Fir Action register contents in primary thread's pointer 2.Enable secondary threads also to call opal, now that the synchronization across threads of a core will be taken care of by the kernel. We can hence safely call fastsleep in smt on mode. Signed-off-by: Vaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com> Signed-off-by: Preeti U Murthy <preeti@linux.vnet.ibm.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
* slw: Change bit used to expose sleep supportBenjamin Herrenschmidt2014-07-221-4/+5
| | | | | | | | | Due to an errata in P8, we cannot let the OS use the sleep instruction without some extra workarounds in the OS. So let's use a different bit to represent that support so that existing OSes without the workaround don't enable support for sleep mode. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
* Initial commit of Open Source releaseBenjamin Herrenschmidt2014-07-021-0/+875
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
OpenPOWER on IntegriCloud