From nobody Tue Feb 10 13:18:10 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 ARC-Seal: i=1; a=rsa-sha256; t=1687194116; cv=none; d=zohomail.com; s=zohoarc; b=TfovvLomqd3UYTen2qENBND6JeY3zMcwhkehJlod+4+RtnCmVNmYWtaZDWVIcgWkf12vLvwzV89UdRwlV07ANdsHu8JcrB/WJ5K9BgynriWnEAbVpuejJS654yqAGw9H4gtckTLqOKxMNQikkrGIP/tmai31DFPiGvSqNvuSFqo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1687194116; h=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=XCDJIqgFhmZ0JxJIz/CX3QdAY7V9+R7dcjMnAbPAVAE=; b=fJAVp+UjkFSaY0F2599FBhO/nVp/fVsfh3w7l9FTHEK/okjRi+zZvNLJIHpQPCBP8vYi1cSyYUNAzoIiTJ5v9hpMb15fIXADzZM2tUTcKP6GHoG7Lp6nB3+ZZsl/ox7AMU0utxzg1OrdUMxlfT9/gtxTCNKpkfo/elygpiOTPek= 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 Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1687194116175283.76536269248186; Mon, 19 Jun 2023 10:01:56 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.551243.860690 (Exim 4.92) (envelope-from ) id 1qBIFn-0003fM-N4; Mon, 19 Jun 2023 17:01:23 +0000 Received: by outflank-mailman (output) from mailman id 551243.860690; Mon, 19 Jun 2023 17:01:23 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qBIFn-0003fD-Jy; Mon, 19 Jun 2023 17:01:23 +0000 Received: by outflank-mailman (input) for mailman id 551243; Mon, 19 Jun 2023 17:01:21 +0000 Received: from mail.xenproject.org ([104.130.215.37]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qBIFl-0003PJ-SG for xen-devel@lists.xenproject.org; Mon, 19 Jun 2023 17:01:21 +0000 Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qBIFl-0002e8-I0; Mon, 19 Jun 2023 17:01:21 +0000 Received: from 54-240-197-232.amazon.com ([54.240.197.232] helo=dev-dsk-jgrall-1b-035652ec.eu-west-1.amazon.com) by xenbits.xenproject.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1qBIFl-00079R-AP; Mon, 19 Jun 2023 17:01:21 +0000 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" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=xen.org; s=20200302mail; h=Content-Transfer-Encoding:MIME-Version:References: In-Reply-To:Message-Id:Date:Subject:Cc:To:From; bh=XCDJIqgFhmZ0JxJIz/CX3QdAY7V9+R7dcjMnAbPAVAE=; b=b7G86f2/m0YHDlxFFdfMktxZJS FuYmVBB/wK3s2CWthe5OwcpPFpnf6QsPtkDVNK5eW7hAjBWdSCsMq6Tpt/6tLCKvbGYW8eKB2rB1D 2ivqbwODXI6tEjaLVcaRFhYXb//cySMhPkad7kRm3RFV8TX2sUd+U0GrOHqYw8bJKg/o=; From: Julien Grall To: xen-devel@lists.xenproject.org Cc: Luca.Fancellu@arm.com, michal.orzel@amd.com, Henry.Wang@arm.com, Julien Grall , Stefano Stabellini , Julien Grall , Bertrand Marquis , Volodymyr Babchuk Subject: [PATCH 2/7] xen/arm32: head: Add mising isb in switch_to_runtime_mapping() Date: Mon, 19 Jun 2023 18:01:10 +0100 Message-Id: <20230619170115.81398-3-julien@xen.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230619170115.81398-1-julien@xen.org> References: <20230619170115.81398-1-julien@xen.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @xen.org) X-ZM-MESSAGEID: 1687194118009100001 Content-Type: text/plain; charset="utf-8" From: Julien Grall Per the Arm Arm (ARM DDI 0406C.d A3.8.3): "The DMB and DSB memory barriers affect reads and writes to the memory system generated by load/store instructions and data or unified cache maintenance operations being executed by the processor. Instruction fetches or accesses caused by a hardware translation table access are not explicit accesses." The function switch_to_runtime_mapping() is responsible to map the Xen at its runtime address if we were using the temporary area before jumping returning using a runtime address. So we need to ensure the 'dsb' has completed before continuing. Therefore add an 'isb'. Fixes: fbd9b5fb4c26 ("xen/arm32: head: Remove restriction where to load Xen= ") Signed-off-by: Julien Grall Reviewed-by: Bertrand Marquis Reviewed-by: Henry Wang Reviewed-by: Luca Fancellu Tested-by: Henry Wang --- xen/arch/arm/arm32/head.S | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/xen/arch/arm/arm32/head.S b/xen/arch/arm/arm32/head.S index 6ca3329138e3..b942e7e54d08 100644 --- a/xen/arch/arm/arm32/head.S +++ b/xen/arch/arm/arm32/head.S @@ -656,6 +656,11 @@ switch_to_runtime_mapping: =20 /* Ensure any page table updates are visible before continuing */ dsb nsh + /* + * The function will return on the runtime mapping. So we want + * to prevent instruction fetch before the dsb completes. + */ + isb =20 ready_to_switch: mov pc, lr --=20 2.40.1