From nobody Fri May 3 10:43:47 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1494306364965520.4494125117182; Mon, 8 May 2017 22:06:04 -0700 (PDT) Received: from localhost ([::1]:34978 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d7xLW-0006wv-8A for importer@patchew.org; Tue, 09 May 2017 01:06:02 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39406) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d7xKi-0006al-BK for qemu-devel@nongnu.org; Tue, 09 May 2017 01:05:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d7xKh-0008Mo-CZ for qemu-devel@nongnu.org; Tue, 09 May 2017 01:05:12 -0400 Received: from ozlabs.org ([2401:3900:2:1::2]:54739) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1d7xKg-0008JD-Hx; Tue, 09 May 2017 01:05:11 -0400 Received: by ozlabs.org (Postfix, from userid 1007) id 3wMS3d73q8z9s7C; Tue, 9 May 2017 15:05:01 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gibson.dropbear.id.au; s=201602; t=1494306301; bh=ZXWkhVzxggoKnI3RmAVzsd6iBDwEFSM6QVWchuvbwOo=; h=From:To:Cc:Subject:Date:From; b=WAq9BRajwPvf5zSVieA3WsRAGewTN/5X537zebzqaSnG+1X6p9e9vCPk1NIU+TGnS yexiNwF3QKteqJVhJaiddE1AW2Nqj8c/OR+9KJStjkTl6iQp2sEB8e8eJaTaYe5BPE 9W+weDDRcO9U35A9hI7wM28nMidr+PaIPVS8+k2s= From: David Gibson To: sam.bobroff@au1.ibm.com, thuth@redhat.com Date: Tue, 9 May 2017 15:04:58 +1000 Message-Id: <20170509050458.23237-1-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.9.3 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2401:3900:2:1::2 Subject: [Qemu-devel] [PATCH] spapr: Don't accidentally advertise HTM support on POWER9 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: lvivier@redhat.com, aik@ozlabs.ru, qemu-devel@nongnu.org, mdroth@linux.vnet.ibm.com, qemu-ppc@nongnu.org, bharata@linux.vnet.ibm.com, David Gibson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Logic in spapr_populate_pa_features() enables the bit advertising Hardware Transactional Memory (HTM) in the guest's device tree only when KVM advertises its availability with the KVM_CAP_PPC_HTM feature. However, this assumes that the HTM bit is off in the base template used for the device tree value. That is true for POWER8, but not for POWER9. It looks like that was accidentally changed in 9fb4541 "spapr: Enable ISA 3.0 MMU mode selection via CAS". Fixes: 9fb4541f5803f8d2ba116b12113386e26482ba30 Signed-off-by: David Gibson Reviewed-by: Sam Bobroff Reviewed-by: Thomas Huth --- hw/ppc/spapr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index e2dc77c..1b7cada 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -219,7 +219,7 @@ static void spapr_populate_pa_features(CPUPPCState *env= , void *fdt, int offset, /* 16: Vector */ 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, /* 12 - 17 */ /* 18: Vec. Scalar, 20: Vec. XOR, 22: HTM */ - 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, /* 18 - 23 */ + 0x80, 0x00, 0x80, 0x00, 0x00, 0x00, /* 18 - 23 */ /* 24: Ext. Dec, 26: 64 bit ftrs, 28: PM ftrs */ 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, /* 24 - 29 */ /* 30: MMR, 32: LE atomic, 34: EBB + ext EBB */ --=20 2.9.3