target/ppc: Deprecate Power8E and Power8NVL
PATCH v2 1/1 target/ppc: Deprecate Power8E and Power8NVL
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 deprecated -- CPU is unmaintained.
...
$ ./build/qemu-system-ppc64 -M powernv8 --cpu power8e -nographic
qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained.
...
$ ./build/qemu-system-ppc64 -M pseries --cpu power8e -nographic
qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- 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
...---
Cover Letter
============
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
=========
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 | 17 ++++++++++++++--- target/ppc/cpu_init.c | 7 ++++++- 3 files changed, 29 insertions(+), 4 deletions(-)
docs/about/deprecated.rst +9 -0
@@ -275,6 +275,15 @@ embedded 405 for power management (OCC) and other internal tasks, it is theoretically possible to use QEMU to model them. Let's keep the CPU implementation for a while before removing all support. +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 ------------------------
target/ppc/cpu-models.c +14 -3
@@ -32,17 +32,22 @@/* 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, _is_deprecated) \ static void \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_class_init) \ (ObjectClass *oc, void *data) \ { \ DeviceClass *dc = DEVICE_CLASS(oc); \ + CPUClass *cc = CPU_CLASS(oc); \ PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc); \ \ pcc->pvr = _pvr; \ pcc->svr = _svr; \ dc->desc = _desc; \ + \ + if (_is_deprecated) { \ + cc->deprecation_note = "CPU is unmaintained."; \ + } \ } \ \ static const TypeInfo \
@@ -63,6 +68,12 @@type_init ( \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_register_types)) +#define POWERPC_DEF_SVR (_name, _desc, _pvr, _svr, _type) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, _svr, _type, false) + +#define POWERPC_DEPRECATED_CPU (_name, _pvr, _type, _desc) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type, true) +#define POWERPC_DEF (_name, _pvr, _type, _desc) \ POWERPC_DEF_SVR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type)
@@ -722,11 +733,11 @@ "POWER7 v2.3") POWERPC_DEF("power7p_v2.1", CPU_POWERPC_POWER7P_v21, POWER7, "POWER7+ v2.1") - POWERPC_DEF("power8e_v2.1", CPU_POWERPC_POWER8E_v21, POWER8, + POWERPC_DEPRECATED_CPU("power8e_v2.1", CPU_POWERPC_POWER8E_v21, POWER8, "POWER8E v2.1") POWERPC_DEF("power8_v2.0", CPU_POWERPC_POWER8_v20, POWER8, "POWER8 v2.0") - POWERPC_DEF("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10, POWER8, + POWERPC_DEPRECATED_CPU("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10, POWER8, "POWER8NVL v1.0")POWERPC_DEF ("power9_v2.0" ,CPU_POWERPC_POWER9_DD20 ,POWER9 ,"POWER9 v2.0" )
target/ppc/cpu_init.c +6 -1
@@ -7143,6 +7143,7 @@ static void ppc_cpu_list_entry(gpointer data, gpointer user_data) {ObjectClass *oc = data;PowerPCCPUClass *pcc =POWERPC_CPU_CLASS (oc); +CPUClass *cc =CPU_CLASS (oc);DeviceClass *family =DEVICE_CLASS (ppc_cpu_get_family_class (pcc));const char *typename =object_class_get_name (oc);char *name;
@@ -7153,7 +7154,11 @@ static void ppc_cpu_list_entry(gpointer data, gpointer user_data) } name =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 =0 ; ppc_cpu_aliases[i].alias !=NULL ; i++) {PowerPCCPUAlias *alias = &ppc_cpu_aliases[i];ObjectClass *alias_oc =ppc_cpu_class_by_name (alias->model);
Signature · 1 line
2.49.0
Hi Aditya,
Quoted 104 lines · Aditya Gupta
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 deprecated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M powernv8 --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M pseries --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- 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édric Le Goater <[email protected]>Signed-off-by Aditya Gupta <[email protected]>---
Cover Letter
============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_notecould 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
=========
v2:
+ add mention todocs/about/deprecated.rst
+ add '(deprecated)' in output of qemu-system-ppc64 --cpu help
------ docs/about/deprecated.rst | 9 +++++++++ target/ppc/cpu-models.c | 17 ++++++++++++++--- target/ppc/cpu_init.c | 7 ++++++- 3 files changed, 29 insertions(+), 4 deletions(-)docs/about/deprecated.rst +9
-0@@ -275,6 +275,15 @@ embedded 405 for power management (OCC) and other internal tasks, it is theoretically possible to use QEMU to model them. Let's keep the CPU implementation for a while before removing all support. +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 ------------------------target/ppc/cpu-models.c +1
-1@@ -32,17 +32,22 @@/* 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, _is_deprecated) \ static void \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_class_init) \ (ObjectClass *oc, void *data) \ { \
target/ppc/cpu-models.c line 49
Quoted 10 lines
target/ppc/cpu-models.c +4
-0DeviceClass *dc =DEVICE_CLASS (oc); \ +CPUClass *cc =CPU_CLASS (oc); \PowerPCCPUClass *pcc =POWERPC_CPU_CLASS (oc); \ \ pcc->pvr = _pvr; \ pcc->svr = _svr; \ dc->desc = _desc; \ + \ +if (_is_deprecated) { \ + cc->deprecation_note ="CPU is unmaintained." ; \
The CPUs deprecated in this patch are indeed unmaintained, but maybe future deprecated ones will have a different reason.
Maybe use s/_is_deprecated/_deprecation_note/, so passing a NULL deprecation note is OK?
cc->deprecation_note = _deprecation_note; \
target/ppc/cpu-models.c line 72
Quoted 10 lines
target/ppc/cpu-models.c +3
-0+ } \ } \ \ static const TypeInfo \@@ -63,6 +68,12 @@type_init ( \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_register_types)) +#define POWERPC_DEF_SVR (_name, _desc, _pvr, _svr, _type) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, _svr, _type, false)
POWERPC_DEF_SVR_DEPR(..., NULL)
target/ppc/cpu-models.c line 737
Quoted 13 lines
target/ppc/cpu-models.c +4
-1+#define POWERPC_DEPRECATED_CPU (_name, _pvr, _type, _desc) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type, true) +#define POWERPC_DEF (_name, _pvr, _type, _desc) \ POWERPC_DEF_SVR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type)@@ -722,11 +733,11 @@ "POWER7 v2.3") POWERPC_DEF("power7p_v2.1", CPU_POWERPC_POWER7P_v21, POWER7, "POWER7+ v2.1") -POWERPC_DEF ("power8e_v2.1" , CPU_POWERPC_POWER8E_v21,POWER8 , +POWERPC_DEPRECATED_CPU ("power8e_v2.1" , CPU_POWERPC_POWER8E_v21,POWER8 ,"POWER8E v2.1" )
POWERPC_DEF_SVR_DEPR("power8e_v2.1", CPU_POWERPC_POWER8E_v21,
POWER8, "POWER8E v2.1",
"CPU is unmaintained")target/ppc/cpu-models.c line 741
Quoted 5 lines
target/ppc/cpu-models.c +1
-1POWERPC_DEF ("power8_v2.0" , CPU_POWERPC_POWER8_v20,POWER8 , "POWER8 v2.0") -POWERPC_DEF ("power8nvl_v1.0" , CPU_POWERPC_POWER8NVL_v10,POWER8 , +POWERPC_DEPRECATED_CPU ("power8nvl_v1.0" , CPU_POWERPC_POWER8NVL_v10,POWER8 ,"POWER8NVL v1.0" )
POWERPC_DEF_SVR_DEPR("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10,
POWER8, "POWER8NVL v1.0",
"CPU is unmaintained")Quoted 27 lines
target/ppc/cpu-models.c +0
-0POWERPC_DEF ("power9_v2.0" ,CPU_POWERPC_POWER9_DD20 ,POWER9 ,"POWER9 v2.0" )target/ppc/cpu_init.c +6
-1@@ -7143,6 +7143,7 @@ static void ppc_cpu_list_entry(gpointer data, gpointer user_data) {ObjectClass *oc = data;PowerPCCPUClass *pcc =POWERPC_CPU_CLASS (oc); +CPUClass *cc =CPU_CLASS (oc);DeviceClass *family =DEVICE_CLASS (ppc_cpu_get_family_class (pcc));const char *typename =object_class_get_name (oc);char *name;@@ -7153,7 +7154,11 @@ static void ppc_cpu_list_entry(gpointer data, gpointer user_data) } name =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 =0 ; ppc_cpu_aliases[i].alias !=NULL ; i++) {PowerPCCPUAlias *alias = &ppc_cpu_aliases[i];ObjectClass *alias_oc =ppc_cpu_class_by_name (alias->model);
Quoted 31 lines · Philippe Mathieu-Daudé
Hi Aditya,
Quoted 14 lines · Aditya Gupta
<...snip...>
target/ppc/cpu-models.c +1
-1@@ -32,17 +32,22 @@/* 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, _is_deprecated) \ static void \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_class_init) \ (ObjectClass *oc, void *data) \ { \target/ppc/cpu-models.c line 49
Quoted 10 lines
target/ppc/cpu-models.c +4
-0DeviceClass *dc =DEVICE_CLASS (oc); \ +CPUClass *cc =CPU_CLASS (oc); \PowerPCCPUClass *pcc =POWERPC_CPU_CLASS (oc); \ \ pcc->pvr = _pvr; \ pcc->svr = _svr; \ dc->desc = _desc; \ + \ +if (_is_deprecated) { \ + cc->deprecation_note ="CPU is unmaintained." ; \The CPUs deprecated in this patch are indeed unmaintained, but maybe future deprecated ones will have a different reason.
Quoted 4 lines
Maybe use s/_is_deprecated/_deprecation_note/, so passing a NULL deprecation note is OK?
cc->deprecation_note = _deprecation_note; \
Makes sense. Thanks, will pass a string then as deprecation message.
Quoted 12 lines
target/ppc/cpu-models.c line 71
Quoted 10 lines
target/ppc/cpu-models.c +3
-0+ } \ } \ \ static const TypeInfo \@@ -63,6 +68,12 @@type_init ( \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_register_types)) +#define POWERPC_DEF_SVR (_name, _desc, _pvr, _svr, _type) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, _svr, _type, false)POWERPC_DEF_SVR_DEPR(..., NULL)
Got it.
Quoted 17 lines
target/ppc/cpu-models.c line 737
Quoted 13 lines
target/ppc/cpu-models.c +4
-1+#define POWERPC_DEPRECATED_CPU (_name, _pvr, _type, _desc) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type, true) +#define POWERPC_DEF (_name, _pvr, _type, _desc) \ POWERPC_DEF_SVR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type)@@ -722,11 +733,11 @@ "POWER7 v2.3") POWERPC_DEF("power7p_v2.1", CPU_POWERPC_POWER7P_v21, POWER7, "POWER7+ v2.1") -POWERPC_DEF ("power8e_v2.1" , CPU_POWERPC_POWER8E_v21,POWER8 , +POWERPC_DEPRECATED_CPU ("power8e_v2.1" , CPU_POWERPC_POWER8E_v21,POWER8 ,"POWER8E v2.1" )POWERPC_DEF_SVR_DEPR("power8e_v2.1", CPU_POWERPC_POWER8E_v21, POWER8, "POWER8E v2.1", "CPU is unmaintained")
Got it.
Quoted 10 lines
target/ppc/cpu-models.c line 741
Quoted 6 lines
target/ppc/cpu-models.c +1
-1POWERPC_DEF ("power8_v2.0" , CPU_POWERPC_POWER8_v20,POWER8 , "POWER8 v2.0") -POWERPC_DEF ("power8nvl_v1.0" , CPU_POWERPC_POWER8NVL_v10,POWER8 , +POWERPC_DEPRECATED_CPU ("power8nvl_v1.0" , CPU_POWERPC_POWER8NVL_v10,POWER8 ,"POWER8NVL v1.0" )POWERPC_DEF_SVR_DEPR("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10, POWER8, "POWER8NVL v1.0", "CPU is unmaintained")
Sure.
Thanks for the reviews, Philippe.
- Aditya G
Quoted 5 lines · Aditya Gupta
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
It is worth mentioning commit c5424f683ee3 ("Remove support for POWER8 DD1") too. In fact, I prefer the cover letter section below for a commit log.
This commit log is not mentioning the introduction of POWERPC_DEPRECATED_CPU. I suggest adding an extra patch for it.
Quoted 5 lines
Deprecate the 8E and 8NVL variants.
After deprecation, QEMU will print a warning like below when the CPU/Chips are used:
Quoted 9 lines
$ ./build/qemu-system-ppc64 -M powernv8 --cpu power8nvl -nographic
qemu-system-ppc64: warning: CPU model power8nvl_v1.0-powerpc64-cpu is deprecated -- CPU is unmaintained.
...
$ ./build/qemu-system-ppc64 -M powernv8 --cpu power8e -nographic
qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained.
...
$ ./build/qemu-system-ppc64 -M pseries --cpu power8e -nographic
qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained.
...This is not very useful and it belongs to a patch adding POWERPC_DEPRECATED_CPU.
Quoted 13 lines
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
ditto.
Quoted 6 lines
Suggested-by Cédric Le Goater <[email protected]>Signed-off-by Aditya Gupta <[email protected]>---
Cover Letter
============
Why don't you use --cover-letter instead ? The rational would be at the beginning.
Quoted 7 lines
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")
Quoted 8 lines
No direct way to deprecate the pnv chips, a field like
deprecation_notecould 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.
Please separate the changes, one patch for POWERPC_DEPRECATED_CPU, another for PowerNV deprecation. More CPUs could be deprecated.
Also, we have time : the QEMU 10.1 development phase has not started and the soft freeze should be around July. No rush needed.
Thanks,
C.
Quoted 113 lines
Changelog
=========
v2:
+ add mention todocs/about/deprecated.rst
+ add '(deprecated)' in output of qemu-system-ppc64 --cpu help
------ docs/about/deprecated.rst | 9 +++++++++ target/ppc/cpu-models.c | 17 ++++++++++++++--- target/ppc/cpu_init.c | 7 ++++++- 3 files changed, 29 insertions(+), 4 deletions(-)docs/about/deprecated.rst +9
-0@@ -275,6 +275,15 @@ embedded 405 for power management (OCC) and other internal tasks, it is theoretically possible to use QEMU to model them. Let's keep the CPU implementation for a while before removing all support. +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 ------------------------target/ppc/cpu-models.c +14
-3@@ -32,17 +32,22 @@/* 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, _is_deprecated) \ static void \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_class_init) \ (ObjectClass *oc, void *data) \ { \ DeviceClass *dc = DEVICE_CLASS(oc); \ + CPUClass *cc = CPU_CLASS(oc); \ PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc); \ \ pcc->pvr = _pvr; \ pcc->svr = _svr; \ dc->desc = _desc; \ + \ + if (_is_deprecated) { \ + cc->deprecation_note = "CPU is unmaintained."; \ + } \ } \ \ static const TypeInfo \@@ -63,6 +68,12 @@type_init ( \ glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_register_types)) +#define POWERPC_DEF_SVR (_name, _desc, _pvr, _svr, _type) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, _svr, _type, false) + +#define POWERPC_DEPRECATED_CPU (_name, _pvr, _type, _desc) \ + POWERPC_DEF_SVR_DEPR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type, true) +#define POWERPC_DEF (_name, _pvr, _type, _desc) \ POWERPC_DEF_SVR(_name, _desc, _pvr, POWERPC_SVR_NONE, _type)@@ -722,11 +733,11 @@ "POWER7 v2.3") POWERPC_DEF("power7p_v2.1", CPU_POWERPC_POWER7P_v21, POWER7, "POWER7+ v2.1") - POWERPC_DEF("power8e_v2.1", CPU_POWERPC_POWER8E_v21, POWER8, + POWERPC_DEPRECATED_CPU("power8e_v2.1", CPU_POWERPC_POWER8E_v21, POWER8, "POWER8E v2.1") POWERPC_DEF("power8_v2.0", CPU_POWERPC_POWER8_v20, POWER8, "POWER8 v2.0") - POWERPC_DEF("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10, POWER8, + POWERPC_DEPRECATED_CPU("power8nvl_v1.0", CPU_POWERPC_POWER8NVL_v10, POWER8, "POWER8NVL v1.0")POWERPC_DEF ("power9_v2.0" ,CPU_POWERPC_POWER9_DD20 ,POWER9 ,"POWER9 v2.0" )target/ppc/cpu_init.c +6
-1@@ -7143,6 +7143,7 @@ static void ppc_cpu_list_entry(gpointer data, gpointer user_data) {ObjectClass *oc = data;PowerPCCPUClass *pcc =POWERPC_CPU_CLASS (oc); +CPUClass *cc =CPU_CLASS (oc);DeviceClass *family =DEVICE_CLASS (ppc_cpu_get_family_class (pcc));const char *typename =object_class_get_name (oc);char *name;@@ -7153,7 +7154,11 @@ static void ppc_cpu_list_entry(gpointer data, gpointer user_data) } name =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 =0 ; ppc_cpu_aliases[i].alias !=NULL ; i++) {PowerPCCPUAlias *alias = &ppc_cpu_aliases[i];ObjectClass *alias_oc =ppc_cpu_class_by_name (alias->model);
Quoted 7 lines · Cédric Le Goater
Quoted 5 lines · Aditya Gupta
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
Quoted 6 lines
It is worth mentioning commit
c5424f683ee3("Remove support for POWER8 DD1") too. In fact, I prefer the cover letter section below for a commit log.This commit log is not mentioning the introduction of
POWERPC_DEPRECATED_CPU. I suggest adding an extra patch for it.
Got it. Sure will include that mention in patch deprecating 8e/8nvl.
Quoted 16 lines
Quoted 6 lines
Deprecate the 8E and 8NVL variants.
After deprecation, QEMU will print a warning like below when the CPU/Chips are used:
Quoted 9 lines
$ ./build/qemu-system-ppc64 -M powernv8 --cpu power8nvl -nographic qemu-system-ppc64: warning: CPU model power8nvl_v1.0-powerpc64-cpu is deprecated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M powernv8 --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M pseries --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained. ...
Quoted 2 lines
This is not very useful and it belongs to a patch adding
POWERPC_DEPRECATED_CPU.
Got it.
Quoted 16 lines
Quoted 4 lines
Also, print '(deprecated)' for deprecated CPUs in 'qemu-system-ppc64 --cpu ?':
Quoted 10 lines
$ ./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
Quoted 1 line
ditto.
Got it.
Quoted 11 lines
Quoted 7 lines
Suggested-by Cédric Le Goater <[email protected]>Signed-off-by Aditya Gupta <[email protected]>---
Cover Letter
============Why don't you use --cover-letter instead ? The rational would be at the beginning.
Sure, I will from next time. I generally write a small cover letter with the patch for single patches, and use --cover-letter for multiple patch series.
Quoted 13 lines
Quoted 13 lines
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_notecould 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.
Quoted 6 lines
Quoted 3 lines
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.
Please separate the changes, one patch for
POWERPC_DEPRECATED_CPU, another for PowerNV deprecation. More CPUs could be deprecated.
By PowerNV deprecation, you mean Power8E/8NVL CPUs right ?
Like there's no powernv8e machine as such, and powernv8e chip doesn't have a way to deprecate. I can add a 'deprecation_note' kind of field, but feel that is unnecessary, as it only gets used when power8e CPU is used, which will show one deprecation warning already.
Quoted 3 lines
Also, we have time : the QEMU 10.1 development phase has not started and the soft freeze should be around July. No rush needed.
Sure, thanks for the detail
Thanks,
- Aditya G
Quoted 4 lines
Thanks,
C.
Quoted 65 lines · Aditya Gupta
Quoted 7 lines · Cédric Le Goater
Quoted 5 lines · Aditya Gupta
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
Quoted 6 lines
It is worth mentioning commit
c5424f683ee3("Remove support for POWER8 DD1") too. In fact, I prefer the cover letter section below for a commit log.This commit log is not mentioning the introduction of
POWERPC_DEPRECATED_CPU. I suggest adding an extra patch for it.Got it. Sure will include that mention in patch deprecating 8e/8nvl.
Quoted 16 lines
Quoted 6 lines
Deprecate the 8E and 8NVL variants.
After deprecation, QEMU will print a warning like below when the CPU/Chips are used:
Quoted 9 lines
$ ./build/qemu-system-ppc64 -M powernv8 --cpu power8nvl -nographic qemu-system-ppc64: warning: CPU model power8nvl_v1.0-powerpc64-cpu is deprecated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M powernv8 --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained. ... $ ./build/qemu-system-ppc64 -M pseries --cpu power8e -nographic qemu-system-ppc64: warning: CPU model power8e_v2.1-powerpc64-cpu is deprecated -- CPU is unmaintained. ...Quoted 2 lines
This is not very useful and it belongs to a patch adding
POWERPC_DEPRECATED_CPU.Got it.
Quoted 16 lines
Quoted 4 lines
Also, print '(deprecated)' for deprecated CPUs in 'qemu-system-ppc64 --cpu ?':
Quoted 10 lines
$ ./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 004e1202Quoted 1 line
ditto.
Got it.
Quoted 5 lines
Quoted 5 lines
Suggested-by Cédric Le Goater <[email protected]>Signed-off-by Aditya Gupta <[email protected]>---
Quoted 10 lines
By PowerNV deprecation, you mean Power8E/8NVL CPUs right ?
Like there's no powernv8e machine as such, and powernv8e chip doesn't have a way to deprecate. I can add a '
deprecation_note' kind of field, but feel that is unnecessary, as it only gets used when power8e CPU is used, which will show one deprecation warning already.Quoted 3 lines
Also, we have time : the QEMU 10.1 development phase has not started and the soft freeze should be around July. No rush needed.
Pre-release period is normally OK to deprecate things (Cc'ing Thomas in doubt...).
Quoted 6 lines
Quoted 3 lines
Quoted 3 lines
Also, we have time : the QEMU 10.1 development phase has not started and the soft freeze should be around July. No rush needed.
Pre-release period is normally OK to deprecate things (Cc'ing Thomas in doubt...).
I thought this was a fixes-only period, which might warrant spending some time on evenings or weekends. I wouldn't do that for deprecation patches.
Thanks,
C.
Quoted 5 lines
Quoted 3 lines
Please separate the changes, one patch for
POWERPC_DEPRECATED_CPU, another for PowerNV deprecation. More CPUs could be deprecated.By PowerNV deprecation, you mean Power8E/8NVL CPUs right ?
yes. Just the CPUs which implies the chips.
Quoted 4 lines
Like there's no powernv8e machine as such, and powernv8e chip doesn't have a way to deprecate. I can add a '
deprecation_note' kind of field, but feel that is unnecessary, as it only gets used when power8e CPU is used, which will show one deprecation warning already.
It is fine.
Thanks,
C.