[coyotos-dev] SMP Patch 1
Valerio Bellizzomi
devbox at selnet.org
Wed Oct 24 20:08:46 EDT 2007
On 24/10/2007, at 13.04, Jeroen Visser wrote:
>On 10/24/07, Jonathan S. Shapiro <shap at eros-os.com> wrote:
>> I have a nasty feeling that we just did a bunch of parallel effort
>> again. The stuff I just committed is probably not right, and is
>> certainly incomplete, but can you look it over?
>
>It is fantastic. I learned a lot from your rewrite already. You commit
>also shows proper names for variables and functions, as well as proper
>layering (arch vs machine independent).
>
>How about I get you the transmap patch against the latest repository?
>After that I can integrate the good parts of my latest SMP work. Among
>other things it addresses:
>
>low map:
>
>The AP bootstrap code page has been augmented with a boot map page (2
>physical pages total for AP bootstrap). The boot map contains a copy
>of the kernel map, but with a low alias. The kernel map never contains
>a low mapping after arch_init.
>
>on-demand AP boot pages:
>
>The AP boot pages can be mapped and unmapped on demand. Combined with
>the above we should be able to safely start APs (and perhaps reboot
>them) while running. If that is not required we can use this code to
>free up the AP bootstrap physical pages.
This is a fantastic thing if it is possible to reboot APs while running.
>
>MY_CPU(booted) field:
>
>Set to 1 when the apboot has been run and interrupts have been
>enabled. The CPU is ready to dispatch its first process. In this mode
>the CPU sits in a "hlt" loop until MY_CPU(active) becomes 1. To
>actually start the CPU, set its active field to 1 and send it an IPI
>to break out of the hlt loop. CPU 0 waits for this field to transition
>from 0 -> 1 to detect AP spinup.
What is the exact meaning of IPI ?
>
>SMP command line options:
>
>Options 'smp' and 'nosmp' controlling a variable named smp_enabled
>which defaults to false for now.
>
>AP bootstrap code cleanup:
>
>Remove some unnecessary complexity. Use the new boot map page that was
>added.
>
>-JCV
More information about the coyotos-dev
mailing list