Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
In order for the firmware built into the system to optimize itself for running in Long Mode, AMD recommends that the OS notify the BIOS about the intended target environment that the OS will be running in: 32-bit mode, 64-bit mode, or a mixture of both modes. This can be done by calling the BIOS interrupt 15h from Real Mode with AX set to 0xEC00, and BL set to 1 for 32-bit Protected Mode, 2 for 64-bit Long Mode, or 3 if both modes will be used.
But the BIOS is usually not called from protected mode or long mode. What exactly does this function do?
BTW, if I return back to real mode to call the BIOS, should I use this function or not?
You know your OS is advanced when you stop using the Intel programming guide as a reference.
This function should be called once when the CPU is still in Real Mode before switching to 32-bit mode.
If your OS does not use 64-bit mode, you should pass a 1 to this function.
Project: OZone
Source: GitHub
Current Task: LIB/OBJ file support
"The more they overthink the plumbing, the easier it is to stop up the drain." - Montgomery Scott