Before I incorrectly enabled napping also for BookE, which would result in
needless dcache flushes. Since we only need to force enable napping on
Book3s_64 because it doesn't go into MSR_POW otherwise, we can just #ifdef
that code to this particular platform.

Reported-by: Scott Wood <[email protected]>
Signed-off-by: Alexander Graf <[email protected]>
---
 arch/powerpc/kernel/kvm.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/powerpc/kernel/kvm.c b/arch/powerpc/kernel/kvm.c
index 95aed6b..293765a 100644
--- a/arch/powerpc/kernel/kvm.c
+++ b/arch/powerpc/kernel/kvm.c
@@ -583,8 +583,10 @@ static int __init kvm_guest_init(void)
        if (kvm_para_has_feature(KVM_FEATURE_MAGIC_PAGE))
                kvm_use_magic_page();
 
+#ifdef CONFIG_PPC_BOOK3S_64
        /* Enable napping */
        powersave_nap = 1;
+#endif
 
 free_tmp:
        kvm_free_tmp();
-- 
1.6.0.2

--
To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to