summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2001-10-24 22:15:38 +0000
committerjhb <jhb@FreeBSD.org>2001-10-24 22:15:38 +0000
commita99a514c87def1f63bc7f3d5677c6248f38c9118 (patch)
tree7c0f033b626d825696123f875ee72308bcded23a /sys
parentdb5d9e122b911b46d76df61b88dea905bdf31e10 (diff)
downloadFreeBSD-src-a99a514c87def1f63bc7f3d5677c6248f38c9118.zip
FreeBSD-src-a99a514c87def1f63bc7f3d5677c6248f38c9118.tar.gz
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
Diffstat (limited to 'sys')
-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 47ac12e..10a0d98 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>
OpenPOWER on IntegriCloud