From patchwork Sat Apr 26 12:17:03 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marc Zyngier X-Patchwork-Id: 29149 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ve0-f198.google.com (mail-ve0-f198.google.com [209.85.128.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id E8E08202E6 for ; Sat, 26 Apr 2014 12:17:36 +0000 (UTC) Received: by mail-ve0-f198.google.com with SMTP id oz11sf19080911veb.9 for ; Sat, 26 Apr 2014 05:17:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:in-reply-to :references:subject:precedence:list-id:list-unsubscribe:list-archive :list-post:list-help:list-subscribe:mime-version:sender:errors-to :x-original-sender:x-original-authentication-results:mailing-list :content-type:content-transfer-encoding; bh=7sKC22S5+9/J5WOK3ywjSD661arDO05C4u7gMpDPDF0=; b=fG5r8TvdP05MKrxy7FSsFvUMi81ZphbHVOMha3LBxIcmJuIotHIv58yMoo8tqWAM+d VmZJ4beFFLx2DCA+U9Z51B/mrpjZ13Q2JTjfAUOKfUQkotTts0qT3J6H+GLi2w0HPwtg grDecZiA11SMFDO7/TuDIA4nO2E55+PjCTqAQ/Okqfn2Qy/jaHTFmgyVE7UJhF9CZ1Uj EOL+dC7rS+1frYGB3lu+4muql4AolfMfwLAvm8xJjRKhwzlFj0KWANW702b6PqE54yec PXgR25l2yAwTilhntf1Eg7FGeU9N4k3YuzK0FItZ/79szcqV+KVRGZK1X1Bx5zoEj1XH K3bQ== X-Gm-Message-State: ALoCoQkmAfrd2ZoFnF9RLO/R4Jvv5W7BWDryQZ4KCTArFGLdqxCyvthhvZ/I3yVwKi0gYgoFDue3 X-Received: by 10.236.171.169 with SMTP id r29mr397795yhl.32.1398514656635; Sat, 26 Apr 2014 05:17:36 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.21.40 with SMTP id 37ls1874390qgk.32.gmail; Sat, 26 Apr 2014 05:17:36 -0700 (PDT) X-Received: by 10.220.147.16 with SMTP id j16mr12161768vcv.14.1398514656535; Sat, 26 Apr 2014 05:17:36 -0700 (PDT) Received: from mail-vc0-f181.google.com (mail-vc0-f181.google.com [209.85.220.181]) by mx.google.com with ESMTPS id tz5si2399596vdc.7.2014.04.26.05.17.36 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 26 Apr 2014 05:17:36 -0700 (PDT) Received-SPF: none (google.com: patch+caf_=patchwork-forward=linaro.org@linaro.org does not designate permitted sender hosts) client-ip=209.85.220.181; Received: by mail-vc0-f181.google.com with SMTP id hy4so138842vcb.26 for ; Sat, 26 Apr 2014 05:17:36 -0700 (PDT) X-Received: by 10.52.255.99 with SMTP id ap3mr8531385vdd.19.1398514656224; Sat, 26 Apr 2014 05:17:36 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.221.72 with SMTP id ib8csp164747vcb; Sat, 26 Apr 2014 05:17:35 -0700 (PDT) X-Received: by 10.14.204.199 with SMTP id h47mr4212730eeo.48.1398514655322; Sat, 26 Apr 2014 05:17:35 -0700 (PDT) Received: from theia.denx.de (theia.denx.de. [85.214.87.163]) by mx.google.com with ESMTP id y41si16512429eel.110.2014.04.26.05.17.34 for ; Sat, 26 Apr 2014 05:17:35 -0700 (PDT) Received-SPF: none (google.com: u-boot-bounces@lists.denx.de does not designate permitted sender hosts) client-ip=85.214.87.163; Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 71FA94BFC3; Sat, 26 Apr 2014 14:17:34 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2g2ZE-fRtNx7; Sat, 26 Apr 2014 14:17:34 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 679C54BEEC; Sat, 26 Apr 2014 14:17:29 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id B146B4BFC8 for ; Sat, 26 Apr 2014 14:17:27 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7O8ycRdKfvcC for ; Sat, 26 Apr 2014 14:17:23 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from inca-roads.misterjones.org (inca-roads.misterjones.org [213.251.177.50]) by theia.denx.de (Postfix) with ESMTPS id 302424BEEC for ; Sat, 26 Apr 2014 14:17:19 +0200 (CEST) Received: from [2.125.202.75] (helo=why.wild-wind.fr.eu.org) by cheepnis.misterjones.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA256:128) (Exim 4.80) (envelope-from ) id 1We1Xj-0003DF-Ba; Sat, 26 Apr 2014 14:17:19 +0200 From: Marc Zyngier To: u-boot@lists.denx.de Date: Sat, 26 Apr 2014 13:17:03 +0100 Message-Id: <1398514631-23956-3-git-send-email-marc.zyngier@arm.com> X-Mailer: git-send-email 1.9.2 In-Reply-To: <1398514631-23956-1-git-send-email-marc.zyngier@arm.com> References: <1398514631-23956-1-git-send-email-marc.zyngier@arm.com> X-SA-Exim-Connect-IP: 2.125.202.75 X-SA-Exim-Rcpt-To: u-boot@lists.denx.de, albert.u.boot@aribaud.net X-SA-Exim-Mail-From: marc.zyngier@arm.com X-SA-Exim-Scanned: No (on cheepnis.misterjones.org); SAEximRunCond expanded to false Subject: [U-Boot] [PATCH v4 02/10] ARM: HYP/non-sec: add a barrier after setting SCR.NS==1 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: marc.zyngier@arm.com X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: patch+caf_=patchwork-forward=linaro.org@linaro.org does not designate permitted sender hosts) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 A CP15 instruction execution can be reordered, requiring an isb to be sure it is executed in program order. Signed-off-by: Marc Zyngier --- arch/arm/cpu/armv7/nonsec_virt.S | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/cpu/armv7/nonsec_virt.S b/arch/arm/cpu/armv7/nonsec_virt.S index 6367e09..12de5c2 100644 --- a/arch/arm/cpu/armv7/nonsec_virt.S +++ b/arch/arm/cpu/armv7/nonsec_virt.S @@ -46,6 +46,7 @@ _secure_monitor: #endif mcr p15, 0, r1, c1, c1, 0 @ write SCR (with NS bit set) + isb #ifdef CONFIG_ARMV7_VIRT mrceq p15, 0, r0, c12, c0, 1 @ get MVBAR value