lkml.org 
[lkml]   [2003]   [Feb]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH][2.5][14/14] smp_call_function_on_cpu - x86_64
On Fri, 14 Feb 2003, Andi Kleen wrote:

> On Fri, Feb 14, 2003 at 07:52:15AM -0500, Zwane Mwaikambo wrote:
> > One liner to fix num_cpus == 0 on SMP kernel w/ UP box
>
> Shouldn't num_cpus be 1 in that case ?

We mask out current cpu first like so;

mask &= ~(1UL << smp_processor_id());
num_cpus = hweight(mask);
if (num_cpus == )
return 0;

So really it's number of eligible IPI cpus

Zwane
--
function.linuxpower.ca
-
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/

\
 
 \ /
  Last update: 2005-03-22 13:33    [W:0.044 / U:0.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site