Multiprocessing Data Structures
Each processor has a data structure that is used to keep track of data specific to that processor. This structure is of type struct mpinfo, which is typdefed to mpinfo_t. The global variable mpproc_info is declared as a pointer to a struct mpinfo. At boot time, the system allocates enough memory to hold one struct mpinfo for each processor. It then points mpproc_info to the beginning of this allocated memory. In this way, mpproc_info can be used as an array of struct mpinfo by using the processor index. For example, mpproc_info[0] is the mpinfo structure for the first processor in the system. The mpinfo structure is also sometimes called the per-processor data pointer (PPDP).
The mpinfo structure is a huge structure—over ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access