From patchwork Tue Dec 18 08:42:49 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudio Fontana X-Patchwork-Id: 1890931 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork1.kernel.org (Postfix) with ESMTP id 1436E3FC81 for ; Tue, 18 Dec 2012 08:46:45 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1Tkslc-0003nl-Kp; Tue, 18 Dec 2012 08:43:12 +0000 Received: from szxga04-in.huawei.com ([119.145.14.67]) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TkslZ-0003nU-Ce for linux-arm-kernel@lists.infradead.org; Tue, 18 Dec 2012 08:43:11 +0000 Received: from huawei.com (szxga04-in [172.24.2.12]) by szxga04-in.huawei.com (iPlanet Messaging Server 5.2 HotFix 2.14 (built Aug 8 2006)) with ESMTP id <0MF70064OXJQU6@szxga04-in.huawei.com> for linux-arm-kernel@lists.infradead.org; Tue, 18 Dec 2012 16:43:02 +0800 (CST) Received: from huawei.com ([172.24.2.119]) by szxga04-in.huawei.com (iPlanet Messaging Server 5.2 HotFix 2.14 (built Aug 8 2006)) with ESMTP id <0MF7003ZRXJQZ4@szxga04-in.huawei.com> for linux-arm-kernel@lists.infradead.org; Tue, 18 Dec 2012 16:43:02 +0800 (CST) Received: from [127.0.0.1] ([10.220.139.102]) by szxml06-in.huawei.com (iPlanet Messaging Server 5.2 HotFix 2.14 (built Aug 8 2006)) with ESMTPA id <0MF700N7UXJD2D@szxml06-in.huawei.com> for linux-arm-kernel@lists.infradead.org; Tue, 18 Dec 2012 16:43:02 +0800 (CST) Date: Tue, 18 Dec 2012 09:42:49 +0100 From: Claudio Fontana Subject: [PATCH RESEND 4] ARM: plat-versatile: move secondary CPU startup into cpuinit In-reply-to: <50B47C31.2040709@huawei.com> To: Russell King Message-id: <50D02C89.9030307@huawei.com> MIME-version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:17.0) Gecko/17.0 Thunderbird/17.0 References: <50B47C31.2040709@huawei.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20121218_034309_814211_3614FD4F X-CRM114-Status: UNSURE ( 4.56 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -4.9 (----) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-4.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [119.145.14.67 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -0.7 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Christoffer Dall , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org 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 Using __CPUINIT instead of __INIT puts the secondary CPU startup code into the "right" section: it will not be freed in hotplug configurations, allowing hot-add of cpus, while still getting freed in non-hotplug configs. Tested successfully on Fast-Models and on Arndale for VCPU hotplug. Signed-off-by: Claudio Fontana Tested-by: Claudio Fontana diff --git a/arch/arm/plat-versatile/headsmp.S b/arch/arm/plat-versatile/headsmp.S index dd703ef..19fe180 100644 --- a/arch/arm/plat-versatile/headsmp.S +++ b/arch/arm/plat-versatile/headsmp.S @@ -11,7 +11,7 @@ #include #include - __INIT + __CPUINIT /* * Realview/Versatile Express specific entry point for secondary CPUs.