From patchwork Tue Jan 29 11:38:53 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: srinidhi kasagar X-Patchwork-Id: 2061221 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id C308BDF23E for ; Tue, 29 Jan 2013 11:43:33 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1U09XD-0004Bs-Fq; Tue, 29 Jan 2013 11:39:27 +0000 Received: from eu1sys200aog117.obsmtp.com ([207.126.144.143]) by merlin.infradead.org with smtps (Exim 4.76 #1 (Red Hat Linux)) id 1U09XA-0004BO-33 for linux-arm-kernel@lists.infradead.org; Tue, 29 Jan 2013 11:39:24 +0000 Received: from beta.dmz-us.st.com ([167.4.1.35]) (using TLSv1) by eu1sys200aob117.postini.com ([207.126.147.11]) with SMTP ID DSNKUQe02GUSFhj94Jf7PCh/nNtq2wBXxJBN@postini.com; Tue, 29 Jan 2013 11:39:23 UTC Received: from zeta.dmz-us.st.com (ns4.st.com [167.4.16.71]) by beta.dmz-us.st.com (STMicroelectronics) with ESMTP id 59BE445; Tue, 29 Jan 2013 11:38:13 +0000 (GMT) Received: from relay1.stm.gmessaging.net (unknown [10.230.100.17]) by zeta.dmz-us.st.com (STMicroelectronics) with ESMTP id 3E3D298; Tue, 29 Jan 2013 05:51:46 +0000 (GMT) Received: from exdcvycastm022.EQ1STM.local (alteon-source-exch [10.230.100.61]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (Client CN "exdcvycastm022", Issuer "exdcvycastm022" (not verified)) by relay1.stm.gmessaging.net (Postfix) with ESMTPS id 55B4624C2E5; Tue, 29 Jan 2013 12:38:51 +0100 (CET) Received: from localhost (10.201.54.34) by exdcvycastm022.EQ1STM.local (10.230.100.30) with Microsoft SMTP Server (TLS) id 8.3.83.0; Tue, 29 Jan 2013 12:38:56 +0100 Date: Tue, 29 Jan 2013 17:08:53 +0530 From: Srinidhi Kasagar To: Russell King - ARM Linux Subject: Re: [PATCH v1 1/5] ARM: cache-l2x0: add 'smc' identifier Message-ID: <20130129113853.GA22145@bnru10> References: <20130129101328.GA11878@bnru10> <20130129113325.GG2637@n2100.arm.linux.org.uk> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20130129113325.GG2637@n2100.arm.linux.org.uk> User-Agent: Mutt/1.5.20 (2009-06-14) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130129_063924_361404_D00B86FB X-CRM114-Status: GOOD ( 20.88 ) X-Spam-Score: -4.2 (----) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-4.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [207.126.144.143 listed in list.dnswl.org] -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: "kgene.kim@samsung.com" , "horms@verge.net.au" , "tony@atomide.com" , "linus.walleij@linaro.org" , "avorontsov@mvista.com" , "magnus.damm@gmail.com" , "linux-omap@vger.kernel.org" , "linux-samsung-soc@vger.kernel.org" , "viresh.linux@gmail.com" , "kernel@pengutronix.de" , "gregory.clement@free-electrons.com" , "shawn.guo@linaro.org" , "linux-arm-kernel@lists.infradead.org" , "rubini@unipv.it" X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org On Tue, Jan 29, 2013 at 12:33:25 +0100, Russell King - ARM Linux wrote: > On Tue, Jan 29, 2013 at 03:43:31PM +0530, srinidhi kasagar wrote: > > Add 'smc' (Secure Monitor Call) identifier to differentiates > > the platforms which implements this. > > This patch makes no sense. > > So, if setting 'smc' in the DT description is supposed to mean that > the platform has a secure monitor then... > > > + is_smc = of_property_read_bool(np, "smc"); > > + > > + if (is_smc) { > > + /* set the debug interface */ > > + outer_cache.set_debug = pl310_set_debug; > > + } > > Now, let's look at what pl310_set_debug() does: > > static void pl310_set_debug(unsigned long val) > { > writel_relaxed(val, l2x0_base + L2X0_DEBUG_CTRL); > } > > Can you explain where the secure monitor call is there please, because > I can't see one. In fact, this is the function used when there _isn't_ > a secure monitor. So this patch just seems totally wrong to me. Today, one and only platform is omap. Please check below snapshot: --- a/arch/arm/boot/dts/omap4.dtsi +++ b/arch/arm/boot/dts/omap4.dtsi @@ -51,6 +51,7 @@ reg = <0x48242000 0x1000>; cache-unified; cache-level = <2>; + smc; }; [...] --- a/arch/arm/mach-omap2/omap4-common.c +++ b/arch/arm/mach-omap2/omap4-common.c @@ -214,7 +214,7 @@ static int __init omap_l2_cache_init(void) if (of_have_populated_dt()) l2x0_of_init(aux_ctrl, L2X0_AUX_CTRL_MASK); else - l2x0_init(l2cache_base, aux_ctrl, L2X0_AUX_CTRL_MASK); + l2x0_init(l2cache_base, aux_ctrl, L2X0_AUX_CTRL_MASK, true); regards/srinidhi