Skip to content

Typo: "process ID" should be "processor ID" in Chapter 1.1 #274

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
msk2000 opened this issue Apr 22, 2025 · 0 comments · May be fixed by #275
Open

Typo: "process ID" should be "processor ID" in Chapter 1.1 #274

msk2000 opened this issue Apr 22, 2025 · 0 comments · May be fixed by #275

Comments

@msk2000
Copy link

msk2000 commented Apr 22, 2025

docs/lesson01/rpi-os.md reads:


.globl _start
_start:
    mrs    x0, mpidr_el1        
    and    x0, x0,#0xFF        // Check processor id
    cbz    x0, master        // Hang for all non-primary CPU
    b    proc_hang

The first thing this function does is check the processor ID. The Raspberry Pi 3 has four core processors, and after the device is powered on, each core begins to execute the same code. However, we don't want to work with four cores; we want to work only with the first one and put all of the other cores in an endless loop. This is exactly what the _start function is responsible for. **It gets the processor ID** from the [mpidr_el1](http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi0500g/BABHBJCI.html) system register. **If the current process ID is 0**, then execution is transferred to the master function:

The correct term should be "processor ID" because mpidr_el1 identifies the processor core (not a software process). At this point in the boot process, there's no OS and hence no concept of process IDs.

I’d be happy to submit a pull request with a fix!

@msk2000 msk2000 linked a pull request Apr 22, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant