lkml.org 
[lkml]   [2001]   [Oct]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Wierd /proc/cpuinfo with 2.4.11-pre4
> This will also fail if, for some reason "clustered_apic_mode" is set and
> you have less than 8 CPUs. What you really want is to have "max(8:NR_CPUS)"
> in the loop (or make the loop actually work with > 8 CPUs, which is probably
> the correct solution in the long run).

Nope, the cpu_online map should catch this. NR_CPUS is always 32
in SMP mode.

in get_cpuinfo ....

if (!(cpu_online_map & (1<<n)))
continue;

I didn't notice that this would only work in SMP mode.

It's a horrible hack, but it's less horrible than corrupting memory randomly ;-)

M.

-
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:04    [W:0.072 / U:0.420 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site