From patchwork Tue May 19 21:55:12 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 6440711 Return-Path: X-Original-To: patchwork-linux-rockchip@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 892B5C0432 for ; Tue, 19 May 2015 21:57:15 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 8E3252013A for ; Tue, 19 May 2015 21:57:14 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8BED92012D for ; Tue, 19 May 2015 21:57:13 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1YupVf-0006tl-Vv; Tue, 19 May 2015 21:57:11 +0000 Received: from mout.kundenserver.de ([212.227.17.13]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YupVS-0006rE-Ni; Tue, 19 May 2015 21:57:00 +0000 Received: from wuerfel.localnet ([149.172.15.242]) by mrelayeu.kundenserver.de (mreue102) with ESMTPSA (Nemesis) id 0M2v1a-1ZCurX0qSk-00saoX; Tue, 19 May 2015 23:55:22 +0200 From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH] ARM: v7 setup function should invalidate L1 cache Date: Tue, 19 May 2015 23:55:12 +0200 Message-ID: <2080993.BUNZpO9uLL@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) In-Reply-To: <6452458.LAJUB33YSi@phil> References: <6452458.LAJUB33YSi@phil> MIME-Version: 1.0 X-Provags-ID: V03:K0:q+ClVW6b2ECHqDKn4DjDKxbF4hbR8uapO4r5gizSTFwtgcp6Bv2 0mqb7W0r9ERJpZgdLrWnaliYZAzqhz9gzyyR/gp2mi9RF7he8c5jfaZFzTX7IVCbwwhrB9K ZaCEYOiMTsHgqncVEdK76PxmxJSL2bNZfTA4DJlYGFEc3cwYd7kwUBXbb3rtbs5RgwsoZWm GX0DmrlXUot1xhsQG2S8g== X-UI-Out-Filterresults: notjunk:1; X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150519_145659_138588_F038D89F X-CRM114-Status: GOOD ( 11.43 ) X-Spam-Score: -1.1 (-) Cc: Andrew Lunn , Heiko Stuebner , linux-sh@vger.kernel.org, Gregory Clement , Thierry Reding , Alexandre Courbot , Florian Fainelli , Magnus Damm , Michal Simek , Wei Xu , linux-rockchip@lists.infradead.org, bcm-kernel-feedback-list@broadcom.com, Michael =?ISO-8859-1?Q?Niew=F6hner?= , Sebastian Hesselbarth , Jason Cooper , Stephen Warren , Marc Carino , Simon Horman , Gregory Fong , Russell King , linux-tegra@vger.kernel.org, =?ISO-8859-1?Q?S=C3=B6ren?= Brinkmann , Barry Song , Shawn Guo , Christian Daudt , Sascha Hauer , Dinh Nguyen , Brian Norris X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Tuesday 19 May 2015 23:44:58 Heiko Stuebner wrote: > > Michael Niewoehner tested this on a rk3188 (Cortex-A9) and wrote in [0] > > Tested-by: Michael Niewoehner > > > > Tested on Radxa Rock Pro with RK3188. > > The kernel panics on reboot I had before and also a kernel BUG when running > > "memtester 1900M" went away and the rock seems to run stable now. > We should probably create a separate fix for that and add it to the stable kernels then. I would suggest something like the untested patch below, which takes advantage of the fact that we already have separate assignments for the start_secondary function pointer for A9 and A17. Arnd diff --git a/arch/arm/mach-rockchip/headsmp.S b/arch/arm/mach-rockchip/headsmp.S index 46c22dedf632..ae0077e8fe98 100644 --- a/arch/arm/mach-rockchip/headsmp.S +++ b/arch/arm/mach-rockchip/headsmp.S @@ -16,9 +16,6 @@ #include ENTRY(rockchip_secondary_startup) - mrc p15, 0, r0, c0, c0, 0 @ read main ID register - ldr r1, =0x00000c09 @ Cortex-A9 primary part number - teq r0, r1 beq v7_invalidate_l1 b secondary_startup ENDPROC(rockchip_secondary_startup) diff --git a/arch/arm/mach-rockchip/platsmp.c b/arch/arm/mach-rockchip/platsmp.c index 5b4ca3c3c879..5f46724cca2f 100644 --- a/arch/arm/mach-rockchip/platsmp.c +++ b/arch/arm/mach-rockchip/platsmp.c @@ -149,8 +149,7 @@ static int __cpuinit rockchip_boot_secondary(unsigned int cpu, * sram_base_addr + 8: start address for pc * */ udelay(10); - writel(virt_to_phys(rockchip_secondary_startup), - sram_base_addr + 8); + writel(virt_to_phys(secondary_startup), sram_base_addr + 8); writel(0xDEADBEAF, sram_base_addr + 4); dsb_sev(); }