[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v5 43/44] x86/boot: convert dom0_construct_pv to struct boot_domain


  • To: "Daniel P. Smith" <dpsmith@xxxxxxxxxxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Jason Andryuk <jason.andryuk@xxxxxxx>
  • Date: Tue, 8 Oct 2024 15:54:34 -0400
  • 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=38kzgQZuvtjPTcjHsGMRDZRICHRETo1px+QNNAvmIYs=; b=XMSHTYiddQ9tWBNkLmbHae1l7I/xXwqAh8vSEwg6uiZqLzNpfOmoyGbth7Xt/HLN1BNwI6QPuiZDN1OhFD2IWRG0KcG3QfhnKa2wkRUJu1S3kJe0lcZzC2Tyn4PbaDo7Ws+JitUv4/CMqmFnW94OWri9kGX0RXaCh6vhYWiOZJmeLGgW57mtUtHv55hw1HFVS9rAOiver8ZEPpoFqdDfEr3rOacza0Dte1g1SFZ1BzYp4fYVlmM+DrAE7pN8O0hq0GZs/emRLKotN8pn0pYCXv0tLJVEDAtkj8+gKSOFOC7+CmVxwDZ71oNYz2umRHPXY2QDxo8kK53DXIR1BYogLA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=pnU+kGaqtn/Hm5+7ybnqrtsArC1/z1ANmFT35ZKdI1Iawg77QdxABOb+wm5P3aZ6G7wwpUIe8P8Ku7rjkBXEnRHFTpqJ/UoDNeK+XNYWsfIASA9APSXpJmig71kRoU50cNzM3RtTDRGlS8fn1SNYDwiJlWnWAJHjaMmImM7n9z848yj21+0T/KRB8I1aVyusniaspefMRVL81hRsH8bwbss8QOP6ii6DxF/vMUGQiuZzJE4UMKz9b2c4cTUMzHEtSKOO/kvmLnL06f+HRMJf84SUZBt+KOCcyrt2ykiz5PtqXLLvCdk4laI470EihEC/nATFvsJgBDkKl9EEVW24aA==
  • 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: Tue, 08 Oct 2024 20:55:29 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 2024-10-06 17:49, Daniel P. Smith wrote:
With construct_dom0 consuming struct boot_domain, continue passing the
structure down to dom0_construct_pv.

Signed-off-by: Daniel P. Smith <dpsmith@xxxxxxxxxxxxxxxxxxxx>

diff --git a/xen/arch/x86/pv/dom0_build.c b/xen/arch/x86/pv/dom0_build.c
index 16b8c1e40998..34974aa7cd56 100644
--- a/xen/arch/x86/pv/dom0_build.c
+++ b/xen/arch/x86/pv/dom0_build.c
@@ -354,10 +354,7 @@ static struct page_info * __init alloc_chunk(struct domain 
*d,
      return page;
  }
-static int __init dom0_construct(struct domain *d,
-                                 const struct boot_module *image,
-                                 struct boot_module *initrd,
-                                 const char *cmdline)
+static int __init dom0_construct(struct boot_domain *bd)
  {
      int i, rc, order, machine;
      bool compatible, compat;
@@ -373,11 +370,12 @@ static int __init dom0_construct(struct domain *d,
      struct page_info *page = NULL;
      unsigned int flush_flags = 0;
      start_info_t *si;
-    struct vcpu *v = d->vcpu[0];
-    void *image_base = bootstrap_map_bm(image);
-    unsigned long image_len = image->size;
-    void *image_start = image_base + image->headroom;
-    unsigned long initrd_len = initrd ? initrd->size : 0;
+    struct domain *d = bd->d;
+    struct vcpu *v = bd->d->vcpu[0];

This can stay:
    struct vcpu *v = d->vcpu[0];

With that:

Reviewed-by: Jason Andryuk <jason.andryuk@xxxxxxx>



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.