lkml.org 
[lkml]   [2004]   [Jul]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] ppc64 SMT bugfix
This patch is fairly straightforward.  maxcpus should be per SMT thread 
and not per physical processor. SUSE picked this up back in May (was
discussed on ppc64 mailing list) and has had no trouble with it.


Signed-off-by: Joel Schopp <jschopp@austin.ibm.com>
diff -Nru a/arch/ppc64/kernel/smp.c b/arch/ppc64/kernel/smp.c
--- a/arch/ppc64/kernel/smp.c Tue Jul 27 13:44:45 2004
+++ b/arch/ppc64/kernel/smp.c Tue Jul 27 13:44:45 2004
@@ -422,7 +422,11 @@
}

maxcpus = ireg[num_addr_cell + num_size_cell];
- /* DRENG need to account for threads here too */
+
+ /* Double maxcpus for processors which have SMT capability */
+ if (cur_cpu_spec->cpu_features & CPU_FTR_SMT)
+ maxcpus *= 2;
+

if (maxcpus > NR_CPUS) {
printk(KERN_WARNING
\
 
 \ /
  Last update: 2005-03-22 14:04    [W:0.038 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site