Received: by 10.223.185.111 with SMTP id b44csp331433wrg; Fri, 9 Mar 2018 05:49:09 -0800 (PST) X-Google-Smtp-Source: AG47ELtGVrMkcx9nv0raYPGVappr64B6+kdgd+YJVfIsEjHnjRwT/naM25y+ssejok6tctelgHgC X-Received: by 10.99.190.68 with SMTP id g4mr24201521pgo.143.1520603349212; Fri, 09 Mar 2018 05:49:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520603349; cv=none; d=google.com; s=arc-20160816; b=DcYX2y2251lF2HyflmcqPCmQuNW2Y3hHmf4uYVkPVzHzD6eKhgYvnKtxSv1rU9PNb3 cS/7DS/tzTEvX+UQXjbtMU9dEMeYzKdKovAmubVr5+aEFJtxHL8AK1TyGazBV+Ymk5oV qOozxGJ0qVABqwM7e8WswOE8KkW3Uh14FDxQu2Cnths6RsPs3Qxyxj9URc8E7Vuv75if z4c1CocHE1ZNoapH+fop/29FP0tySPjZbZ9VdqCmXnIcXm7CXYKfx0U3IX46jCRBa8J7 oCnIY27Kq/NPhRQuKt87vF7s9MC8HgJNkwN7Ko13yLlu9Y9t3kVvjCfgAkS4uvNSn3hn tnhg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=An1iMsl/znKSWAYx5H77JAmuKa4glAiLIsu9Q7BeCSQ=; b=VhCunAAOl02xjlqfZR+kcMpD6rCGXWHTQBS9nPyjKhydb7hHRJfTat1zxwvyg+GseL tmKtSKLLL9kmqq8mqQ4+CKcczWrhn6iAQfOKVOhCwdRD3tZU4AXq4L+J99sWJnYbkpwd UWVqhsFwjKlHCY4aVTYlv9TYkeYa8QrxMt7OnastxRrm62mvrzAHcAl6cKB412Zhzmnx K/NB+nne9Ptof1vCmVRoJqTUqMLlPUf/TtbQpfu9XjPTi00szjaG2+2ul3wYyBo/57Uf ng7q5f3VKgen/jJTSgbb3XFne0H93Tba2zDHZes4ECtYGO3o/df9G/9zNZTs9p7+PoMK hIPA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id bc11-v6si890331plb.43.2018.03.09.05.48.54; Fri, 09 Mar 2018 05:49:09 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932070AbeCINr4 (ORCPT + 99 others); Fri, 9 Mar 2018 08:47:56 -0500 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:51942 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751056AbeCINrz (ORCPT ); Fri, 9 Mar 2018 08:47:55 -0500 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id EFF221529; Fri, 9 Mar 2018 05:47:54 -0800 (PST) Received: from edgewater-inn.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.72.51.249]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id A5CB93F25C; Fri, 9 Mar 2018 05:47:54 -0800 (PST) Received: by edgewater-inn.cambridge.arm.com (Postfix, from userid 1000) id D2ABC1AE53CA; Fri, 9 Mar 2018 13:47:59 +0000 (GMT) Date: Fri, 9 Mar 2018 13:47:59 +0000 From: Will Deacon To: Mark Rutland Cc: Shanker Donthineni , Robin Murphy , linux-kernel , linux-arm-kernel , Catalin Marinas , kvmarm , Marc Zyngier , Vikram Sethi , Philip Elcan Subject: Re: [PATCH v7] arm64: Add support for new control bits CTR_EL0.DIC and CTR_EL0.IDC Message-ID: <20180309134759.GB15537@arm.com> References: <1520434808-29703-1-git-send-email-shankerd@codeaurora.org> <20180309134439.76b43chxnrw7okrw@lakrids.cambridge.arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180309134439.76b43chxnrw7okrw@lakrids.cambridge.arm.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 09, 2018 at 01:44:40PM +0000, Mark Rutland wrote: > On Wed, Mar 07, 2018 at 09:00:08AM -0600, Shanker Donthineni wrote: > > static inline void __flush_icache_all(void) > > { > > - asm("ic ialluis"); > > - dsb(ish); > > + /* Instruction cache invalidation is not required for I/D coherence? */ > > + if (!cpus_have_const_cap(ARM64_HAS_CACHE_DIC)) { > > + asm("ic ialluis"); > > + dsb(ish); > > + } > > } > > I don't think we need the comment here. We don't have this in the other > cases we look at the ARM64_HAS_CACHE_{IDC,DIC} caps. > > This would also be slightly nicer as an early return: > > static inline void __flush_icache_all(void) > { > if (cpus_have_const_cap(ARM64_HAS_CACHE_DIC)) > return; > > asm("ic ialluis"); > dsb(ish); > } > > ... which minimizes indentation, and the diffstat. > > The rest looks fine to me, so with the above changes: > > Reviewed-by: Mark Rutland I've already queued this, but not pushed out yet so I'll fold these changes in. Will