From patchwork Fri Aug 19 19:38:16 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mike Turquette X-Patchwork-Id: 3580 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 E93C823F26 for ; Fri, 19 Aug 2011 19:39:58 +0000 (UTC) Received: from mail-gy0-f180.google.com (mail-gy0-f180.google.com [209.85.160.180]) by fiordland.canonical.com (Postfix) with ESMTP id B161DA1800B for ; Fri, 19 Aug 2011 19:39:58 +0000 (UTC) Received: by gyc15 with SMTP id 15so3520029gyc.11 for ; Fri, 19 Aug 2011 12:39:58 -0700 (PDT) Received: by 10.150.68.26 with SMTP id q26mr122603yba.276.1313782798154; Fri, 19 Aug 2011 12:39:58 -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.150.157.17 with SMTP id f17cs113590ybe; Fri, 19 Aug 2011 12:39:57 -0700 (PDT) Received: by 10.91.66.35 with SMTP id t35mr110519agk.207.1313782797506; Fri, 19 Aug 2011 12:39:57 -0700 (PDT) Received: from na3sys009aog112.obsmtp.com ([74.125.149.207]) by mx.google.com with SMTP id r2si7916849pbp.108.2011.08.19.12.39.56 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 19 Aug 2011 12:39:57 -0700 (PDT) Received-SPF: pass (google.com: domain of mturquette@ti.com designates 74.125.149.207 as permitted sender) client-ip=74.125.149.207; Authentication-Results: mx.google.com; spf=pass (google.com: domain of mturquette@ti.com designates 74.125.149.207 as permitted sender) smtp.mail=mturquette@ti.com Received: from mail-yi0-f46.google.com ([209.85.218.46]) (using TLSv1) by na3sys009aob112.postini.com ([74.125.148.12]) with SMTP ID DSNKTk68DN/PeXOLTMc49YjsRJO6lx1CGUGy@postini.com; Fri, 19 Aug 2011 12:39:57 PDT Received: by yie30 with SMTP id 30so2893722yie.5 for ; Fri, 19 Aug 2011 12:39:55 -0700 (PDT) Received: by 10.236.177.97 with SMTP id c61mr770407yhm.87.1313782795889; Fri, 19 Aug 2011 12:39:55 -0700 (PDT) Received: from localhost.localdomain (dragon.ti.com [192.94.94.33]) by mx.google.com with ESMTPS id e21sm1179802yhn.35.2011.08.19.12.39.54 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 19 Aug 2011 12:39:55 -0700 (PDT) From: Mike Turquette To: linaro-dev@lists.linaro.org, patches@linaro.org Cc: Mike Turquette Subject: [PATCH 3/6] cpu: update cpu_hotpluggable_mask in register_cpu Date: Fri, 19 Aug 2011 12:38:16 -0700 Message-Id: <1313782699-29411-4-git-send-email-mturquette@ti.com> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1313782699-29411-1-git-send-email-mturquette@ti.com> References: <1313782699-29411-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)