From: Mike Travis <travis@sgi.com>
To: Ingo Molnar <mingo@redhat.com>
Cc: Rusty Russell <rusty@rustcorp.com.au>,
"H. Peter Anvin" <hpa@zytor.com>,
Stephen Rothwell <sfr@canb.auug.org.au>,
Thomas Gleixner <tglx@linutronix.de>,
Jack Steiner <steiner@sgi.com>,
linux-kernel@vger.kernel.org
Subject: [PATCH 03/16] x86: move and enhance debug printk for nr_cpu_ids etc.
Date: Mon, 15 Dec 2008 18:24:12 -0800 [thread overview]
Message-ID: <20081216022410.269898000@polaris-admin.engr.sgi.com> (raw)
In-Reply-To: <20081216022409.679598000@polaris-admin.engr.sgi.com>
[-- Attachment #1: 0003-x86-move-and-enhance-debug-printk-for-nr_cpu_ids-et.patch --]
[-- Type: text/plain, Size: 1906 bytes --]
Impact: cleanup, better debugging
This has proven useful in debugging, *before* we try to use
for_each_possible_cpu(). It also now shows nr_cpumask_bits.
Signed-off-by: Mike Travis <travis@sgi.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
---
arch/x86/kernel/setup_percpu.c | 17 +++++++++++------
1 files changed, 11 insertions(+), 6 deletions(-)
diff --git a/arch/x86/kernel/setup_percpu.c b/arch/x86/kernel/setup_percpu.c
index 1c20842..0b63b08 100644
--- a/arch/x86/kernel/setup_percpu.c
+++ b/arch/x86/kernel/setup_percpu.c
@@ -152,6 +152,11 @@ void __init setup_per_cpu_areas(void)
old_size = PERCPU_ENOUGH_ROOM;
align = max_t(unsigned long, PAGE_SIZE, align);
size = roundup(old_size, align);
+
+ printk(KERN_INFO
+ "NR_CPUS:%d nr_cpumask_bits:%d nr_cpu_ids:%d nr_node_ids:%d\n",
+ NR_CPUS, nr_cpumask_bits, nr_cpu_ids, nr_node_ids);
+
printk(KERN_INFO "PERCPU: Allocating %zd bytes of per cpu data\n",
size);
@@ -168,24 +173,24 @@ void __init setup_per_cpu_areas(void)
"cpu %d has no node %d or node-local memory\n",
cpu, node);
if (ptr)
- printk(KERN_DEBUG "per cpu data for cpu%d at %016lx\n",
+ printk(KERN_DEBUG
+ "per cpu data for cpu%d at %016lx\n",
cpu, __pa(ptr));
}
else {
ptr = __alloc_bootmem_node(NODE_DATA(node), size, align,
__pa(MAX_DMA_ADDRESS));
if (ptr)
- printk(KERN_DEBUG "per cpu data for cpu%d on node%d at %016lx\n",
- cpu, node, __pa(ptr));
+ printk(KERN_DEBUG
+ "per cpu data for cpu%d on node%d "
+ "at %016lx\n",
+ cpu, node, __pa(ptr));
}
#endif
per_cpu_offset(cpu) = ptr - __per_cpu_start;
memcpy(ptr, __per_cpu_start, __per_cpu_end - __per_cpu_start);
}
- printk(KERN_DEBUG "NR_CPUS: %d, nr_cpu_ids: %d, nr_node_ids %d\n",
- NR_CPUS, nr_cpu_ids, nr_node_ids);
-
/* Setup percpu data maps */
setup_per_cpu_maps();
--
1.6.0
--
next prev parent reply other threads:[~2008-12-16 2:27 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-16 2:24 [PATCH 00/16] cpumask: consolidate and apply x86 cpumask changes Mike Travis
2008-12-16 2:24 ` [PATCH 01/16] x86 smp: modify send_IPI_mask interface to accept cpumask_t pointers Mike Travis
2008-12-16 2:24 ` [PATCH 02/16] x86: enable MAXSMP Mike Travis
2008-12-16 2:24 ` Mike Travis [this message]
2008-12-16 2:24 ` [PATCH 04/16] x86: Add cpu_mask_to_apicid_and Mike Travis
2008-12-16 2:24 ` [PATCH 05/16] x86: update add-cpu_mask_to_apicid_and to use struct cpumask* Mike Travis
2008-12-16 2:24 ` [PATCH 06/16] x86: Update io_apic.c to use new cpumask API Mike Travis
2008-12-16 2:24 ` [PATCH 07/16] xen: convert to cpumask_var_t and new cpumask primitives Mike Travis
2008-12-16 2:24 ` [PATCH 08/16] x86: fixup_irqs() doesnt need an argument Mike Travis
2008-12-16 2:24 ` [PATCH 09/16] x86: cosmetic changes apic-related files Mike Travis
2008-12-16 2:24 ` [PATCH 10/16] x86: Set CONFIG_NR_CPUS even on UP Mike Travis
2008-12-16 2:24 ` [PATCH 11/16] x86: prepare for cpumask iterators to only go to nr_cpu_ids Mike Travis
2008-12-16 2:24 ` [PATCH 12/16] x86: Use cpumask accessors code for possible/present maps Mike Travis
2008-12-16 2:24 ` [PATCH 13/16] x86: Remove cpumask games in x86/kernel/cpu/intel_cacheinfo.c Mike Travis
2008-12-16 2:24 ` [PATCH 14/16] x86: use work_on_cpu in x86/kernel/cpu/mcheck/mce_amd_64.c Mike Travis
2008-12-16 2:24 ` [PATCH 15/16] x86: xen: use smp_call_function_many() Mike Travis
2008-12-16 2:24 ` [PATCH 16/16] x86: Introduce topology_core_cpumask()/topology_thread_cpumask() Mike Travis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20081216022410.269898000@polaris-admin.engr.sgi.com \
--to=travis@sgi.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rusty@rustcorp.com.au \
--cc=sfr@canb.auug.org.au \
--cc=steiner@sgi.com \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®