From patchwork Wed Aug 10 01:33:27 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mike Turquette X-Patchwork-Id: 3336 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 9CA6823F5E for ; Wed, 10 Aug 2011 01:34:56 +0000 (UTC) Received: from mail-qw0-f52.google.com (mail-qw0-f52.google.com [209.85.216.52]) by fiordland.canonical.com (Postfix) with ESMTP id 646C8A186B1 for ; Wed, 10 Aug 2011 01:34:56 +0000 (UTC) Received: by mail-qw0-f52.google.com with SMTP id 8so471339qwb.11 for ; Tue, 09 Aug 2011 18:34:56 -0700 (PDT) Received: by 10.229.159.194 with SMTP id k2mr2544153qcx.83.1312940095571; Tue, 09 Aug 2011 18:34:55 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.229.190.71 with SMTP id dh7cs64208qcb; Tue, 9 Aug 2011 18:34:55 -0700 (PDT) Received: from mr.google.com ([10.150.150.42]) by 10.150.150.42 with SMTP id x42mr4266267ybd.93.1312940095332 (num_hops = 1); Tue, 09 Aug 2011 18:34:55 -0700 (PDT) Received: by 10.150.150.42 with SMTP id x42mr3003096ybd.93.1312940094948; Tue, 09 Aug 2011 18:34:54 -0700 (PDT) Received: from na3sys009aog113.obsmtp.com ([74.125.149.209]) by mx.google.com with SMTP id w20si990564wff.104.2011.08.09.18.34.54 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 09 Aug 2011 18:34:54 -0700 (PDT) Received-SPF: pass (google.com: domain of mturquette@ti.com designates 74.125.149.209 as permitted sender) client-ip=74.125.149.209; Authentication-Results: mx.google.com; spf=pass (google.com: domain of mturquette@ti.com designates 74.125.149.209 as permitted sender) smtp.mail=mturquette@ti.com Received: from mail-yx0-f171.google.com ([209.85.213.171]) (using TLSv1) by na3sys009aob113.postini.com ([74.125.148.12]) with SMTP ID DSNKTkHgPdZ/ZcPG+S4rs2X6ud1Jpp+2tVdi@postini.com; Tue, 09 Aug 2011 18:34:54 PDT Received: by yxk38 with SMTP id 38so519545yxk.2 for ; Tue, 09 Aug 2011 18:34:53 -0700 (PDT) Received: by 10.236.191.101 with SMTP id f65mr5164212yhn.9.1312940093250; Tue, 09 Aug 2011 18:34:53 -0700 (PDT) Received: from localhost.localdomain (dragon.ti.com [192.94.94.33]) by mx.google.com with ESMTPS id c63sm567838yhe.46.2011.08.09.18.34.51 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 09 Aug 2011 18:34:52 -0700 (PDT) From: Mike Turquette To: linux-kernel@vger.kernel.org Cc: linux-pm@lists.linux-foundation.org, linaro-dev@lists.linaro.org, patches@linaro.org, Mike Turquette Subject: [PATCH 2/2] cpu: update cpu_hotpluggable_mask in register_cpu Date: Tue, 9 Aug 2011 18:33:27 -0700 Message-Id: <1312940007-26069-3-git-send-email-mturquette@ti.com> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1312940007-26069-1-git-send-email-mturquette@ti.com> References: <1312940007-26069-1-git-send-email-mturquette@ti.com> Update the cpu_hotpluggable_mask for each registered CPU which supports hotplug. This makes it trivial for kernel code to know which CPUs support hotplug operations. Signed-off-by: Mike Turquette --- drivers/base/cpu.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/drivers/base/cpu.c b/drivers/base/cpu.c index 251acea..91ddcf8 100644 --- a/drivers/base/cpu.c +++ b/drivers/base/cpu.c @@ -224,8 +224,10 @@ int __cpuinit register_cpu(struct cpu *cpu, int num) error = sysdev_register(&cpu->sysdev); - if (!error && cpu->hotpluggable) + if (!error && cpu->hotpluggable) { register_cpu_control(cpu); + set_cpu_hotpluggable(num, true); + } if (!error) per_cpu(cpu_sys_devices, num) = &cpu->sysdev; if (!error)