* [Qemu-devel] [PATCH v3] ppc: Deprecate qemu-system-ppcemb
@ 2018-01-21 21:57 Thomas Huth
2018-01-22 8:18 ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2018-01-22 13:53 ` [Qemu-devel] " David Gibson
0 siblings, 2 replies; 3+ messages in thread
From: Thomas Huth @ 2018-01-21 21:57 UTC (permalink / raw)
To: qemu-devel; +Cc: David Gibson, qemu-ppc
qemu-system-ppcemb has been once split of qemu-system-ppc to support
CPU page sizes < 4096 for some of the embedded 4xx PowerPC CPUs.
However, there was hardly any OS available in the wild that really
used such small page sizes (Linux uses 4096 on PPC), so there is
no known recent use case for this separate build anymore. It's
rather cumbersome to maintain a separate set of config switches for
this, and it's wasting compile and test time of all the developers
who have to build all QEMU targets to verify that their changes did
not break anything.
Except for the small CPU page sizes, qemu-system-ppc can be used as
a full replacement for qemu-system-ppcemb since it contains all the
embedded 4xx PPC boards and CPUs, too. Thus let's start the deprecation
process for qemu-system-ppcemb to see whether somebody still needs
the small page sizes or whether we could finally remove this unloved
separate build.
Signed-off-by: Thomas Huth <thuth@redhat.com>
---
v3: Use qtest_enabled() and emit the deprecation message in the
machine init functions (I unfortunately haven't found a better
common spot for all 4xx machines where qtest_enabled() works).
hw/ppc/ppc405_boards.c | 14 ++++++++++++++
hw/ppc/ppc440_bamboo.c | 9 +++++++++
hw/ppc/virtex_ml507.c | 8 ++++++++
qemu-doc.texi | 6 ++++++
4 files changed, 37 insertions(+)
diff --git a/hw/ppc/ppc405_boards.c b/hw/ppc/ppc405_boards.c
index e92db2c..6f7f2ee 100644
--- a/hw/ppc/ppc405_boards.c
+++ b/hw/ppc/ppc405_boards.c
@@ -202,6 +202,13 @@ static void ref405ep_init(MachineState *machine)
DriveInfo *dinfo;
MemoryRegion *sysmem = get_system_memory();
+#ifdef TARGET_PPCEMB
+ if (!qtest_enabled()) {
+ warn_report("qemu-system-ppcemb is deprecated, "
+ "please use qemu-system-ppc instead.");
+ }
+#endif
+
/* XXX: fix this */
memory_region_allocate_system_memory(&ram_memories[0], NULL, "ef405ep.ram",
0x08000000);
@@ -497,6 +504,13 @@ static void taihu_405ep_init(MachineState *machine)
int fl_idx, fl_sectors;
DriveInfo *dinfo;
+#ifdef TARGET_PPCEMB
+ if (!qtest_enabled()) {
+ warn_report("qemu-system-ppcemb is deprecated, "
+ "please use qemu-system-ppc instead.");
+ }
+#endif
+
/* RAM is soldered to the board so the size cannot be changed */
ram_size = 0x08000000;
memory_region_allocate_system_memory(ram, NULL, "taihu_405ep.ram",
diff --git a/hw/ppc/ppc440_bamboo.c b/hw/ppc/ppc440_bamboo.c
index 693c215..a299206 100644
--- a/hw/ppc/ppc440_bamboo.c
+++ b/hw/ppc/ppc440_bamboo.c
@@ -13,6 +13,7 @@
#include "qemu/osdep.h"
#include "qemu-common.h"
+#include "qemu/error-report.h"
#include "net/net.h"
#include "hw/hw.h"
#include "hw/pci/pci.h"
@@ -27,6 +28,7 @@
#include "hw/ppc/ppc.h"
#include "ppc405.h"
#include "sysemu/sysemu.h"
+#include "sysemu/qtest.h"
#include "hw/sysbus.h"
#define BINARY_DEVICE_TREE_FILE "bamboo.dtb"
@@ -191,6 +193,13 @@ static void bamboo_init(MachineState *machine)
exit(1);
}
+#ifdef TARGET_PPCEMB
+ if (!qtest_enabled()) {
+ warn_report("qemu-system-ppcemb is deprecated, "
+ "please use qemu-system-ppc instead.");
+ }
+#endif
+
qemu_register_reset(main_cpu_reset, cpu);
ppc_booke_timers_init(cpu, 400000000, 0);
ppc_dcr_init(env, NULL, NULL);
diff --git a/hw/ppc/virtex_ml507.c b/hw/ppc/virtex_ml507.c
index 5ac4f76..9fe7655 100644
--- a/hw/ppc/virtex_ml507.c
+++ b/hw/ppc/virtex_ml507.c
@@ -29,6 +29,7 @@
#include "hw/char/serial.h"
#include "hw/block/flash.h"
#include "sysemu/sysemu.h"
+#include "sysemu/qtest.h"
#include "hw/devices.h"
#include "hw/boards.h"
#include "sysemu/device_tree.h"
@@ -210,6 +211,13 @@ static void virtex_init(MachineState *machine)
int kernel_size;
int i;
+#ifdef TARGET_PPCEMB
+ if (!qtest_enabled()) {
+ warn_report("qemu-system-ppcemb is deprecated, "
+ "please use qemu-system-ppc instead.");
+ }
+#endif
+
/* init CPUs */
cpu = ppc440_init_xilinx(&ram_size, 1, machine->cpu_type, 400000000);
env = &cpu->env;
diff --git a/qemu-doc.texi b/qemu-doc.texi
index 3e9eb81..b13c633 100644
--- a/qemu-doc.texi
+++ b/qemu-doc.texi
@@ -2766,6 +2766,12 @@ The ``host_net_remove'' command is replaced by the ``netdev_del'' command.
The ``ivshmem'' device type is replaced by either the ``ivshmem-plain''
or ``ivshmem-doorbell`` device types.
+@subsection Page size support < 4k for embedded PowerPC CPUs (since 2.12.0)
+
+qemu-system-ppcemb will be removed. qemu-system-ppc (or qemu-system-ppc64)
+should be used instead. That means that embedded 4xx PowerPC CPUs will not
+support page sizes < 4096 any longer.
+
@section System emulator machines
@subsection Xilinx EP108 (since 2.11.0)
--
1.8.3.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [Qemu-ppc] [PATCH v3] ppc: Deprecate qemu-system-ppcemb
2018-01-21 21:57 [Qemu-devel] [PATCH v3] ppc: Deprecate qemu-system-ppcemb Thomas Huth
@ 2018-01-22 8:18 ` Greg Kurz
2018-01-22 13:53 ` [Qemu-devel] " David Gibson
1 sibling, 0 replies; 3+ messages in thread
From: Greg Kurz @ 2018-01-22 8:18 UTC (permalink / raw)
To: Thomas Huth; +Cc: qemu-devel, David Gibson, qemu-ppc
On Sun, 21 Jan 2018 22:57:58 +0100
Thomas Huth <thuth@redhat.com> wrote:
> qemu-system-ppcemb has been once split of qemu-system-ppc to support
> CPU page sizes < 4096 for some of the embedded 4xx PowerPC CPUs.
> However, there was hardly any OS available in the wild that really
> used such small page sizes (Linux uses 4096 on PPC), so there is
> no known recent use case for this separate build anymore. It's
> rather cumbersome to maintain a separate set of config switches for
> this, and it's wasting compile and test time of all the developers
> who have to build all QEMU targets to verify that their changes did
> not break anything.
>
> Except for the small CPU page sizes, qemu-system-ppc can be used as
> a full replacement for qemu-system-ppcemb since it contains all the
> embedded 4xx PPC boards and CPUs, too. Thus let's start the deprecation
> process for qemu-system-ppcemb to see whether somebody still needs
> the small page sizes or whether we could finally remove this unloved
> separate build.
>
> Signed-off-by: Thomas Huth <thuth@redhat.com>
> ---
> v3: Use qtest_enabled() and emit the deprecation message in the
> machine init functions (I unfortunately haven't found a better
> common spot for all 4xx machines where qtest_enabled() works).
>
I guess this is totally acceptable for deprecated code :)
Reviewed-by: Greg Kurz <groug@kaod.org>
> hw/ppc/ppc405_boards.c | 14 ++++++++++++++
> hw/ppc/ppc440_bamboo.c | 9 +++++++++
> hw/ppc/virtex_ml507.c | 8 ++++++++
> qemu-doc.texi | 6 ++++++
> 4 files changed, 37 insertions(+)
>
> diff --git a/hw/ppc/ppc405_boards.c b/hw/ppc/ppc405_boards.c
> index e92db2c..6f7f2ee 100644
> --- a/hw/ppc/ppc405_boards.c
> +++ b/hw/ppc/ppc405_boards.c
> @@ -202,6 +202,13 @@ static void ref405ep_init(MachineState *machine)
> DriveInfo *dinfo;
> MemoryRegion *sysmem = get_system_memory();
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> /* XXX: fix this */
> memory_region_allocate_system_memory(&ram_memories[0], NULL, "ef405ep.ram",
> 0x08000000);
> @@ -497,6 +504,13 @@ static void taihu_405ep_init(MachineState *machine)
> int fl_idx, fl_sectors;
> DriveInfo *dinfo;
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> /* RAM is soldered to the board so the size cannot be changed */
> ram_size = 0x08000000;
> memory_region_allocate_system_memory(ram, NULL, "taihu_405ep.ram",
> diff --git a/hw/ppc/ppc440_bamboo.c b/hw/ppc/ppc440_bamboo.c
> index 693c215..a299206 100644
> --- a/hw/ppc/ppc440_bamboo.c
> +++ b/hw/ppc/ppc440_bamboo.c
> @@ -13,6 +13,7 @@
>
> #include "qemu/osdep.h"
> #include "qemu-common.h"
> +#include "qemu/error-report.h"
> #include "net/net.h"
> #include "hw/hw.h"
> #include "hw/pci/pci.h"
> @@ -27,6 +28,7 @@
> #include "hw/ppc/ppc.h"
> #include "ppc405.h"
> #include "sysemu/sysemu.h"
> +#include "sysemu/qtest.h"
> #include "hw/sysbus.h"
>
> #define BINARY_DEVICE_TREE_FILE "bamboo.dtb"
> @@ -191,6 +193,13 @@ static void bamboo_init(MachineState *machine)
> exit(1);
> }
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> qemu_register_reset(main_cpu_reset, cpu);
> ppc_booke_timers_init(cpu, 400000000, 0);
> ppc_dcr_init(env, NULL, NULL);
> diff --git a/hw/ppc/virtex_ml507.c b/hw/ppc/virtex_ml507.c
> index 5ac4f76..9fe7655 100644
> --- a/hw/ppc/virtex_ml507.c
> +++ b/hw/ppc/virtex_ml507.c
> @@ -29,6 +29,7 @@
> #include "hw/char/serial.h"
> #include "hw/block/flash.h"
> #include "sysemu/sysemu.h"
> +#include "sysemu/qtest.h"
> #include "hw/devices.h"
> #include "hw/boards.h"
> #include "sysemu/device_tree.h"
> @@ -210,6 +211,13 @@ static void virtex_init(MachineState *machine)
> int kernel_size;
> int i;
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> /* init CPUs */
> cpu = ppc440_init_xilinx(&ram_size, 1, machine->cpu_type, 400000000);
> env = &cpu->env;
> diff --git a/qemu-doc.texi b/qemu-doc.texi
> index 3e9eb81..b13c633 100644
> --- a/qemu-doc.texi
> +++ b/qemu-doc.texi
> @@ -2766,6 +2766,12 @@ The ``host_net_remove'' command is replaced by the ``netdev_del'' command.
> The ``ivshmem'' device type is replaced by either the ``ivshmem-plain''
> or ``ivshmem-doorbell`` device types.
>
> +@subsection Page size support < 4k for embedded PowerPC CPUs (since 2.12.0)
> +
> +qemu-system-ppcemb will be removed. qemu-system-ppc (or qemu-system-ppc64)
> +should be used instead. That means that embedded 4xx PowerPC CPUs will not
> +support page sizes < 4096 any longer.
> +
> @section System emulator machines
>
> @subsection Xilinx EP108 (since 2.11.0)
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH v3] ppc: Deprecate qemu-system-ppcemb
2018-01-21 21:57 [Qemu-devel] [PATCH v3] ppc: Deprecate qemu-system-ppcemb Thomas Huth
2018-01-22 8:18 ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
@ 2018-01-22 13:53 ` David Gibson
1 sibling, 0 replies; 3+ messages in thread
From: David Gibson @ 2018-01-22 13:53 UTC (permalink / raw)
To: Thomas Huth; +Cc: qemu-devel, David Gibson, qemu-ppc
[-- Attachment #1: Type: text/plain, Size: 5542 bytes --]
On Sun, Jan 21, 2018 at 10:57:58PM +0100, Thomas Huth wrote:
> qemu-system-ppcemb has been once split of qemu-system-ppc to support
> CPU page sizes < 4096 for some of the embedded 4xx PowerPC CPUs.
> However, there was hardly any OS available in the wild that really
> used such small page sizes (Linux uses 4096 on PPC), so there is
> no known recent use case for this separate build anymore. It's
> rather cumbersome to maintain a separate set of config switches for
> this, and it's wasting compile and test time of all the developers
> who have to build all QEMU targets to verify that their changes did
> not break anything.
>
> Except for the small CPU page sizes, qemu-system-ppc can be used as
> a full replacement for qemu-system-ppcemb since it contains all the
> embedded 4xx PPC boards and CPUs, too. Thus let's start the deprecation
> process for qemu-system-ppcemb to see whether somebody still needs
> the small page sizes or whether we could finally remove this unloved
> separate build.
>
> Signed-off-by: Thomas Huth <thuth@redhat.com>
Applied, thanks.
> ---
> v3: Use qtest_enabled() and emit the deprecation message in the
> machine init functions (I unfortunately haven't found a better
> common spot for all 4xx machines where qtest_enabled() works).
>
> hw/ppc/ppc405_boards.c | 14 ++++++++++++++
> hw/ppc/ppc440_bamboo.c | 9 +++++++++
> hw/ppc/virtex_ml507.c | 8 ++++++++
> qemu-doc.texi | 6 ++++++
> 4 files changed, 37 insertions(+)
>
> diff --git a/hw/ppc/ppc405_boards.c b/hw/ppc/ppc405_boards.c
> index e92db2c..6f7f2ee 100644
> --- a/hw/ppc/ppc405_boards.c
> +++ b/hw/ppc/ppc405_boards.c
> @@ -202,6 +202,13 @@ static void ref405ep_init(MachineState *machine)
> DriveInfo *dinfo;
> MemoryRegion *sysmem = get_system_memory();
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> /* XXX: fix this */
> memory_region_allocate_system_memory(&ram_memories[0], NULL, "ef405ep.ram",
> 0x08000000);
> @@ -497,6 +504,13 @@ static void taihu_405ep_init(MachineState *machine)
> int fl_idx, fl_sectors;
> DriveInfo *dinfo;
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> /* RAM is soldered to the board so the size cannot be changed */
> ram_size = 0x08000000;
> memory_region_allocate_system_memory(ram, NULL, "taihu_405ep.ram",
> diff --git a/hw/ppc/ppc440_bamboo.c b/hw/ppc/ppc440_bamboo.c
> index 693c215..a299206 100644
> --- a/hw/ppc/ppc440_bamboo.c
> +++ b/hw/ppc/ppc440_bamboo.c
> @@ -13,6 +13,7 @@
>
> #include "qemu/osdep.h"
> #include "qemu-common.h"
> +#include "qemu/error-report.h"
> #include "net/net.h"
> #include "hw/hw.h"
> #include "hw/pci/pci.h"
> @@ -27,6 +28,7 @@
> #include "hw/ppc/ppc.h"
> #include "ppc405.h"
> #include "sysemu/sysemu.h"
> +#include "sysemu/qtest.h"
> #include "hw/sysbus.h"
>
> #define BINARY_DEVICE_TREE_FILE "bamboo.dtb"
> @@ -191,6 +193,13 @@ static void bamboo_init(MachineState *machine)
> exit(1);
> }
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> qemu_register_reset(main_cpu_reset, cpu);
> ppc_booke_timers_init(cpu, 400000000, 0);
> ppc_dcr_init(env, NULL, NULL);
> diff --git a/hw/ppc/virtex_ml507.c b/hw/ppc/virtex_ml507.c
> index 5ac4f76..9fe7655 100644
> --- a/hw/ppc/virtex_ml507.c
> +++ b/hw/ppc/virtex_ml507.c
> @@ -29,6 +29,7 @@
> #include "hw/char/serial.h"
> #include "hw/block/flash.h"
> #include "sysemu/sysemu.h"
> +#include "sysemu/qtest.h"
> #include "hw/devices.h"
> #include "hw/boards.h"
> #include "sysemu/device_tree.h"
> @@ -210,6 +211,13 @@ static void virtex_init(MachineState *machine)
> int kernel_size;
> int i;
>
> +#ifdef TARGET_PPCEMB
> + if (!qtest_enabled()) {
> + warn_report("qemu-system-ppcemb is deprecated, "
> + "please use qemu-system-ppc instead.");
> + }
> +#endif
> +
> /* init CPUs */
> cpu = ppc440_init_xilinx(&ram_size, 1, machine->cpu_type, 400000000);
> env = &cpu->env;
> diff --git a/qemu-doc.texi b/qemu-doc.texi
> index 3e9eb81..b13c633 100644
> --- a/qemu-doc.texi
> +++ b/qemu-doc.texi
> @@ -2766,6 +2766,12 @@ The ``host_net_remove'' command is replaced by the ``netdev_del'' command.
> The ``ivshmem'' device type is replaced by either the ``ivshmem-plain''
> or ``ivshmem-doorbell`` device types.
>
> +@subsection Page size support < 4k for embedded PowerPC CPUs (since 2.12.0)
> +
> +qemu-system-ppcemb will be removed. qemu-system-ppc (or qemu-system-ppc64)
> +should be used instead. That means that embedded 4xx PowerPC CPUs will not
> +support page sizes < 4096 any longer.
> +
> @section System emulator machines
>
> @subsection Xilinx EP108 (since 2.11.0)
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-01-22 23:45 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-21 21:57 [Qemu-devel] [PATCH v3] ppc: Deprecate qemu-system-ppcemb Thomas Huth
2018-01-22 8:18 ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2018-01-22 13:53 ` [Qemu-devel] " David Gibson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).