* [PATCH v1 0/2] Parse and handle command line from dtb @ 2024-09-30 15:13 Oleksii Kurochko 2024-09-30 15:13 ` [PATCH v1 1/2] xen/riscv: initialize bootinfo " Oleksii Kurochko 2024-09-30 15:13 ` [PATCH v1 2/2] xen/riscv: parse and handle fdt command line Oleksii Kurochko 0 siblings, 2 replies; 6+ messages in thread From: Oleksii Kurochko @ 2024-09-30 15:13 UTC (permalink / raw) To: xen-devel Cc: Oleksii Kurochko, Alistair Francis, Bob Eshleman, Connor Davis, Andrew Cooper, Jan Beulich, Julien Grall, Stefano Stabellini This patch series initializes bootinfo from dtb and then parse and handle command line from dtb. This patch series is based on the patch series: "Register Xen's load address as a boot module" [1] [1] https://lore.kernel.org/xen-devel/cover.1727708665.git.oleksii.kurochko@gmail.com/T/#t Oleksii Kurochko (2): xen/riscv: initialize bootinfo from dtb xen/riscv: parse and handle fdt command line xen/arch/riscv/setup.c | 9 +++++++++ 1 file changed, 9 insertions(+) -- 2.46.1 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v1 1/2] xen/riscv: initialize bootinfo from dtb 2024-09-30 15:13 [PATCH v1 0/2] Parse and handle command line from dtb Oleksii Kurochko @ 2024-09-30 15:13 ` Oleksii Kurochko 2024-10-01 15:54 ` Jan Beulich 2024-09-30 15:13 ` [PATCH v1 2/2] xen/riscv: parse and handle fdt command line Oleksii Kurochko 1 sibling, 1 reply; 6+ messages in thread From: Oleksii Kurochko @ 2024-09-30 15:13 UTC (permalink / raw) To: xen-devel Cc: Oleksii Kurochko, Alistair Francis, Bob Eshleman, Connor Davis, Andrew Cooper, Jan Beulich, Julien Grall, Stefano Stabellini Parse DTB during startup, allowing memory banks and reserved memory regions to be set up, along with early device tree node ( chosen, "xen,domain", "reserved-memory", etc ) handling. Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com> --- xen/arch/riscv/setup.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xen/arch/riscv/setup.c b/xen/arch/riscv/setup.c index 39375b3366..a8d8ef793d 100644 --- a/xen/arch/riscv/setup.c +++ b/xen/arch/riscv/setup.c @@ -28,6 +28,7 @@ void __init noreturn start_xen(unsigned long bootcpu_id, paddr_t dtb_addr) { struct bootmodule *xen_bootmodule; + size_t fdt_size; remove_identity_mapping(); @@ -54,6 +55,9 @@ void __init noreturn start_xen(unsigned long bootcpu_id, BUG_ON(!xen_bootmodule); + fdt_size = boot_fdt_info(device_tree_flattened, dtb_addr); + BUG_ON(!fdt_size); + printk("All set up\n"); machine_halt(); -- 2.46.1 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH v1 1/2] xen/riscv: initialize bootinfo from dtb 2024-09-30 15:13 ` [PATCH v1 1/2] xen/riscv: initialize bootinfo " Oleksii Kurochko @ 2024-10-01 15:54 ` Jan Beulich 2024-10-02 8:26 ` oleksii.kurochko 0 siblings, 1 reply; 6+ messages in thread From: Jan Beulich @ 2024-10-01 15:54 UTC (permalink / raw) To: Oleksii Kurochko Cc: Alistair Francis, Bob Eshleman, Connor Davis, Andrew Cooper, Julien Grall, Stefano Stabellini, xen-devel On 30.09.2024 17:13, Oleksii Kurochko wrote: > --- a/xen/arch/riscv/setup.c > +++ b/xen/arch/riscv/setup.c > @@ -28,6 +28,7 @@ void __init noreturn start_xen(unsigned long bootcpu_id, > paddr_t dtb_addr) > { > struct bootmodule *xen_bootmodule; > + size_t fdt_size; > > remove_identity_mapping(); > > @@ -54,6 +55,9 @@ void __init noreturn start_xen(unsigned long bootcpu_id, > > BUG_ON(!xen_bootmodule); > > + fdt_size = boot_fdt_info(device_tree_flattened, dtb_addr); > + BUG_ON(!fdt_size); > + > printk("All set up\n"); > > machine_halt(); Looks plausible, and judging from Arm code there'll be an actual use of fdt_size down the road. Or else I would have asked what use the local variable is. In fact, again from looking at Arm code, I now question the need for the xen_bootmodule local var - that has no further use in Arm, and hence that's likely going to be the case for RISC-V, too. However, may I ask that you limit the dependency trees in what you submit? This series depends on another series, which in turn depends on yet something else, all not yet committed. That's getting unwieldy, I'm afraid. Jan ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH v1 1/2] xen/riscv: initialize bootinfo from dtb 2024-10-01 15:54 ` Jan Beulich @ 2024-10-02 8:26 ` oleksii.kurochko 0 siblings, 0 replies; 6+ messages in thread From: oleksii.kurochko @ 2024-10-02 8:26 UTC (permalink / raw) To: Jan Beulich Cc: Alistair Francis, Bob Eshleman, Connor Davis, Andrew Cooper, Julien Grall, Stefano Stabellini, xen-devel On Tue, 2024-10-01 at 17:54 +0200, Jan Beulich wrote: > On 30.09.2024 17:13, Oleksii Kurochko wrote: > > --- a/xen/arch/riscv/setup.c > > +++ b/xen/arch/riscv/setup.c > > @@ -28,6 +28,7 @@ void __init noreturn start_xen(unsigned long > > bootcpu_id, > > paddr_t dtb_addr) > > { > > struct bootmodule *xen_bootmodule; > > + size_t fdt_size; > > > > remove_identity_mapping(); > > > > @@ -54,6 +55,9 @@ void __init noreturn start_xen(unsigned long > > bootcpu_id, > > > > BUG_ON(!xen_bootmodule); > > > > + fdt_size = boot_fdt_info(device_tree_flattened, dtb_addr); > > + BUG_ON(!fdt_size); > > + > > printk("All set up\n"); > > > > machine_halt(); > > Looks plausible, and judging from Arm code there'll be an actual use > of fdt_size > down the road. Or else I would have asked what use the local variable > is. In > fact, again from looking at Arm code, I now question the need for the > xen_bootmodule local var - that has no further use in Arm, and hence > that's > likely going to be the case for RISC-V, too. fdt_size and xen_bootmodule are used only for BUG_ON() now and in future ( the same as you mentioned as in Arm ). They could be dropped. I'll do that in the next patch version. > > However, may I ask that you limit the dependency trees in what you > submit? This > series depends on another series, which in turn depends on yet > something else, > all not yet committed. That's getting unwieldy, I'm afraid. Sure, sorry for that. I will limit the depedency trees in future. ~ Oleksii ^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v1 2/2] xen/riscv: parse and handle fdt command line 2024-09-30 15:13 [PATCH v1 0/2] Parse and handle command line from dtb Oleksii Kurochko 2024-09-30 15:13 ` [PATCH v1 1/2] xen/riscv: initialize bootinfo " Oleksii Kurochko @ 2024-09-30 15:13 ` Oleksii Kurochko 2024-10-01 15:55 ` Jan Beulich 1 sibling, 1 reply; 6+ messages in thread From: Oleksii Kurochko @ 2024-09-30 15:13 UTC (permalink / raw) To: xen-devel Cc: Oleksii Kurochko, Alistair Francis, Bob Eshleman, Connor Davis, Andrew Cooper, Jan Beulich, Julien Grall, Stefano Stabellini 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 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH v1 2/2] xen/riscv: parse and handle fdt command line 2024-09-30 15:13 ` [PATCH v1 2/2] xen/riscv: parse and handle fdt command line Oleksii Kurochko @ 2024-10-01 15:55 ` Jan Beulich 0 siblings, 0 replies; 6+ messages in thread From: Jan Beulich @ 2024-10-01 15:55 UTC (permalink / raw) To: Oleksii Kurochko Cc: Alistair Francis, Bob Eshleman, Connor Davis, Andrew Cooper, Julien Grall, Stefano Stabellini, xen-devel 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> ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2024-10-02 8:27 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2024-09-30 15:13 [PATCH v1 0/2] Parse and handle command line from dtb Oleksii Kurochko 2024-09-30 15:13 ` [PATCH v1 1/2] xen/riscv: initialize bootinfo " Oleksii Kurochko 2024-10-01 15:54 ` Jan Beulich 2024-10-02 8:26 ` oleksii.kurochko 2024-09-30 15:13 ` [PATCH v1 2/2] xen/riscv: parse and handle fdt command line Oleksii Kurochko 2024-10-01 15:55 ` Jan Beulich
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.