From patchwork Wed Apr 10 14:22:08 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 2421781 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) by patchwork2.kernel.org (Postfix) with ESMTP id 90346DF2E5 for ; Wed, 10 Apr 2013 14:23:56 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UPvvm-00007u-Qg; Wed, 10 Apr 2013 14:23:22 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UPvvW-0006Pv-NB; Wed, 10 Apr 2013 14:23:06 +0000 Received: from mail-wg0-f45.google.com ([74.125.82.45]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UPvv5-0006KT-7j for linux-arm-kernel@lists.infradead.org; Wed, 10 Apr 2013 14:22:41 +0000 Received: by mail-wg0-f45.google.com with SMTP id l18so546783wgh.24 for ; Wed, 10 Apr 2013 07:22:37 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=sOZnfayO/LuSWeMMOiwRGLES0JNKfQvUJq/LsL7jyjI=; b=WBJm0mLdI8FntGB+aEUEGd+BqROjZ+Ftn8Zx5xB/9BlMiC3hnKRapKlFapUnmsH9jy XpQUkkH/A+oLCM8RHv/kWP9z6qZv53GpKvPDh71J+muemA2rVPRS/RplD+8a9Nv/v5+t H6y0KM9uudJaz8G1ebbFswWwNrvhfsHJYEG8l56eK62vJQhlAtdoLWF1/9nrCD7JI16o 8NYf/HO2QwFvdNW64bOkoZ7Ulref70w58PU9zFcLOP+lRVEAtpXoORWApMkgTqUDQy8X hzjA5QRCTzFKh2LmulBB/fYxDcZFH3I0Lle5nxQVehrUWd1KdS7bwcy2ZJMHNNvyEey7 3ofQ== X-Received: by 10.180.76.84 with SMTP id i20mr3900338wiw.9.1365603757406; Wed, 10 Apr 2013 07:22:37 -0700 (PDT) Received: from mai.home (AToulouse-654-1-413-119.w82-125.abo.wanadoo.fr. [82.125.160.119]) by mx.google.com with ESMTPS id dp5sm32126938wib.1.2013.04.10.07.22.34 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 10 Apr 2013 07:22:36 -0700 (PDT) From: Daniel Lezcano To: rjw@sisk.pl Subject: [PATCH 03/18] ARM: ux500: cpuidle: replace for_each_online_cpu by for_each_possible_cpu Date: Wed, 10 Apr 2013 16:22:08 +0200 Message-Id: <1365603743-5618-4-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1365603743-5618-1-git-send-email-daniel.lezcano@linaro.org> References: <1365603743-5618-1-git-send-email-daniel.lezcano@linaro.org> X-Gm-Message-State: ALoCoQm7CHPCcnN2yC50KgzftX5HSAmv1mRqZga2DRPZTOvLUw0xV06reEoidYjw335DpfedGnwb X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130410_102239_439456_E5FFE98F X-CRM114-Status: GOOD ( 13.17 ) X-Spam-Score: -0.9 (/) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-0.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [74.125.82.45 listed in list.dnswl.org] 1.7 KHOP_BIG_TO_CC Sent to 10+ recipients instaed of Bcc or a list -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: andrew@lunn.ch, khilman@deeprootsystems.com, linus.walleij@linaro.org, nsekhar@ti.com, josephl@nvidia.com, kgene.kim@samsung.com, patches@linaro.org, magnus.damm@gmail.com, tony@atomide.com, plagnioj@jcrosoft.com, linaro-kernel@lists.linaro.org, jason@lakedaemon.net, swarren@wwwdotorg.org, nicolas.ferre@atmel.com, rob.herring@calxeda.com, horms@verge.net.au, linux@maxim.org.za, linux-arm-kernel@lists.infradead.org, deepthi@linux.vnet.ibm.com, jkosina@suse.cz, linux-pm@vger.kernel.org, lethal@linux-sh.org, santosh.shilimkar@ti.com, kernel@pengutronix.de 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 All the drivers are using, in their initialization function, the for_each_possible_cpu macro. Using for_each_online_cpu means the driver must handle the initialization of the cpuidle device when a cpu is up which is not the case here. Change the macro to for_each_possible_cpu as that fix the hotplug initialization and make the initialization routine consistent with the rest of the code in the different drivers. Signed-off-by: Daniel Lezcano --- arch/arm/mach-ux500/cpuidle.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-ux500/cpuidle.c b/arch/arm/mach-ux500/cpuidle.c index c29c1bf..5657d4a 100644 --- a/arch/arm/mach-ux500/cpuidle.c +++ b/arch/arm/mach-ux500/cpuidle.c @@ -125,7 +125,7 @@ int __init ux500_idle_init(void) return ret; } - for_each_online_cpu(cpu) { + for_each_possible(cpu) { device = &per_cpu(ux500_cpuidle_device, cpu); device->cpu = cpu; ret = cpuidle_register_device(device); @@ -139,7 +139,7 @@ out: return ret; out_unregister: - for_each_online_cpu(cpu) { + for_each_possible_cpu(cpu) { device = &per_cpu(ux500_cpuidle_device, cpu); cpuidle_unregister_device(device); }