Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932663Ab2BNXAu (ORCPT ); Tue, 14 Feb 2012 18:00:50 -0500 Received: from mail-iy0-f174.google.com ([209.85.210.174]:53413 "EHLO mail-iy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932117Ab2BNXAo convert rfc822-to-8bit (ORCPT ); Tue, 14 Feb 2012 18:00:44 -0500 MIME-Version: 1.0 In-Reply-To: <4F3AD3B6.8070409@linux.vnet.ibm.com> References: <1328055439-9441-1-git-send-email-venki@google.com> <20120201140125.c656df41.akpm@linux-foundation.org> <87d39xj955.fsf@rustcorp.com.au> <4F3971A1.5010305@linux.vnet.ibm.com> <4F39763D.3070609@linux.vnet.ibm.com> <87wr7pbwbz.fsf@rustcorp.com.au> <4F3AD3B6.8070409@linux.vnet.ibm.com> Date: Tue, 14 Feb 2012 15:00:43 -0800 X-Google-Sender-Auth: RC2QC_OmvTYjQpsP5z4q0t6qB_M Message-ID: Subject: Re: [PATCH] Avoid mask based num_possible_cpus and num_online_cpus -v5 From: Tony Luck To: "Srivatsa S. Bhat" Cc: Rusty Russell , Andrew Morton , Venkatesh Pallipadi , KOSAKI Motohiro , KOSAKI Motohiro , Mike Travis , "Paul E. McKenney" , "Rafael J. Wysocki" , Paul Gortmaker , linux-kernel@vger.kernel.org, Fenghua Yu , linux-ia64@vger.kernel.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1541 Lines: 42 On Tue, Feb 14, 2012 at 1:35 PM, Srivatsa S. Bhat wrote: > Right. And we should also ensure that nobody messes directly with > cpu_possible_map as well. I have written up a patch for ia64 (see below). > Sorry, I haven't even compile tested it - I neither have the toolchain nor the > hardware. I hope it works! Thanks for doing this - compiles and seems to work. Tested-by: Tony Luck Can we get this added to the series - so it gets applied along with Venki's patch. > ?0 files changed, 0 insertions(+), 0 deletions(-) I think your patch generation script needs some attention - I see arch/ia64/kernel/setup.c | 2 +- arch/ia64/kernel/smp.c | 2 +- arch/ia64/kernel/smpboot.c | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-) > @@ -609,7 +609,7 @@ smp_prepare_cpus (unsigned int max_cpus) > ? ? ? ?/* > ? ? ? ? * We have the boot CPU online for sure. > ? ? ? ? */ > - ? ? ? cpu_set(0, cpu_online_map); > + ? ? ? set_cpu_online(0, true); > ? ? ? ?cpu_set(0, cpu_callin_map); > > ? ? ? ?local_cpu_data->loops_per_jiffy = loops_per_jiffy; Generic code has already marked cpu 0 online ... so this one could just be dropped (and the preceding comment too). Though it does no harm to set it again. -Tony -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/