From nobody Mon Feb 9 18:18:41 2026 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; 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; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1688549765; cv=none; d=zohomail.com; s=zohoarc; b=knP7KfL29GchIftLGnGNDhYiCG/14bZVipxIMzlc/Sb6BBfwru02tE3DIPkUwV+bCvdh6nUwh4QaPqf9HHAvwSAquMAVm6kMqG83fFYgqzcBaiWQ/L6N+r8YtCWKA4OxtJAYQojfLjqfE25rbFg+Rfb4xV8J0Denj06rWO0Asss= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1688549765; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=am4ipN3ru3xzSJvgYsCfVXNDufmrJ7j+gUVMYasa6R8=; b=jyqI3MPr9chZ4nM14uxxux07/08rnwl9rh8qEvVfaQtyS18GltDj0kP7I6Z0FiFZPK6Ni0e5mO5tM1pM+qZA/bOF3M+2nU0bcRBfd33rNuwbN7TJsRUeKPPXGxcsbJ39WchHWEThz2EWDqO9XlH8PP2+GJTyRF9PmQBAjPIM20Y= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; 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; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1688549765841289.1855469023661; Wed, 5 Jul 2023 02:36:05 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.558881.873361 (Exim 4.92) (envelope-from ) id 1qGyuu-0005fS-Ko; Wed, 05 Jul 2023 09:35:20 +0000 Received: by outflank-mailman (output) from mailman id 558881.873361; Wed, 05 Jul 2023 09:35:20 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qGyuu-0005ed-Fg; Wed, 05 Jul 2023 09:35:20 +0000 Received: by outflank-mailman (input) for mailman id 558881; Wed, 05 Jul 2023 09:35:19 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qGyut-0005bC-MD for xen-devel@lists.xenproject.org; Wed, 05 Jul 2023 09:35:19 +0000 Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [2a00:1450:4864:20::129]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 406545c0-1b17-11ee-8611-37d641c3527e; Wed, 05 Jul 2023 11:35:17 +0200 (CEST) Received: by mail-lf1-x129.google.com with SMTP id 2adb3069b0e04-4fbb281eec6so4765599e87.1 for ; Wed, 05 Jul 2023 02:35:17 -0700 (PDT) Received: from rayden.urgonet (h-46-59-78-111.A175.priv.bahnhof.se. [46.59.78.111]) by smtp.gmail.com with ESMTPSA id q22-20020a2e84d6000000b002b6d8cfb6d2sm2910625ljh.140.2023.07.05.02.35.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 05 Jul 2023 02:35:16 -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: 406545c0-1b17-11ee-8611-37d641c3527e DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1688549716; x=1691141716; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=am4ipN3ru3xzSJvgYsCfVXNDufmrJ7j+gUVMYasa6R8=; b=YRRVF3KTUR2CfX8sPtJGO/1Jng4XNRK/IuXWR5mRgQEIlhCd8cqSgFMhzC/Yndbaqi jQQ1qOWBoOL9CdNIwvvesIQ/g4Gzn9BW3GiAQGINWc0nmYau2qH51TRxkRJOP9hDFk95 JDQAX3XZ7mR81dRnlEXo0nPFWc+N8ASyz3MvXJNIc0t3A0v/77JFbmaHRuH8+zG90zV8 TNdCkmpNNycLL422jOxbgFTGQLdlD4sq7aLzPrCEJay0ScS0BC8V1hPoDfxkQxFlM+rm 6/O2BXb1U3lyXm+ZOd1HicIqgEel/nX5OkPQcTeXcUQodA2mZ7X/sxVdz4Yz3xz1a12m opeg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688549716; x=1691141716; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=am4ipN3ru3xzSJvgYsCfVXNDufmrJ7j+gUVMYasa6R8=; b=kWXTHK3YkqqON6c4nHlEwpyC3FTVQlzxmqz1uLeSib1YisPKvzRnFc1o+jO9v9MRjZ n1Kgzd2taZd2Zw72xiVOyZp36boCnFALSMPfE9ibSIIIV4z+e+j3xPJ1tiw5rnZqmO4Q +dDn5gqZ6Wj+fBZ/8L8kGTKQNqNSTuZM3oDyYpiAqoxo+7pOeO3ckh3KaWeMp1Tzp9Jm gzxG0HZdtVAOQ909qIAPtkj2P4S9n3rFApX5hvdJJk5JXXguiF177Vm8fLp+rK40yQ/o sO8wnTOoOfeNsejm+IHp9CQjuez84mC6pjtCai8TxxqdzQ7Sc1ci7G741ygTzmjD8hem /eYQ== X-Gm-Message-State: ABy/qLYd/DjYMpvXZU+dvHl82fMrj9eZ7Cwfzjm0PvFxNFZZryAWG6C+ 42yDLyvFJcfd2Wo/P7NwWeFTzTI+iBGDmkaO7cg= X-Google-Smtp-Source: APBJJlFmHssN6U2jD6Aj2M55oV1Ks3I50SPjEcyFBfIaeIPGLY9rjYKrdzZePpVHlgKBka1r4/s5Ww== X-Received: by 2002:a2e:8182:0:b0:2b6:cfec:69f7 with SMTP id e2-20020a2e8182000000b002b6cfec69f7mr10183434ljg.1.1688549716784; Wed, 05 Jul 2023 02:35:16 -0700 (PDT) From: Jens Wiklander To: xen-devel@lists.xenproject.org Cc: Stefano Stabellini , Julien Grall , Volodymyr Babchuk , Bertrand.Marquis@arm.com, Anthony PERARD , Juergen Gross , Wei Liu , Marc Bonnici , Achin Gupta , Andrew Cooper , George Dunlap , =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= , Jan Beulich , Bertrand Marquis , Jens Wiklander Subject: [XEN PATCH v9 01/24] xen: Introduce arch_domain_teardown() Date: Wed, 5 Jul 2023 11:34:10 +0200 Message-Id: <20230705093433.2514898-2-jens.wiklander@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230705093433.2514898-1-jens.wiklander@linaro.org> References: <20230705093433.2514898-1-jens.wiklander@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1688549766433100011 From: Andrew Cooper Plumb it into domain_teardown(). Provide arch_val in the teardown continuation information for use by arch_domain_teardown(). No practical change. Signed-off-by: Andrew Cooper Signed-off-by: Jens Wiklander Reviewed-by: Bertrand Marquis Reviewed-by: Jan Beulich --- CC: Jan Beulich CC: Roger Pau Monn=C3=A9 CC: Wei Liu CC: Stefano Stabellini CC: Julien Grall CC: Volodymyr Babchuk CC: Bertrand Marquis CC: Jens Wiklander --- xen/arch/arm/domain.c | 5 +++++ xen/arch/x86/domain.c | 5 +++++ xen/common/domain.c | 6 ++++++ xen/include/xen/domain.h | 1 + xen/include/xen/sched.h | 1 + 5 files changed, 18 insertions(+) diff --git a/xen/arch/arm/domain.c b/xen/arch/arm/domain.c index 8c18e9207907..15d9709a97d2 100644 --- a/xen/arch/arm/domain.c +++ b/xen/arch/arm/domain.c @@ -793,6 +793,11 @@ fail: return rc; } =20 +int arch_domain_teardown(struct domain *d) +{ + return 0; +} + void arch_domain_destroy(struct domain *d) { /* IOMMU page table is shared with P2M, always call diff --git a/xen/arch/x86/domain.c b/xen/arch/x86/domain.c index 39c215316546..5f66c2ae33d7 100644 --- a/xen/arch/x86/domain.c +++ b/xen/arch/x86/domain.c @@ -888,6 +888,11 @@ int arch_domain_create(struct domain *d, return rc; } =20 +int arch_domain_teardown(struct domain *d) +{ + return 0; +} + void arch_domain_destroy(struct domain *d) { if ( is_hvm_domain(d) ) diff --git a/xen/common/domain.c b/xen/common/domain.c index caaa40263792..304aa04fa6cb 100644 --- a/xen/common/domain.c +++ b/xen/common/domain.c @@ -439,6 +439,7 @@ static int domain_teardown(struct domain *d) PROG_none, PROG_gnttab_mappings, PROG_vcpu_teardown, + PROG_arch_teardown, PROG_done, }; =20 @@ -459,6 +460,11 @@ static int domain_teardown(struct domain *d) return rc; } =20 + PROGRESS(arch_teardown): + rc =3D arch_domain_teardown(d); + if ( rc ) + return rc; + PROGRESS(done): break; =20 diff --git a/xen/include/xen/domain.h b/xen/include/xen/domain.h index 1df8f933d076..d35af348410c 100644 --- a/xen/include/xen/domain.h +++ b/xen/include/xen/domain.h @@ -81,6 +81,7 @@ int arch_domain_create(struct domain *d, struct xen_domctl_createdomain *config, unsigned int flags); =20 +int arch_domain_teardown(struct domain *d); void arch_domain_destroy(struct domain *d); =20 void arch_domain_shutdown(struct domain *d); diff --git a/xen/include/xen/sched.h b/xen/include/xen/sched.h index 85242a73d374..854f3e32c00e 100644 --- a/xen/include/xen/sched.h +++ b/xen/include/xen/sched.h @@ -589,6 +589,7 @@ struct domain */ struct { unsigned int val; + unsigned int arch_val; struct vcpu *vcpu; } teardown; =20 --=20 2.34.1