From nobody Wed Dec 4 19:48:06 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass header.i=dpsmith@apertussolutions.com; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1 dmarc=pass fromdomain=apertussolutions.com) ARC-Seal: i=2; a=rsa-sha256; t=1729472215; cv=pass; d=zohomail.com; s=zohoarc; b=Jk5yyqh8QsXmmsd76HN9teBwTGnDqSC0PUlQAdTrR3dtWvBpplw2sBAQl5c+9OHq/ugrsAKGobmCrrb2VrRnntwQ+YJo3yWtTSkc6GDwK5E9BpFHG1AqfAL8HfXxHS+GaP6GPZyt73FxWWhc0cw1jxIvIXnidOvdWb/kXNhXSgc= ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1729472215; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=aNiN7YZD1SazmqTlmBUizZzq3LQ/OZULOiAYxfKrfPs=; b=VRPvPNpYLqfb/GPuxIL1zC76bxsv07W0hO+V/OxuwLdw+E+6oElm7qbEhqWRT16Tb5QCApkSXH6VtAOMZfAxrRk/fllXc+YoMXXSjIfU8sRyB3DKqVh3J4EKehsCHtU+Zb/9lOQ+PnkU5gPBfoEEJ2KJYLUZWvIFANxGsJL6d9I= ARC-Authentication-Results: i=2; mx.zohomail.com; dkim=pass header.i=dpsmith@apertussolutions.com; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1 dmarc=pass fromdomain=apertussolutions.com) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1729472215019438.8001736904506; Sun, 20 Oct 2024 17:56:55 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.822968.1236948 (Exim 4.92) (envelope-from ) id 1t2giq-0000ts-6Q; Mon, 21 Oct 2024 00:56:36 +0000 Received: by outflank-mailman (output) from mailman id 822968.1236948; Mon, 21 Oct 2024 00:56:36 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1t2giq-0000rm-1H; Mon, 21 Oct 2024 00:56:36 +0000 Received: by outflank-mailman (input) for mailman id 822968; Mon, 21 Oct 2024 00:56:34 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1t2gdg-0001i1-E6 for xen-devel@lists.xenproject.org; Mon, 21 Oct 2024 00:51:16 +0000 Received: from sender3-of-o57.zoho.com (sender3-of-o57.zoho.com [136.143.184.57]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 92784cff-8f46-11ef-a0be-8be0dac302b0; Mon, 21 Oct 2024 02:51:15 +0200 (CEST) Received: by mx.zohomail.com with SMTPS id 1729471627762341.13633961756796; Sun, 20 Oct 2024 17:47:07 -0700 (PDT) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 92784cff-8f46-11ef-a0be-8be0dac302b0 ARC-Seal: i=1; a=rsa-sha256; t=1729471630; cv=none; d=zohomail.com; s=zohoarc; b=DBpP/etX40b9X02XsY3EwrRHnOnn1TQzVdf233CEGfo6hf/HkjM+08haoVCXvTxSkuVdjQMRUZhChx3xDGieYgOFJv3ue5fD4iDRIda1e31w9597CFrmqsUGvxOtI1+1/YQ6p/zKf1Fg4tXEj6k2wRzVGVhGbPp4qorLmAEUlY4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1729471630; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=aNiN7YZD1SazmqTlmBUizZzq3LQ/OZULOiAYxfKrfPs=; b=cClLXdwR2izAtMgWydaL8WXbRd943bZGgq1Jubtuoog+ln9tjiBEltcE6tDNXiHTgJpNlr0OJwog8b/N8qOHYGB3I15wAr+O+xl7Wr2cC1LseSyTzruRKdMxP+a0/N1SXVANs8YwlinIgAUEn2WWohdwChRo0RAMtqcJ+Za7dyU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=apertussolutions.com; spf=pass smtp.mailfrom=dpsmith@apertussolutions.com; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1729471630; s=zoho; d=apertussolutions.com; i=dpsmith@apertussolutions.com; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-Id:Message-Id:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding:Reply-To; bh=aNiN7YZD1SazmqTlmBUizZzq3LQ/OZULOiAYxfKrfPs=; b=BtM3NsMWsvvFPWD62qTZVIfeXRwvA6uhNs8WbuskbHBWsdvBGGzG1JoNAtIVYCEW ZeyeCK1tD24lOc8v//7bNaoXHA7HH7jfZgnnII7AYU30YR+4srXjq4nCOlRulIUOSSP BOX9qzU2r+YyoVGGOJ72ZlpriyVa/5CtdRtsu75s= From: "Daniel P. Smith" To: xen-devel@lists.xenproject.org Cc: "Daniel P. Smith" , jason.andryuk@amd.com, christopher.w.clark@gmail.com, stefano.stabellini@amd.com, Jan Beulich , Andrew Cooper , =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= Subject: [PATCH v7 38/38] x86/boot: convert dom0_construct_pvh to struct boot_domain Date: Sun, 20 Oct 2024 20:46:13 -0400 Message-Id: <20241021004613.18793-39-dpsmith@apertussolutions.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20241021004613.18793-1-dpsmith@apertussolutions.com> References: <20241021004613.18793-1-dpsmith@apertussolutions.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMailClient: External X-ZohoMail-DKIM: pass (identity dpsmith@apertussolutions.com) X-ZM-MESSAGEID: 1729472215546116600 Content-Type: text/plain; charset="utf-8" With construct_dom0 consuming struct boot_domain, continue passing the structure down to dom0_construct_pvh. Signed-off-by: Daniel P. Smith --- Changes since v5: - revert back to using *d as local reference for struct domain --- xen/arch/x86/dom0_build.c | 2 +- xen/arch/x86/hvm/dom0_build.c | 8 ++++---- xen/arch/x86/include/asm/dom0_build.h | 4 +--- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/xen/arch/x86/dom0_build.c b/xen/arch/x86/dom0_build.c index 96cd1154b037..f0d2c349095b 100644 --- a/xen/arch/x86/dom0_build.c +++ b/xen/arch/x86/dom0_build.c @@ -610,7 +610,7 @@ int __init construct_dom0(struct boot_domain *bd) process_pending_softirqs(); =20 if ( is_hvm_domain(d) ) - rc =3D dom0_construct_pvh(bd->d, bd->kernel, bd->ramdisk, bd->cmdl= ine); + rc =3D dom0_construct_pvh(bd); else if ( is_pv_domain(d) ) rc =3D dom0_construct_pv(bd); else diff --git a/xen/arch/x86/hvm/dom0_build.c b/xen/arch/x86/hvm/dom0_build.c index 211f4e3e772e..720e08f9346f 100644 --- a/xen/arch/x86/hvm/dom0_build.c +++ b/xen/arch/x86/hvm/dom0_build.c @@ -1299,10 +1299,9 @@ static void __hwdom_init pvh_setup_mmcfg(struct doma= in *d) } } =20 -int __init dom0_construct_pvh(struct domain *d, const struct boot_module *= image, - struct boot_module *initrd, - const char *cmdline) +int __init dom0_construct_pvh(const struct boot_domain *bd) { + struct domain *d =3D bd->d; paddr_t entry, start_info; int rc; =20 @@ -1345,7 +1344,8 @@ int __init dom0_construct_pvh(struct domain *d, const= struct boot_module *image, return rc; } =20 - rc =3D pvh_load_kernel(d, image, initrd, bootstrap_map_bm(image), cmdl= ine, + rc =3D pvh_load_kernel(d, bd->kernel, bd->ramdisk, + bootstrap_map_bm(bd->kernel), bd->cmdline, &entry, &start_info); if ( rc ) { diff --git a/xen/arch/x86/include/asm/dom0_build.h b/xen/arch/x86/include/a= sm/dom0_build.h index eafa741db16f..adbe90bfd034 100644 --- a/xen/arch/x86/include/asm/dom0_build.h +++ b/xen/arch/x86/include/asm/dom0_build.h @@ -16,9 +16,7 @@ int dom0_setup_permissions(struct domain *d); =20 int dom0_construct_pv(struct boot_domain *bd); =20 -int dom0_construct_pvh(struct domain *d, const struct boot_module *image, - struct boot_module *initrd, - const char *cmdline); +int dom0_construct_pvh(const struct boot_domain *bd); =20 unsigned long dom0_paging_pages(const struct domain *d, unsigned long nr_pages); --=20 2.30.2