Re: [patch 3/8] x86_64:Dont call enforce_max_cpus when hotplug is enabled

From: Ashok Raj
Date: Thu Aug 04 2005 - 11:33:05 EST


On Thu, Aug 04, 2005 at 12:41:10PM +0200, Andi Kleen wrote:
> On Mon, Aug 01, 2005 at 01:20:20PM -0700, Ashok Raj wrote:
> > No need to enforce_max_cpus when hotplug code is enabled. This
> > nukes out cpu_present_map and cpu_possible_map making it impossible to add
> > new cpus in the system.
>
> Hmm - i think there was some reason for this early zeroing,
> but I cannot remember it right now.
>
> It might be related to some checks later that check max possible cpus.
>
> So it would be still good to have some way to limit max possible cpus.
> Maybe with a new option?

The only useful thing with enfore_max() is that cpu_possible_map is trimmed
so some resource allocations that use for_each_cpu() for upfront allocation
wont allocate resources.

Currently i see max_cpus only limiting boot-time start, none trim cpu_possible
which is done in only x86_64. max_cpu is still honored, just that for initial
boot. I would think maybe remove enforce_max_cpus() altogether like other
archs instead of adding one more just for x86_64.

Maybe we should add only if there is a need, instead of adding and finding
no-one using it and finally removing it very soon.
>
> -Andi

--
Cheers,
Ashok Raj
- Open Source Technology Center
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/