From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B2A5FD2446F for ; Fri, 11 Oct 2024 11:08:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=r5DzHKpTVKLrsVa8psxGIH4jQbmu9j1ZZEjhny8w1VU=; b=2DQMZiQJ6K5z418AfPPB/NyaTH y95SWu8HhE/xBZ9KRX+iR55dGLfr0P5Ln5yTvTXt/LB1DrWvXRsBbSw4KE//BtX4tR+MtddytGuHX BoXzn6X38Ncj8IPulF5Svj1Y6sK2GyW0jvpA4ade7GqedZGyZ1A/dc4TviMKolm96vNqEuoEYxWjT b3QDE1GhEGkLOanir6/abUOxQiUdldImzidH5WEtnWiPnLEWO0AMix/G7tyRT9QbFw1c+hJ+asXc8 Wqj9BfiSwDMvQFpilymNoXxhkGyShhy0vnjCSSHhcF8yHk6aq5vmqksoxcg3fEV7+ihwj1viTlxH6 1nCQ9khg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1szDVD-0000000G6h4-0PT8; Fri, 11 Oct 2024 11:08:11 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1szDJf-0000000G4In-1Ln7 for linux-arm-kernel@lists.infradead.org; Fri, 11 Oct 2024 10:56:17 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id E0E4E497; Fri, 11 Oct 2024 03:56:43 -0700 (PDT) Received: from J2N7QTR9R3 (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 56C333F73F; Fri, 11 Oct 2024 03:56:13 -0700 (PDT) Date: Fri, 11 Oct 2024 11:56:10 +0100 From: Mark Rutland To: Luca Fancellu Cc: andre.przywara@arm.com, linux-arm-kernel@lists.infradead.org Subject: Re: [boot-wrapper v3 4/4] aarch64: Start Xen on Armv8-R at EL2 Message-ID: References: <20240731141103.2559706-1-luca.fancellu@arm.com> <20240731141103.2559706-5-luca.fancellu@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240731141103.2559706-5-luca.fancellu@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241011_035615_507747_58FB37A3 X-CRM114-Status: GOOD ( 17.41 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Jul 31, 2024 at 03:11:03PM +0100, Luca Fancellu wrote: > When bootwrapper is compiled with Xen support and it is started > at EL2 on Armv8-R AArch64, keep the current EL and jump to the > Xen image using the SPSR_KERNEL as spsr_el2 value. > > Signed-off-by: Luca Fancellu > --- > Changes from v2: > - Major rework, reason in the cover letter. > --- > Makefile.am | 1 + > arch/aarch64/boot.S | 2 +- > 2 files changed, 2 insertions(+), 1 deletion(-) > > diff --git a/Makefile.am b/Makefile.am > index 62e2988c0dd3..0aee117eb827 100644 > --- a/Makefile.am > +++ b/Makefile.am > @@ -113,6 +113,7 @@ XEN_CHOSEN := xen,xen-bootargs = \"$(XEN_CMDLINE)\"; \ > compatible = \"xen,linux-zimage\", \"xen,multiboot-module\"; \ > reg = <0x0 $(DOM0_OFFSET) 0x0 $(KERNEL_SIZE)>; \ > }; > +DEFINES += -DXEN > endif > > if INITRD > diff --git a/arch/aarch64/boot.S b/arch/aarch64/boot.S > index 0b4f6824045a..d50ff48d83de 100644 > --- a/arch/aarch64/boot.S > +++ b/arch/aarch64/boot.S > @@ -100,7 +100,7 @@ ASM_FUNC(jump_kernel) > mov x1, x21 > mov x2, x22 > mov x3, x23 > -#if defined(BOOTWRAPPER_64R) > +#if defined(BOOTWRAPPER_64R) && !defined(XEN) > // On Armv8-R Linux needs to be booted at EL1 > mov x4, #SPSR_KERNEL_EL1 > #else FWIW, this looks fine to me. Mark.