[PATCH v1 2/2] xen/riscv: parse and handle fdt command line

Oleksii Kurochko posted 2 patches 1 month, 3 weeks ago
There is a newer version of this series
[PATCH v1 2/2] xen/riscv: parse and handle fdt command line
Posted by Oleksii Kurochko 1 month, 3 weeks ago
Receive Xen's command line passed by DTB using boot_fdt_cmdline()
and passed it to cmdline_parse() for further procesinng and setup
of Xen-specific parameters.

Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
---
 xen/arch/riscv/setup.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/xen/arch/riscv/setup.c b/xen/arch/riscv/setup.c
index a8d8ef793d..0d1b52f8d0 100644
--- a/xen/arch/riscv/setup.c
+++ b/xen/arch/riscv/setup.c
@@ -29,6 +29,7 @@ void __init noreturn start_xen(unsigned long bootcpu_id,
 {
     struct bootmodule *xen_bootmodule;
     size_t fdt_size;
+    const char *cmdline;
 
     remove_identity_mapping();
 
@@ -58,6 +59,10 @@ void __init noreturn start_xen(unsigned long bootcpu_id,
     fdt_size = boot_fdt_info(device_tree_flattened, dtb_addr);
     BUG_ON(!fdt_size);
 
+    cmdline = boot_fdt_cmdline(device_tree_flattened);
+    printk("Command line: %s\n", cmdline);
+    cmdline_parse(cmdline);
+
     printk("All set up\n");
 
     machine_halt();
-- 
2.46.1
Re: [PATCH v1 2/2] xen/riscv: parse and handle fdt command line
Posted by Jan Beulich 1 month, 3 weeks ago
On 30.09.2024 17:13, Oleksii Kurochko wrote:
> Receive Xen's command line passed by DTB using boot_fdt_cmdline()
> and passed it to cmdline_parse() for further procesinng and setup
> of Xen-specific parameters.
> 
> Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>

Acked-by: Jan Beulich <jbeulich@suse.com>