diff options
author | Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> | 2005-10-30 17:59:38 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-10-30 20:37:12 -0500 |
commit | 30037f66ce63b6b7ca1fbfb06605b831f4a60df6 (patch) | |
tree | 48645e204613332df510b42f56655d06d9200a33 /arch/i386 | |
parent | f014a556e714dfb02502e3be6146a39ca625f33c (diff) |
[PATCH] x86: when L3 is present show its size in /proc/cpuinfo
The code that prints the cache size assumes that L3 always lives in chipset
and is shared across CPUs. Which is not really true.
I think all the cachesizes reported by cpuid are in the processor itself.
The attached patch changes the code to reflect that.
Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/i386')
-rw-r--r-- | arch/i386/kernel/cpu/intel_cacheinfo.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/arch/i386/kernel/cpu/intel_cacheinfo.c b/arch/i386/kernel/cpu/intel_cacheinfo.c index c802206274c2..7cc84a4a6df9 100644 --- a/arch/i386/kernel/cpu/intel_cacheinfo.c +++ b/arch/i386/kernel/cpu/intel_cacheinfo.c | |||
@@ -278,13 +278,7 @@ unsigned int __devinit init_intel_cacheinfo(struct cpuinfo_x86 *c) | |||
278 | if ( l3 ) | 278 | if ( l3 ) |
279 | printk(KERN_INFO "CPU: L3 cache: %dK\n", l3); | 279 | printk(KERN_INFO "CPU: L3 cache: %dK\n", l3); |
280 | 280 | ||
281 | /* | 281 | c->x86_cache_size = l3 ? l3 : (l2 ? l2 : (l1i+l1d)); |
282 | * This assumes the L3 cache is shared; it typically lives in | ||
283 | * the northbridge. The L1 caches are included by the L2 | ||
284 | * cache, and so should not be included for the purpose of | ||
285 | * SMP switching weights. | ||
286 | */ | ||
287 | c->x86_cache_size = l2 ? l2 : (l1i+l1d); | ||
288 | } | 282 | } |
289 | 283 | ||
290 | return l2; | 284 | return l2; |