From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from hr2.samba.org (hr2.samba.org [IPv6:2a01:4f8:192:486::147:1]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 3qdq5F0KcCzDqF7 for ; Mon, 4 Apr 2016 21:09:53 +1000 (AEST) Date: Mon, 4 Apr 2016 21:09:28 +1000 From: Anton Blanchard To: Alexey Kardashevskiy , Michael Ellerman , Paul Mackerras , Benjamin Herrenschmidt , Michael Neuling , David Gibson , Alexander Graf Cc: linuxppc-dev@lists.ozlabs.org, qemu-devel@nongnu.org, qemu-ppc@nongnu.org Subject: [PATCH] spapr: Don't set the TM ibm,pa-features bit in PR KVM mode Message-ID: <20160404210928.0d9ae644@kryten> In-Reply-To: <20160404204346.1cf44df8@kryten> References: <20160404164457.539a55f0@kryten> <57021123.6050506@ozlabs.ru> <20160404204346.1cf44df8@kryten> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , We don't support transactional memory in PR KVM, so don't tell the OS that we do. Signed-off-by: Anton Blanchard --- diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index e7be21e..538bd87 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -696,6 +696,12 @@ static void spapr_populate_cpu_dt(CPUState *cs, void *fdt, int offset, } else /* env->mmu_model == POWERPC_MMU_2_07 */ { pa_features = pa_features_207; pa_size = sizeof(pa_features_207); + + /* Don't enable TM in PR KVM mode */ + if (kvm_enabled() && + kvm_vm_check_extension(cs->kvm_state, KVM_CAP_PPC_GET_PVINFO)) { + pa_features[24] &= ~0x80; + } } if (env->ci_large_pages) { pa_features[3] |= 0x20;