From patchwork Fri Apr 18 01:15:24 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chanwoo Choi X-Patchwork-Id: 4012521 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 06319C0DA2 for ; Fri, 18 Apr 2014 01:19:20 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 3BB7D20306 for ; Fri, 18 Apr 2014 01:19:19 +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 54183202EB for ; Fri, 18 Apr 2014 01:19:18 +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 1WaxPk-0006cU-Vo; Fri, 18 Apr 2014 01:16:24 +0000 Received: from mailout1.samsung.com ([203.254.224.24]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WaxPG-0006UJ-Ak for linux-arm-kernel@lists.infradead.org; Fri, 18 Apr 2014 01:15:55 +0000 Received: from epcpsbgr3.samsung.com (u143.gpu120.samsung.co.kr [203.254.230.143]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0N47006LSCTSW670@mailout1.samsung.com> for linux-arm-kernel@lists.infradead.org; Fri, 18 Apr 2014 10:15:28 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [172.20.52.112]) by epcpsbgr3.samsung.com (EPCPMTA) with SMTP id 4A.3D.10092.0BC70535; Fri, 18 Apr 2014 10:15:28 +0900 (KST) X-AuditID: cbfee68f-b7f156d00000276c-9a-53507cb0cc0b Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id DF.A3.28157.FAC70535; Fri, 18 Apr 2014 10:15:28 +0900 (KST) Received: from chan.10.32.193.11 ([10.252.81.195]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0N4700C5CCTPZG70@mmp1.samsung.com>; Fri, 18 Apr 2014 10:15:27 +0900 (KST) From: Chanwoo Choi To: linux-kernel@vger.kernel.org Subject: [PATCHv3 3/7] ARM: EXYNOS: Support secondary CPU boot of Exynos3250 Date: Fri, 18 Apr 2014 10:15:24 +0900 Message-id: <1397783728-6193-4-git-send-email-cw00.choi@samsung.com> X-Mailer: git-send-email 1.8.0 In-reply-to: <1397783728-6193-1-git-send-email-cw00.choi@samsung.com> References: <1397783728-6193-1-git-send-email-cw00.choi@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrMIsWRmVeSWpSXmKPExsWyRsSkQHdDTUCwwecVwhZ/Jx1jt5i07gCT xeX92hbXvzxntZh/5ByrxecPLewWvQuuslmcbXrDbrHp8TVWi8u75rBZzDi/j8ni9mVei793 /rFZnLr+mc3i5J9eRosnhz+yWsyY/JLNYv2M1ywWx2YsYbRo/7uXzWLvzsmMDqIea+atYfRo ae5h8/j9axKjx99VL5g9ds66y+5x59oeNo/NS+o9rpxoYvXo27KK0ePzJrkArigum5TUnMyy 1CJ9uwSujMvrlrIW3OWu6N2/ibWB8SRnFyMnh4SAicTys8/ZIWwxiQv31rN1MXJxCAksZZS4 tuMaK0zRr13bWCASixgl/tw9xQrhNDFJnDs6hwmkik1AS2L/ixtsILaIgILE5t5nYEXMAr+Y JX4+bwbbISzgIzHvwiFGEJtFQFWidcF8sDivgIvEz/0TmSDWyUl82PMILM4p4Cpx/vERFhBb CKjm4ffpLBA1Sz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i4b3w1T9YiDWxrLgy9xCjBAezkgivcmlAsBBvSmJlVWpRfnxRaU5q8SHGZKCr JjJLiSbnA5NTXkm8obGJmZGlkbmhhZGxOWnCSuK8B1utA4UE0hNLUrNTUwtSi2C2MHFwSjUw ltTpCX9i/XC5+5bMfXdZ0cVrVx7P5N7oJOu+UGHrJf0i/duiGxRLAs4ucypSfsv5OLx23a8J L6o32PxivCWaYCFXZnp1taZlZliRSHm15OuwoPuBcw0K3j1hy2qd1b7h/cKO+UyPhVgWT37+ V2vP7S1f3LduuOJVdumArx2rEavzx8uaF6N3KbEUZyQaajEXFScCAIZCu7JEAwAA DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140417_181554_539182_BC2FFE87 X-CRM114-Status: GOOD ( 12.10 ) X-Spam-Score: -5.7 (-----) Cc: sajjan.linux@gmail.com, devicetree@vger.kernel.org, kgene.kim@samsung.com, linux@arm.linux.org.uk, arnd@arndb.de, marc.zyngier@arm.com, t.figa@samsung.com, hyunhee.kim@samsung.com, sw0312.kim@samsung.com, yj44.cho@samsung.com, cw00.choi@samsung.com, kyungmin.park@samsung.com, linux-samsung-soc@vger.kernel.org, thomas.abraham@linaro.org, ben-linux@fluff.org, olof@lixom.net, chanho61.park@samsung.com, sachin.kamat@linaro.org, linux-arm-kernel@lists.infradead.org, tushar.behera@linaro.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,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 This patch fix the offset of CPU boot address and don't need to send smc call of SMC_CMD_CPU1BOOT command for secondary CPU boot because Exynos3250 removes WFE in secure mode. Signed-off-by: Chanwoo Choi Acked-by: Kyungmin Park --- arch/arm/mach-exynos/firmware.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-exynos/firmware.c b/arch/arm/mach-exynos/firmware.c index aa01c42..386d01d 100644 --- a/arch/arm/mach-exynos/firmware.c +++ b/arch/arm/mach-exynos/firmware.c @@ -31,11 +31,17 @@ static int exynos_do_idle(void) static int exynos_cpu_boot(int cpu) { /* + * Exynos3250 doesn't need to send smc command for secondary CPU boot + * because Exynos3250 removes WFE in secure mode. + */ + if (soc_is_exynos3250()) + return 0; + /* * The second parameter of SMC_CMD_CPU1BOOT command means CPU id. * But, Exynos4212 has only one secondary CPU so second parameter * isn't used for informing secure firmware about CPU id. */ - if (soc_is_exynos4212()) + else if (soc_is_exynos4212()) cpu = 0; exynos_smc(SMC_CMD_CPU1BOOT, cpu, 0, 0); @@ -46,7 +52,7 @@ static int exynos_set_cpu_boot_addr(int cpu, unsigned long boot_addr) { void __iomem *boot_reg = S5P_VA_SYSRAM_NS + 0x1c; - if (!soc_is_exynos4212()) + if (!soc_is_exynos4212() && !soc_is_exynos3250()) boot_reg += 4*cpu; __raw_writel(boot_addr, boot_reg);