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=-12.3 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 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 4FA34C4338F for ; Sat, 24 Jul 2021 20:42:33 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id B5FAD60725 for ; Sat, 24 Jul 2021 20:42:32 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org B5FAD60725 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id A04BB831A9; Sat, 24 Jul 2021 22:42:27 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=konsulko.com header.i=@konsulko.com header.b="hI8hTmEr"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 268F683189; Sat, 24 Jul 2021 22:40:50 +0200 (CEST) Received: from mail-qt1-x836.google.com (mail-qt1-x836.google.com [IPv6:2607:f8b0:4864:20::836]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 7927C83148 for ; Sat, 24 Jul 2021 22:40:43 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-qt1-x836.google.com with SMTP id w10so4211187qtj.3 for ; Sat, 24 Jul 2021 13:40:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=ZnogPzUzToptm/NNpfPo/x1HD48HshTmGXqWMZQ3DUY=; b=hI8hTmEro/pXb9WN761nbgweHUPTndRhP5bIuJiQmMDz7INGInWoU2Li9V1HXlacpd Fqcjkp3MxanMXNI3EbpcrAz01Efw2yAgXjKcw8nVPDYiY0Sfrua8VPkHNnuC14eVqmkF V9njLspo4xEBKGRKpc7bNQw//6kFWseikeTUM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=ZnogPzUzToptm/NNpfPo/x1HD48HshTmGXqWMZQ3DUY=; b=h7GgLWv7VeEpEnxt1XWslS+WM7YsdNm1r/gfnqddQupK0aQAA5T168gr/Uc+kHgFS9 YOeCqrhakzhN6/TKz5LoGniIuw8d5J9OyAIYCi0MJJr3uKdu1hCuQqCKjkbxx3e+X8RI m8Ro59WkN49sayVazZ5jg/gMjHnOf//8NqatU4hgpbV8pFI5S1oZ/WIQX0y/pVja5QzI br4LpHSDuSLBycHSZiA9IfUwnk88bEMd+488zrVL5pLo/z/+hs+u9u97tfbC0MaOGDZn d8HqhtaHVoIkzA6V0I7RkRQ5HQpJWJUKZWHngG7iZVwbuaqra26ijJUtKEX5lmOM/dzc ab2Q== X-Gm-Message-State: AOAM531InctNgLbdMNGdrPAqW8dPtFIrJ5Vrq8yWGHPdiIxf3vsyUk+T zXtpMhuTIs5J10lFVh+5XhRAqQ== X-Google-Smtp-Source: ABdhPJwRWS1bMnyIv9yWojLy3sNIBSt86+1wiUkHJzAPxS19dsdeg86ls4Wdszx5sEILyF7y6Fmx8w== X-Received: by 2002:a05:622a:60c:: with SMTP id z12mr9168446qta.295.1627159242347; Sat, 24 Jul 2021 13:40:42 -0700 (PDT) Received: from bill-the-cat (2603-6081-7b01-cbda-0853-2920-f0b9-3dd6.res6.spectrum.com. [2603:6081:7b01:cbda:853:2920:f0b9:3dd6]) by smtp.gmail.com with ESMTPSA id t10sm853885qti.94.2021.07.24.13.40.41 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 24 Jul 2021 13:40:41 -0700 (PDT) Date: Sat, 24 Jul 2021 16:40:39 -0400 From: Tom Rini To: Peter Hoyes Cc: u-boot@lists.denx.de, Stephen Warren , Michal Simek , "Edgar E . Iglesias" , Andre Przywara , Diego Sueiro Subject: Re: [PATCH] armv8: Initialize CNTFRQ if at highest exception level Message-ID: <20210724204039.GW9379@bill-the-cat> References: <20210712140421.3532104-1-peter.hoyes@arm.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="vHmniAU8lLDT2+7p" Content-Disposition: inline In-Reply-To: <20210712140421.3532104-1-peter.hoyes@arm.com> X-Clacks-Overhead: GNU Terry Pratchett User-Agent: Mutt/1.9.4 (2018-02-28) X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean --vHmniAU8lLDT2+7p Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jul 12, 2021 at 03:04:21PM +0100, Peter Hoyes wrote: > From: Peter Hoyes >=20 > CNTFRQ_EL0 is only writable from the highest supported exception > level on the platform. For Armv8-A, this is typically EL3, but > technically EL2 and EL3 are optional so it may need to be > initialized at EL2 or EL1. For Armv8-R, the highest exception > level is always EL2. >=20 > This patch moves the initialization outside of the switch_el > block and uses a new macro branch_if_not_highest_el which > dynamically detects whether it is at the highest supported > exception level. >=20 > Linux's docs state that CNTFRQ_EL0 should be initialized by the > bootloader. If not set, the the U-Boot prompt countdown hangs. >=20 > Signed-off-by: Peter Hoyes Applied to u-boot/master, thanks! --=20 Tom --vHmniAU8lLDT2+7p Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmD8escACgkQFHw5/5Y0 tyxqMAwAtvH6dZrZOCuhSrosHv8n24dcAgmHRj1jZsDVwEKxJWkDRMZWKVZCKHrh XqaPJakXc6j52JIfxGmVFqihpjcCEsHc7AAj+Eq2CyPptAaJuhGf2ZGu9TPHC2sw Ucsj7ebPqiq5IGhp66Cb3TEx8s+mVTNybwKhZQy1TXBgfllZruZtzLuap29pM4k6 Z3rVNKveFJQ6a7NtsK1JyPiXMwT6ITRkHim5CQem/RRRv5hXub3DCbJ7sfCyv/r8 Kl9ENaNSe6KZRWNde0aJD1GtzDNWtyFGMUtuk1zogPOoT8sl7yFdVCIzCeTigoEc Wldu8dIYsmroMGGAj0W5aTSVo70wbZXsOKHKLTpeSuarYO9DbXonpnbblPSyidNE bNwtZ8MwaY7F90EjVrwyR7woGwvP/uZ9NowPXeTCVjJnUp6IRLUFRP7RLcdO0daR fCuYu5JbqVkSIssRLLHfGqHJ9RjzmNifgZmYH9E79HrZ+s/onnxJAQtrcwxSUW5l YAjAYtzG =UKrv -----END PGP SIGNATURE----- --vHmniAU8lLDT2+7p--