aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/subr_pcpu.c
diff options
context:
space:
mode:
authorJohn Baldwin <jhb@FreeBSD.org>2001-10-24 22:15:38 +0000
committerJohn Baldwin <jhb@FreeBSD.org>2001-10-24 22:15:38 +0000
commit882bcf5879dfb26b6c35784e9020676122b37a33 (patch)
tree7c0f033b626d825696123f875ee72308bcded23a /sys/kern/subr_pcpu.c
parent02185af5a923aaf16e1109a61a1d46e6f166ff69 (diff)
downloadsrc-882bcf5879dfb26b6c35784e9020676122b37a33.tar.gz
src-882bcf5879dfb26b6c35784e9020676122b37a33.zip
Document the requirements and nature of the logical CPU IDs. It isn't
very strict and leaves much up to the platform so that it can define a convenient mapping. Requested by: mjacob
Notes
Notes: svn path=/head/; revision=85444
Diffstat (limited to 'sys/kern/subr_pcpu.c')
-rw-r--r--sys/kern/subr_pcpu.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/sys/kern/subr_pcpu.c b/sys/kern/subr_pcpu.c
index 47ac12e12edf..10a0d988ea42 100644
--- a/sys/kern/subr_pcpu.c
+++ b/sys/kern/subr_pcpu.c
@@ -32,6 +32,16 @@
/*
* This module provides MI support for per-cpu data.
+ *
+ * Each architecture determines the mapping of logical CPU IDs to physical
+ * CPUs. The requirements of this mapping are as follows:
+ * - Logical CPU IDs must reside in the range 0 ... MAXCPU - 1.
+ * - The mapping is not required to be dense. That is, there may be
+ * gaps in the mappings.
+ * - The platform sets the value of MAXCPU in <machine/param.h>.
+ * - It is suggested, but not required, that in the non-SMP case, the
+ * platform define MAXCPU to be 1 and define the logical ID of the
+ * sole CPU as 0.
*/
#include <sys/param.h>