[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 10/12] x86/boot: introduce boot domain
- To: "Daniel P. Smith" <dpsmith@xxxxxxxxxxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Jason Andryuk <jason.andryuk@xxxxxxx>
- Date: Thu, 7 Nov 2024 15:58:35 -0500
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=apertussolutions.com smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0)
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Qx0dw3guOB3XMuPqs5dm8Tr2WH50uT+xQ2WTwDKtohI=; b=HR202OX+zTioKlbfLxbyztQ2T0KZPsBxB5e5SZzGom+8TuIqDAwinRln3IQerTM1DEFI62+Zp7Lj2Rw9Mm1oJTukFnifuctZb3ps2MwUkTq6gkMjwxA2MJ7cNqVNgpNfjztW4381t1IpN/brrurWiw+Jbs3O9qhGPMoteevEtY6087JrXT+S7uZHYtKzo1ISGSwSubT2hfGeLnAwljwx+2qnBMmy+SSamFZvE9wko0GK86uLKU7qxfcS4MB2XcJAb1iEx5/DSIswUqR0O2f5Y0YRcl9OAJbMtzOx9Zt2vawUNQhcnCFEV7+FGkMlclQCUgfEno2sTVG/epWc59DpGw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ScUzk6qu1RnjWQldmFeBiApbj9E9WGtJbWGlTF1Zun5MzxEAXX/HOnsklxKLsn9Awdjd5TGLjsWjBMwycYh2Fj2SiUlTbRh6d1Wv3G6UzOwH2adMpEE/mKGu++YjdazicIMdxKMD30Mx8PWd/fW94hku/kZD2PCsExEskr3ssEm2FKv7aqNk4uHZxfvlMTkYRKvAcu+m9HyyUyiu0TDcvvaS+5ew7SXNlSNlv9tSLevaTCggTIvUXvUaW+AijE7zZ0+jCiFSYJu6IHRLMaDGrZGLy/9oQkgpMczjkmKO+brhmcVz/VXiKvyzNEs7CpW7DYZqxqAeBLDtiGS9ypCN6Q==
- Cc: <christopher.w.clark@xxxxxxxxx>, <stefano.stabellini@xxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>
- Delivery-date: Thu, 07 Nov 2024 20:58:53 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
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 <dpsmith@xxxxxxxxxxxxxxxxxxxx>
---
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().
With that:
Reviewed-by: Jason Andryuk <jason.andryuk@xxxxxxx>
if ( bi->kextra )
/* kextra always includes exactly one leading space. */
|