* [Qemu-devel] [PATCH] hw/ppc/spapr, e500: Use new property "stdout-path" for boot console
@ 2018-03-01 6:05 Nikunj A Dadhania
2018-03-02 1:01 ` David Gibson
0 siblings, 1 reply; 2+ messages in thread
From: Nikunj A Dadhania @ 2018-03-01 6:05 UTC (permalink / raw)
To: qemu-ppc, david; +Cc: qemu-devel, agraf, benh, Nikunj A Dadhania
Linux kernel commit 2a9d832cc9aae21ea827520fef635b6c49a06c6d
(of: Add bindings for chosen node, stdout-path) deprecated chosen property
"linux,stdout-path" and "stdout".
Introduce the new property "stdout-path" and continue supporting the older
property to remain compatible with existing/older firmware. This older property
can be deprecated after 5 years.
Signed-off-by: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>
---
hw/ppc/e500.c | 7 +++++++
hw/ppc/spapr.c | 7 +++++++
2 files changed, 14 insertions(+)
diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c
index a40d3ec3e3..a325a95015 100644
--- a/hw/ppc/e500.c
+++ b/hw/ppc/e500.c
@@ -119,7 +119,14 @@ static void dt_serial_create(void *fdt, unsigned long long offset,
qemu_fdt_setprop_string(fdt, "/aliases", alias, ser);
if (defcon) {
+ /*
+ * "linux,stdout-path" and "stdout" properties are deprecated by linux
+ * kernel. New platforms should only use the "stdout-path" property. Set
+ * the new property and continue using older property to remain
+ * compatible with the existing firmware.
+ */
qemu_fdt_setprop_string(fdt, "/chosen", "linux,stdout-path", ser);
+ qemu_fdt_setprop_string(fdt, "/chosen", "stdout-path", ser);
}
}
diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
index 83c9d66dd5..58a44edc4a 100644
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -1062,7 +1062,14 @@ static void spapr_dt_chosen(sPAPRMachineState *spapr, void *fdt)
}
if (!spapr->has_graphics && stdout_path) {
+ /*
+ * "linux,stdout-path" and "stdout" properties are deprecated by linux
+ * kernel. New platforms should only use the "stdout-path" property. Set
+ * the new property and continue using older property to remain
+ * compatible with the existing firmware.
+ */
_FDT(fdt_setprop_string(fdt, chosen, "linux,stdout-path", stdout_path));
+ _FDT(fdt_setprop_string(fdt, chosen, "stdout-path", stdout_path));
}
spapr_dt_ov5_platform_support(fdt, chosen);
--
2.14.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH] hw/ppc/spapr, e500: Use new property "stdout-path" for boot console
2018-03-01 6:05 [Qemu-devel] [PATCH] hw/ppc/spapr, e500: Use new property "stdout-path" for boot console Nikunj A Dadhania
@ 2018-03-02 1:01 ` David Gibson
0 siblings, 0 replies; 2+ messages in thread
From: David Gibson @ 2018-03-02 1:01 UTC (permalink / raw)
To: Nikunj A Dadhania; +Cc: qemu-ppc, qemu-devel, agraf, benh
[-- Attachment #1: Type: text/plain, Size: 2526 bytes --]
On Thu, Mar 01, 2018 at 11:35:50AM +0530, Nikunj A Dadhania wrote:
> Linux kernel commit 2a9d832cc9aae21ea827520fef635b6c49a06c6d
> (of: Add bindings for chosen node, stdout-path) deprecated chosen property
> "linux,stdout-path" and "stdout".
>
> Introduce the new property "stdout-path" and continue supporting the older
> property to remain compatible with existing/older firmware. This older property
> can be deprecated after 5 years.
>
> Signed-off-by: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>
Applied to ppc-for-2.12, thanks.
> ---
> hw/ppc/e500.c | 7 +++++++
> hw/ppc/spapr.c | 7 +++++++
> 2 files changed, 14 insertions(+)
>
> diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c
> index a40d3ec3e3..a325a95015 100644
> --- a/hw/ppc/e500.c
> +++ b/hw/ppc/e500.c
> @@ -119,7 +119,14 @@ static void dt_serial_create(void *fdt, unsigned long long offset,
> qemu_fdt_setprop_string(fdt, "/aliases", alias, ser);
>
> if (defcon) {
> + /*
> + * "linux,stdout-path" and "stdout" properties are deprecated by linux
> + * kernel. New platforms should only use the "stdout-path" property. Set
> + * the new property and continue using older property to remain
> + * compatible with the existing firmware.
> + */
> qemu_fdt_setprop_string(fdt, "/chosen", "linux,stdout-path", ser);
> + qemu_fdt_setprop_string(fdt, "/chosen", "stdout-path", ser);
> }
> }
>
> diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> index 83c9d66dd5..58a44edc4a 100644
> --- a/hw/ppc/spapr.c
> +++ b/hw/ppc/spapr.c
> @@ -1062,7 +1062,14 @@ static void spapr_dt_chosen(sPAPRMachineState *spapr, void *fdt)
> }
>
> if (!spapr->has_graphics && stdout_path) {
> + /*
> + * "linux,stdout-path" and "stdout" properties are deprecated by linux
> + * kernel. New platforms should only use the "stdout-path" property. Set
> + * the new property and continue using older property to remain
> + * compatible with the existing firmware.
> + */
> _FDT(fdt_setprop_string(fdt, chosen, "linux,stdout-path", stdout_path));
> + _FDT(fdt_setprop_string(fdt, chosen, "stdout-path", stdout_path));
> }
>
> spapr_dt_ov5_platform_support(fdt, chosen);
--
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] 2+ messages in thread
end of thread, other threads:[~2018-03-02 1:36 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-01 6:05 [Qemu-devel] [PATCH] hw/ppc/spapr, e500: Use new property "stdout-path" for boot console Nikunj A Dadhania
2018-03-02 1:01 ` 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).