login
Header Space

 
 

[PATCH] - Increase MAX_APICS for large configs

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: <mingo@...>, <tglx@...>
Cc: <linux-mm@...>, <linux-kernel@...>
Date: Wednesday, April 16, 2008 - 12:39 pm

Increase the maximum number of apics when running very large
configurations. This patch has no affect on most systems.

Signed-off-by: Jack Steiner <steiner@sgi.com>

---

I think this area of the code will be substantially changed when
the full x2apic patch is available. In the meantime, this seems
like an acceptible alternative. The patch has no effect on any 32-bit
kernel. It adds ~4k to the size of 64-bit kernels but only if
NR_CPUS > 255.


 include/asm-x86/mpspec_def.h |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

Index: linux/include/asm-x86/mpspec_def.h
===================================================================
--- linux.orig/include/asm-x86/mpspec_def.h	2008-03-29 06:45:28.000000000 -0500
+++ linux/include/asm-x86/mpspec_def.h	2008-03-31 14:17:01.000000000 -0500
@@ -17,10 +17,11 @@
 # define MAX_MPC_ENTRY 1024
 # define MAX_APICS      256
 #else
-/*
- * A maximum of 255 APICs with the current APIC ID architecture.
- */
-# define MAX_APICS 255
+# if NR_CPUS <= 255
+#  define MAX_APICS     255
+# else
+#  define MAX_APICS   32768
+# endif
 #endif
 
 struct intel_mp_floating {
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] - Increase MAX_APICS for large configs, Jack Steiner, (Wed Apr 16, 12:39 pm)
Re: [PATCH] - Increase MAX_APICS for large configs, Ingo Molnar, (Thu Apr 17, 7:07 am)
Re: [PATCH] - Increase MAX_APICS for large configs, Jack Steiner, (Fri Apr 18, 5:14 pm)
Re: [PATCH] - Increase MAX_APICS for large configs, Yinghai Lu, (Fri Apr 18, 6:01 pm)
Re: [PATCH] - Increase MAX_APICS for large configs, Jack Steiner, (Fri Apr 18, 8:01 pm)
Re: [PATCH] - Increase MAX_APICS for large configs, Yinghai Lu, (Thu Apr 17, 2:02 pm)
Re: [PATCH] - Increase MAX_APICS for large configs, Ingo Molnar, (Wed Apr 16, 2:45 pm)
Re: [PATCH] - Increase MAX_APICS for large configs, Jack Steiner, (Wed Apr 16, 3:22 pm)
speck-geostationary