From nobody Thu Apr 3 10:02:39 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=reject dis=none) header.from=linux.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1743369121; cv=none; d=zohomail.com; s=zohoarc; b=V3cjEQWldqWR1wfylv09A32thWNMn5jahE0ZMrkkoJ++y8r9TYDisSZGwd4qdyWB7rqVDZNR2zjkr2lqQHzc2U7lUAVuDHwpdpCyrvAQQTDuW9GJThQs5/5xQeNkq9YyYWvIM6q+Hrd10L6dVfe8KZEhCmCBKqsyAMzyRk0QvXA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1743369121; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=XKtSp9BqkUrT/Y4Y75YL9Bl9fgRNVWeixOj4qZbXsjk=; b=RLlywqAJWkHyw1l1gRFcClcw58YgviQtaJdcCx5dhVzSoztH35mTZohbuwKzDzAJf4W+kBreMMvh1PlR2YEe6uP7+gwKY5vOMxJ+FeMchX3/kbnpALruSJvwd5xBDoDg+Q9BGSUWVX2ywHkTjyL+cvjOdvLxXSv1lrT5HRnacgA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 174336912169912.356799575762238; Sun, 30 Mar 2025 14:12:01 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tyzw1-00013O-0Y; Sun, 30 Mar 2025 17:11:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tyzvz-00013A-4L; Sun, 30 Mar 2025 17:11:11 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tyzvt-0000UX-UV; Sun, 30 Mar 2025 17:11:10 -0400 Received: from pps.filterd (m0360072.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 52UHD972031867; Sun, 30 Mar 2025 21:10:32 GMT Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 45qa4wrkfy-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sun, 30 Mar 2025 21:10:32 +0000 (GMT) Received: from m0360072.ppops.net (m0360072.ppops.net [127.0.0.1]) by pps.reinject (8.18.0.8/8.18.0.8) with ESMTP id 52ULAVUj015975; Sun, 30 Mar 2025 21:10:31 GMT Received: from ppma13.dal12v.mail.ibm.com (dd.9e.1632.ip4.static.sl-reverse.com [50.22.158.221]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 45qa4wrkfx-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sun, 30 Mar 2025 21:10:31 +0000 (GMT) Received: from pps.filterd (ppma13.dal12v.mail.ibm.com [127.0.0.1]) by ppma13.dal12v.mail.ibm.com (8.18.1.2/8.18.1.2) with ESMTP id 52UJTUV6006620; Sun, 30 Mar 2025 21:10:31 GMT Received: from smtprelay06.fra02v.mail.ibm.com ([9.218.2.230]) by ppma13.dal12v.mail.ibm.com (PPS) with ESMTPS id 45pwdk2vdw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sun, 30 Mar 2025 21:10:30 +0000 Received: from smtpav06.fra02v.mail.ibm.com (smtpav06.fra02v.mail.ibm.com [10.20.54.105]) by smtprelay06.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 52ULAReK21955012 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 30 Mar 2025 21:10:27 GMT Received: from smtpav06.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 56B3F20049; Sun, 30 Mar 2025 21:10:27 +0000 (GMT) Received: from smtpav06.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id DB8B320040; Sun, 30 Mar 2025 21:10:24 +0000 (GMT) Received: from li-3c92a0cc-27cf-11b2-a85c-b804d9ca68fa.ibm.com (unknown [9.39.31.121]) by smtpav06.fra02v.mail.ibm.com (Postfix) with ESMTP; Sun, 30 Mar 2025 21:10:24 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=cc :content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to; s=pp1; bh=XKtSp9BqkUrT/Y4Y75YL9Bl9fgRN VWeixOj4qZbXsjk=; b=m7QnjEFXiG3siunxH5XxmBiENV/GQPSC3+BufUgiFjy7 Rl3Q7ERSD5FTYQjC1HN+ni2GXYG+J2sT3H3X480n/5ut0OX4kqHOiHphJgYdvFiD q6rDR91hal5UuyUa0kDuOdlOTr6xLbqO2MfOlZVN9JgmYtIhbnxO8rENpV9xJrA0 7KdibYykd/QGwgbIWuf9lnb0Ba7X3zdJyZ+WDYQ6BRhw4DKOGToKclbVumUV4C11 qTIbxXLK2hIlTnl9MCDLYXEGRmCFTnm3hJ/c+NwaUPdT7GEd46UvUB+WeloHLGWE dAE265F/jJ7UFZWdiwKdKTJsF+G1Xi1mu44GE8F7qQ== From: Aditya Gupta To: =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Nicholas Piggin , Daniel Henrique Barboza , Mahesh J Salgaonkar , Madhavan Srinivasan Cc: , Subject: [PATCH v4] target/ppc: Deprecate Power8E and Power8NVL Date: Mon, 31 Mar 2025 02:40:12 +0530 Message-ID: <20250330211012.2932258-1-adityag@linux.ibm.com> X-Mailer: git-send-email 2.49.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 X-Proofpoint-GUID: lLfJlHOBzTezE-xlPkJF_f2XiTzmZa4B X-Proofpoint-ORIG-GUID: YQqkuVm2FqAs9ZyKvkbl81Cu9aEHGJcy X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1095,Hydra:6.0.680,FMLib:17.12.68.34 definitions=2025-03-30_09,2025-03-27_02,2024-11-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 impostorscore=0 priorityscore=1501 mlxscore=0 suspectscore=0 lowpriorityscore=0 clxscore=1015 mlxlogscore=999 phishscore=0 malwarescore=0 spamscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2502280000 definitions=main-2503300148 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=148.163.158.5; envelope-from=adityag@linux.ibm.com; helo=mx0b-001b2d01.pphosted.com X-Spam_score_int: -36 X-Spam_score: -3.7 X-Spam_bar: --- X-Spam_report: (-3.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H5=-1, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @ibm.com) X-ZM-MESSAGEID: 1743369124029019000 Power8E and Power8NVL variants are not of much use in QEMU now, and not being maintained either. Newer skiboot might not be able to boot Power8NVL since skiboot v7.0 Deprecate the 8E and 8NVL variants. After deprecation, QEMU will print a warning like below when the CPU/Chips are used: $ ./build/qemu-system-ppc64 -M powernv8 --cpu power8nvl -nographic qemu-system-ppc64: warning: CPU model power8nvl_v1.0-powerpc64-cpu is d= eprecated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M powernv8 --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is dep= recated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M pseries --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is dep= recated -- CPU is unmaintained. ... Also, print '(deprecated)' for deprecated CPUs in 'qemu-system-ppc64 --cpu ?': $ ./build/qemu-system-ppc64 --cpu help ... power8e_v2.1 PVR 004b0201 (deprecated) power8e (alias for power8e_v2.1) power8nvl_v1.0 PVR 004c0100 (deprecated) power8nvl (alias for power8nvl_v1.0) power8_v2.0 PVR 004d0200 power8 (alias for power8_v2.0) power9_v2.0 PVR 004e1200 power9_v2.2 PVR 004e1202 ... Suggested-by: C=C3=A9dric Le Goater Signed-off-by: Aditya Gupta Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- Cover Letter =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Power8E and Power8NVL are not maintained, and not useful to qemu, and upstream skiboot also has removed support till Power8 DD1. Power8NVL CPU doesn't boot since skiboot v7.0, or following skiboot commit to be exact: commit c5424f683ee3 ("Remove support for POWER8 DD1") No direct way to deprecate the pnv chips, a field like deprecation_note could be added, but felt not needed as the chip will only get used if the user requests corresponding 8E / 8NVL CPU, which will print deprecation warning. Also, no separate pnv machine for 8E and 8NVL, user has to pass --cpu, which will throw the deprecation warning. So just deprecating CPUs should be enough. Changelog =3D=3D=3D=3D=3D=3D=3D=3D=3D v4: + remove unnecessary 'if' v3: + add 'deprecation_note' argument to the POWERPC_DEPRECATED_CPU macro v2: + add mention to docs/about/deprecated.rst + add '(deprecated)' in output of qemu-system-ppc64 --cpu help --- --- docs/about/deprecated.rst | 9 +++++++++ target/ppc/cpu-models.c | 20 +++++++++++++++----- target/ppc/cpu_init.c | 7 ++++++- 3 files changed, 30 insertions(+), 6 deletions(-) diff --git a/docs/about/deprecated.rst b/docs/about/deprecated.rst index e2b4f077d453..d6b39db2aaca 100644 --- a/docs/about/deprecated.rst +++ b/docs/about/deprecated.rst @@ -275,6 +275,15 @@ embedded 405 for power management (OCC) and other inte= rnal tasks, it is theoretically possible to use QEMU to model them. Let's keep the CPU implementation for a while before removing all support. =20 +Power8E and Power8NVL CPUs and corresponding Pnv chips (since 10.0) +''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' + +The Power8E and Power8NVL variants of Power8 are not really useful anymore +in qemu, and are old and unmaintained now. + +The CPUs as well as corresponding Power8NVL and Power8E PnvChips will also +be considered deprecated. + System emulator machines ------------------------ =20 diff --git a/target/ppc/cpu-models.c b/target/ppc/cpu-models.c index ece348178188..cc79a6373d63 100644 --- a/target/ppc/cpu-models.c +++ b/target/ppc/cpu-models.c @@ -32,17 +32,20 @@ /* PowerPC CPU definitions = */ #define POWERPC_DEF_PREFIX(pvr, svr, type) = \ glue(glue(glue(glue(pvr, _), svr), _), type) -#define POWERPC_DEF_SVR(_name, _desc, _pvr, _svr, _type) = \ +#define POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, _svr, _type, _deprecation= _note) \ static void = \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_class_init) = \ (ObjectClass *oc, void *data) = \ { = \ DeviceClass *dc =3D DEVICE_CLASS(oc); = \ + CPUClass *cc =3D CPU_CLASS(oc); = \ PowerPCCPUClass *pcc =3D POWERPC_CPU_CLASS(oc); = \ = \ pcc->pvr =3D _pvr; = \ pcc->svr =3D _svr; = \ dc->desc =3D _desc; = \ + = \ + cc->deprecation_note =3D _deprecation_note; = \ } = \ = \ static const TypeInfo = \ @@ -63,6 +66,13 @@ type_init( = \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_register_types)) =20 +#define POWERPC_DEF_SVR(_name, _desc, _pvr, _svr, _type) = \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, _svr, _type, NULL) + +#define POWERPC_DEPRECATED_CPU(_name, _pvr, _type, _desc, _deprecation_not= e)\ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type, = \ + _deprecation_note) + #define POWERPC_DEF(_name, _pvr, _type, _desc) = \ POWERPC_DEF_SVR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type) =20 @@ -722,12 +732,12 @@ "POWER7 v2.3") POWERPC_DEF("power7p_v2.1", CPU_POWERPC_POWER7P_v21, POWER= 7, "POWER7+ v2.1") - POWERPC_DEF("power8e_v2.1", CPU_POWERPC_POWER8E_v21, POWER= 8, - "POWER8E v2.1") + POWERPC_DEPRECATED_CPU("power8e_v2.1", CPU_POWERPC_POWER8E_v21, POWER= 8, + "POWER8E v2.1", "CPU is unmaintained.") POWERPC_DEF("power8_v2.0", CPU_POWERPC_POWER8_v20, POWER= 8, "POWER8 v2.0") - POWERPC_DEF("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10, POWER= 8, - "POWER8NVL v1.0") + POWERPC_DEPRECATED_CPU("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10, PO= WER8, + "POWER8NVL v1.0", "CPU is unmaintained.") POWERPC_DEF("power9_v2.0", CPU_POWERPC_POWER9_DD20, POWER= 9, "POWER9 v2.0") POWERPC_DEF("power9_v2.2", CPU_POWERPC_POWER9_DD22, POWER= 9, diff --git a/target/ppc/cpu_init.c b/target/ppc/cpu_init.c index 7decc09aec8f..fade53f7e2d6 100644 --- a/target/ppc/cpu_init.c +++ b/target/ppc/cpu_init.c @@ -7143,6 +7143,7 @@ static void ppc_cpu_list_entry(gpointer data, gpointe= r user_data) { ObjectClass *oc =3D data; PowerPCCPUClass *pcc =3D POWERPC_CPU_CLASS(oc); + CPUClass *cc =3D CPU_CLASS(oc); DeviceClass *family =3D DEVICE_CLASS(ppc_cpu_get_family_class(pcc)); const char *typename =3D object_class_get_name(oc); char *name; @@ -7153,7 +7154,11 @@ static void ppc_cpu_list_entry(gpointer data, gpoint= er user_data) } =20 name =3D cpu_model_from_type(typename); - qemu_printf(" %-16s PVR %08x\n", name, pcc->pvr); + if (cc->deprecation_note) { + qemu_printf(" %-16s PVR %08x (deprecated)\n", name, pcc->pvr); + } else { + qemu_printf(" %-16s PVR %08x\n", name, pcc->pvr); + } for (i =3D 0; ppc_cpu_aliases[i].alias !=3D NULL; i++) { PowerPCCPUAlias *alias =3D &ppc_cpu_aliases[i]; ObjectClass *alias_oc =3D ppc_cpu_class_by_name(alias->model); --=20 2.49.0