linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH] percpu data: only iterate over possible CPUs
@ 2006-02-09  8:32 Chuck Ebbert
  2006-02-09  8:55 ` Paul Jackson
  2006-02-09  9:06 ` Andrew Morton
  0 siblings, 2 replies; 58+ messages in thread
From: Chuck Ebbert @ 2006-02-09  8:32 UTC (permalink / raw)
  To: Andrew Morton
  Cc: Paul Jackson, heiko.carstens, wli, ak, mingo, torvalds,
	linux-kernel, riel, Eric Dumazet

In-Reply-To: <20060208204502.12513ae5.akpm@osdl.org>

On Wed, 8 Feb 2006 at 20:45:02 -0800, Andrew Morton wrote:

> > Its even documented in line 332 of include/linux/cpumask.h
> > 
> >   *  #ifdef CONFIG_HOTPLUG_CPU
> >   *     cpu_possible_map - all NR_CPUS bits set
> 
> That seems a quite bad idea.  If we know which CPUs are possible we should
> populate cpu_possible_map correctly, whether or not CONFIG_HOTPLUG_CPU is
> set.

I don't think that's, um, "possible."  Even if you could discover how many
empty sockets there were in a system, someone might be able to hotplug
a board with more of them on it.  And there's no way to tell how many CPUs
to reserve for each socket anyway, e.g. AMD has already announced quad-core
processors.

But what really surprised me is that for_each_cpu() actually walks
cpu_possible_map and not cpu_present_map as I had assumed.  This violates
the Principle Of Least Surprise.  Maybe renaming for_each_cpu to
for_each_possible_cpu might be a good idea?

-- 
Chuck
"Equations are the Devil's sentences."  --Stephen Colbert


^ permalink raw reply	[flat|nested] 58+ messages in thread

end of thread, other threads:[~2006-02-11 18:05 UTC | newest]

Thread overview: 58+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <200602051959.k15JxoHK001630@hera.kernel.org>
2006-02-07 15:15 ` [PATCH] percpu data: only iterate over possible CPUs Heiko Carstens
2006-02-07 15:31   ` Jens Axboe
2006-02-07 16:25   ` Eric Dumazet
2006-02-07 16:42     ` Linus Torvalds
2006-02-07 17:34       ` Andrew Morton
2006-02-07 17:48         ` Linus Torvalds
2006-02-07 18:30           ` Dipankar Sarma
2006-02-07 18:43             ` Linus Torvalds
2006-02-07 18:53               ` Dipankar Sarma
2006-02-07 19:11                 ` Linus Torvalds
2006-02-08  4:40                   ` Heiko Carstens
2006-02-08  8:55                   ` Ivan Kokshaysky
2006-02-08 22:31 ` Rik van Riel
2006-02-09  1:20   ` Rik van Riel
2006-02-09  3:05   ` Andrew Morton
2006-02-09  3:08     ` Andrew Morton
2006-02-09  4:36       ` Eric Dumazet
2006-02-09  4:45         ` Andrew Morton
2006-02-09  4:56           ` Paul Jackson
2006-02-09 16:08           ` Nathan Lynch
2006-02-09 16:13             ` Heiko Carstens
2006-02-09 16:38               ` Rik van Riel
2006-02-09 16:59               ` Nathan Lynch
2006-02-09 17:37               ` Andi Kleen
2006-02-10 10:05                 ` Heiko Carstens
2006-02-10 10:13                   ` Andi Kleen
2006-02-11 14:49                     ` Heiko Carstens
2006-02-11 18:04                       ` Andi Kleen
2006-02-09 17:03             ` Ashok Raj
2006-02-09 17:23               ` Nathan Lynch
2006-02-09 18:04               ` Andrew Morton
2006-02-09 18:52                 ` Ashok Raj
2006-02-09 20:37                   ` Andrew Morton
2006-02-09 21:03                     ` Ashok Raj
2006-02-10 10:02                 ` Andi Kleen
2006-02-10 10:42                   ` Andrew Morton
2006-02-10 11:09                     ` Eric Dumazet
2006-02-10 11:23                       ` Andrew Morton
2006-02-10 11:26                         ` Andrew Morton
2006-02-10 14:13                         ` Eric Dumazet
2006-02-11  0:10                           ` Nathan Lynch
2006-02-11  0:25                             ` Andrew Morton
2006-02-10 12:10                     ` Andi Kleen
2006-02-10 19:08                       ` Andrew Morton
2006-02-09  4:39   ` Eric Dumazet
2006-02-09  4:46     ` Nick Piggin
2006-02-09  8:32 Chuck Ebbert
2006-02-09  8:55 ` Paul Jackson
2006-02-09  9:06 ` Andrew Morton
2006-02-09  9:11   ` Andrew Morton
2006-02-09 10:08     ` Heiko Carstens
2006-02-09 10:13       ` Andrew Morton
2006-02-09 10:23         ` Heiko Carstens
2006-02-09 10:31           ` Andrew Morton
2006-02-09 11:47             ` Heiko Carstens
2006-02-09 12:46               ` Eric Dumazet
2006-02-09 13:12                 ` Heiko Carstens
2006-02-09 13:55                   ` Eric Dumazet

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).