dect
/
linux-2.6
Archived
13
0
Fork 0

[PATCH] swsusp: don't require bigsmp

Switching to automatic bigsmp causes a misleading error message, that more
then 8 cpus are detected, and user needs to select either X86_GENERICARCH
or X86_BIGSMP to handle.

Reason is we switched to bigsmp to avoid IP race when new cpu is comming
up.  [bigsmp is nothing but using physical flat mode that can work for 1 ..
 255 cpus] [default is X86_PC, that uses logical flat mode up to 8 CPUs
max] Current x86_64 code uses bigsmp as default when hotplug is enabled.

It would be preferable to make bigsmp as default, and work the dependencies
of other related code like SMP_SUSPEND, and some related to memory hotplug
code for i386.

Current logical flat mode doesnt use shortcuts that cause the race by using
the send_IPI_mask() instead of shortcuts when HOTPLUG_CPU is enabled.

In the meantime this patch is the path of lease resistance.

We will switch to bigsmp default sometime soon, when we get to work it again.

Signed-off-by: Ashok Raj <ashok.raj@intel.com>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Nigel Cunningham <nigel@suspend2.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
Ashok Raj 2006-04-10 22:53:07 -07:00 committed by Linus Torvalds
parent 3016b42153
commit 6cf272acd5
1 changed files with 8 additions and 7 deletions

View File

@ -38,12 +38,6 @@
int smp_found_config;
unsigned int __initdata maxcpus = NR_CPUS;
#ifdef CONFIG_HOTPLUG_CPU
#define CPU_HOTPLUG_ENABLED (1)
#else
#define CPU_HOTPLUG_ENABLED (0)
#endif
/*
* Various Linux-internal data structures created from the
* MP-table.
@ -204,7 +198,14 @@ static void __devinit MP_processor_info (struct mpc_config_processor *m)
cpu_set(num_processors, cpu_possible_map);
num_processors++;
if (CPU_HOTPLUG_ENABLED || (num_processors > 8)) {
/*
* Would be preferable to switch to bigsmp when CONFIG_HOTPLUG_CPU=y
* but we need to work other dependencies like SMP_SUSPEND etc
* before this can be done without some confusion.
* if (CPU_HOTPLUG_ENABLED || num_processors > 8)
* - Ashok Raj <ashok.raj@intel.com>
*/
if (num_processors > 8) {
switch (boot_cpu_data.x86_vendor) {
case X86_VENDOR_INTEL:
if (!APIC_XAPIC(ver)) {