mirror of
https://github.com/ipxe/ipxe
synced 2026-02-14 02:31:26 +03:00
Documented the fact that the prefix can prot_call(main) without
worrying about its stack being destroyed during the Etherboot run.
This commit is contained in:
@@ -328,6 +328,15 @@ rm_ds: .word 0
|
|||||||
* function explicitly overwrites values in ix86. Interrupt status
|
* function explicitly overwrites values in ix86. Interrupt status
|
||||||
* and GDT will also be preserved. Gate A20 will be enabled.
|
* and GDT will also be preserved. Gate A20 will be enabled.
|
||||||
*
|
*
|
||||||
|
* Note that prot_call() does not rely on the real-mode stack
|
||||||
|
* remaining intact in order to return, since everything relevant is
|
||||||
|
* copied to the protected-mode stack for the duration of the call.
|
||||||
|
* In particular, this means that a real-mode prefix can make a call
|
||||||
|
* to main() which will return correctly even if the prefix's stack
|
||||||
|
* gets vapourised during the Etherboot run. (The prefix cannot rely
|
||||||
|
* on anything else on the stack being preserved, so should move any
|
||||||
|
* critical data to registers before calling main()).
|
||||||
|
*
|
||||||
* Parameters:
|
* Parameters:
|
||||||
* function : virtual address of protected-mode function to call
|
* function : virtual address of protected-mode function to call
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user