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 X-Spam-Level: X-Spam-Status: No, score=-14.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 78D88C433ED for ; Tue, 4 May 2021 15:32:47 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1716C610FA for ; Tue, 4 May 2021 15:32:47 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1716C610FA Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=0xJPWlr/9GdLuMFOm9c7zTFmKWQj+cEndX6V+gU3Jy8=; b=YYBG88mmTRN7URESFm1ag/y2t Mm5TPgC9t8Rbtqj/WKy0FPM9eTvR8RrIB9l7KaIkCqwRO/GAgBeT4laUgRf6RNbElHbi56XGzgVjl /sjgAGMrTOoFCPhsTT7l/wTcR0JFSqy6bMVEpSkamLerZqdjRzBbZST90mw9S2e5mGOduy6nrvhex TD2MymGWx8a0qnhJ4ubz5suYtW3tS248KGP3xYR7nOww3kZSVAWFJS2rpfW/ANEr0ve7WfZneDLcp 1mSpl7B09XvJwVtpqpxEPAgmZUP7C16Zhnop4EgGbzN4jIszXjMT5msw4R7XvBxgchS7k8+yZWt+v q0vzVAW0w==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1ldx18-00GRTy-Gt; Tue, 04 May 2021 15:31:22 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1ldx16-00GRTe-HN for linux-arm-kernel@desiato.infradead.org; Tue, 04 May 2021 15:31:20 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=vvwEPIcGoNEg1qxhfgA8bseWT4LeE3KIPT6ka9IduuE=; b=yqxjXefXZ8GOumWOX9GjnvtiFs vsGk/P5EScxS0NOE1fMCybphaBMyDGVZsL231jX8E8E0dQzjXNK2ng7z3SMTJEW9x9d7+C77dubAO ySC4e3AP4RYfcD3kzzPtiVBi75ufBGGE9CkOTwdIrjuOj6LLPKbnQXSN4ynav9ypE06zmheW7U6c8 Np6rYPWTR0oOp/KsActUPvMjoDaQDlQpdxDnL1K8QfIO4LnuVPMGws9G5xLa9iRCYiQASHyZTFbjw jXKwx1FwkoDymmwWwsspzldq6ODpq3VuGmjQY7yMbctK9CzMcFrT53d5uLp6Hj5UNts7p4scDGb9H fvV4K0cw==; Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1ldx11-0044Sa-T1 for linux-arm-kernel@lists.infradead.org; Tue, 04 May 2021 15:31:19 +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 E0571D6E; Tue, 4 May 2021 08:31:11 -0700 (PDT) Received: from C02TD0UTHF1T.local (unknown [10.57.1.6]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 028093F718; Tue, 4 May 2021 08:31:10 -0700 (PDT) Date: Tue, 4 May 2021 16:31:08 +0100 From: Mark Rutland To: Marc Zyngier Cc: linux-arm-kernel@lists.infradead.org, broonie@kernel.org, kernel-team@android.com Subject: Re: [AArch64 boot-wrapper][PATCH] aarch64: Enable FGT for EL2 Message-ID: <20210504153108.GB92881@C02TD0UTHF1T.local> References: <20210503120920.1819233-1-maz@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20210503120920.1819233-1-maz@kernel.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210504_083116_008257_77E44E3B X-CRM114-Status: GOOD ( 14.27 ) 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: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, May 03, 2021 at 01:09:20PM +0100, Marc Zyngier wrote: > We have no intention of handling FGT traps to EL3, so let EL2 > play with the feature directly. > > Signed-off-by: Marc Zyngier Thanks; applied. Mark. > --- > > Notes: > Needed to boot Linux 5.13 at EL2. > > arch/aarch64/boot.S | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/arch/aarch64/boot.S b/arch/aarch64/boot.S > index e47cf59..fd7133d 100644 > --- a/arch/aarch64/boot.S > +++ b/arch/aarch64/boot.S > @@ -54,6 +54,13 @@ _start: > cbz x1, 1f > > orr x0, x0, #(1 << 34) // TME enable > +1: > + /* Enable FGT if present */ > + mrs x1, id_aa64mmfr0_el1 > + ubfx x1, x1, #56, #4 > + cbz x1, 1f > + > + orr x0, x0, #(1 << 27) // FGT enable > 1: > #ifndef KERNEL_32 > orr x0, x0, #(1 << 10) // 64-bit EL2 > -- > 2.29.2 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel