On 11/7/24 15:58, Jason Andryuk wrote:
On 2024-11-02 13:25, Daniel P. Smith wrote:
To begin moving toward allowing the hypervisor to construct more than one
domain at boot, a container is needed for a domain's build information.
Introduce a new header, <xen/asm/bootdomain.h>, that contains the initial
struct boot_domain that encapsulate the build information for a domain.
Add a kernel and ramdisk boot module reference along with a struct domain
reference to the new struct boot_domain. This allows a struct boot_domain
reference to be the only parameter necessary to pass down through the
domain
construction call chain.
Signed-off-by: Daniel P. Smith <[email protected]>
---
Changes since v7
- collapsed the incremental changes to the call chain into this commit
---
diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c
index 18b93d6a272a..6e25a9f726c7 100644
--- a/xen/arch/x86/setup.c
+++ b/xen/arch/x86/setup.c
@@ -1026,11 +1019,11 @@ static struct domain *__init
create_dom0(struct boot_info *bi)
panic("Error creating d%uv0\n", domid);
/* Grab the DOM0 command line. */
- if ( image->cmdline_pa || bi->kextra )
+ if ( bd->kernel->cmdline_pa || bi->kextra )
{
- if ( image->cmdline_pa )
- safe_strcpy(
- cmdline, cmdline_cook(__va(image->cmdline_pa), bi-
>loader));
+ if ( bd->kernel->cmdline_pa )
+ safe_strcpy(cmdline, cmdline_cook(__va(bd->kernel-
>cmdline_pa),
+ bi->loader));
I'd indent bi->loader so it lines up with __va, since bi->loader is the
second argument to cmdline_cook().
Ack.
With that:
Reviewed-by: Jason Andryuk <[email protected]>
Thanks,
v/r,
dps