From 11a36156f1af6eb64fa218458c06082ae496036d Mon Sep 17 00:00:00 2001 From: Christoph Lameter Date: Wed, 26 Mar 2008 18:41:38 -0700 Subject: [PATCH] slub: Remove per cpu info from per cpu statistics for !SMP Do not display the per cpu counts if this is not a SMP system. Signed-off-by: Christoph Lameter --- mm/slub.c | 2 ++ 1 file changed, 2 insertions(+) Index: linux-2.6/mm/slub.c =================================================================== --- linux-2.6.orig/mm/slub.c 2008-04-02 22:24:48.686522060 -0700 +++ linux-2.6/mm/slub.c 2008-04-02 22:25:25.986522643 -0700 @@ -4270,10 +4270,12 @@ static int show_stat(struct kmem_cache * len = sprintf(buf, "%lu", sum); +#ifdef CONFIG_SMP for_each_online_cpu(cpu) { if (data[cpu] && len < PAGE_SIZE - 20) len += sprintf(buf + len, " C%d=%u", cpu, data[cpu]); } +#endif kfree(data); return len + sprintf(buf + len, "\n"); }