Difference between revisions of "Unit PlatformARMv7"
Line 1,467: | Line 1,467: | ||
<br /> | <br /> | ||
<br />An IRQ or FIQ context switch uses the SRS (Store Return State) and RFE (Return From Exception) instructions to save and restore the cpsr value from the spsr value of either IRQ or FIQ mode. | <br />An IRQ or FIQ context switch uses the SRS (Store Return State) and RFE (Return From Exception) instructions to save and restore the cpsr value from the spsr value of either IRQ or FIQ mode. | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | |||
+ | '''ARMv7 IRQ functions''' | ||
+ | |||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7DispatchIRQ(CPUID:LongWord; Thread:TThreadHandle):TThreadHandle; inline;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | |||
+ | '''ARMv7 FIQ functions''' | ||
+ | |||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7DispatchFIQ(CPUID:LongWord; Thread:TThreadHandle):TThreadHandle; inline;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | |||
+ | '''ARMv7 SWI functions''' | ||
+ | |||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7DispatchSWI(CPUID:LongWord; Thread:TThreadHandle; Request:PSystemCallRequest):TThreadHandle; inline;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | |||
+ | '''ARMv7 interrupt functions''' | ||
+ | |||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7ResetHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7UndefinedInstructionHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Handle an undefined instruction exception</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | This routine is registered as the vector for undefined instruction exception in the vector table loaded during startup | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7SoftwareInterruptHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Handle a software interrupt (SWI) from a system call (SVC)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | This routine is registered as the vector for SWI requests in the vector table loaded during startup. When the processor executes an SVC it switches to SWI mode, stores the address of the next instruction in the SWI mode link register (lr_svc) and saves the current program status register into the SWI mode saved program status register (spsr_svc). | ||
+ | <br />The SWI handler first saves the SWI mode lr and spsr (which represent the location and state to return to) onto the SYS mode stack using the srsdb (Store Return State Decrement Before) instruction. | ||
+ | <br /> | ||
+ | <br />The SWI handler then switches to SYS mode and saves all the neccessary registers for the return to the interrupted thread before switching back to SWI mode in order to process the software interrupt. Because we arrive here from an interrupt the thread that was executing has no opportunity to save registers and will be unaware on return that it was interrupted. For this reason we must save all of the general purpose registers (r0 to r12) as well as the SYS mode link register (lr). We do not save the stack pointer (r13) because we use it to store the other registers and will return it to the correct value before we return from the SWI handler. The program counter (r15) does not need to be saved as it now points to this code. | ||
+ | <br /> | ||
+ | <br />The SystemCall function should pass the parameters of the call as follows: | ||
+ | <br /> | ||
+ | <br />R0 - System Call Number (eg SYSTEM_CALL_CONTEXT_SWITCH) | ||
+ | <br />R1 - Parameter 1 | ||
+ | <br />R2 - Parameter 2 | ||
+ | <br />R3 - Parameter 3 | ||
+ | <br /> | ||
+ | <br />To process the software interrupt | ||
+ | <br />?????? | ||
+ | <br /> | ||
+ | <br />To return from the software interrupt | ||
+ | <br />?????? | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7PrefetchAbortHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Handle a prefetch abort exception</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | This routine is registered as the vector for prefetch abort exception in the vector table loaded during startup | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7DataAbortHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Handle a data abort exception</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | This routine is registered as the vector for data abort exception in the vector table loaded during startup | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7ReservedHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7IRQHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Handle an interrupt request IRQ from an interrupt source</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | This routine is registered as the vector for IRQ requests in the vector table loaded during startup. | ||
+ | <br />At the end of each instruction the processor checks the IRQ line and if triggered it will lookup the vector in the vector table and jump to the routine listed. | ||
+ | <br /> | ||
+ | <br />When the processor receives an IRQ it switches to IRQ mode, stores the address of the next instruction in the IRQ mode link register (lr_irq) and saves the current program status register into the IRQ mode saved program status register (spsr_irq). | ||
+ | <br /> | ||
+ | <br />The IRQ handler first saves the IRQ mode lr and spsr (which represent the location and state to return to) onto the SYS mode stack using the srsdb (Store Return State Decrement Before) instruction. | ||
+ | <br /> | ||
+ | <br />The IRQ handler then switches to SYS mode and saves all the neccessary registers for the return to the interrupted thread before switching back to IRQ mode in order to process the interrupt request. Because we arrive here from an interrupt the thread that was executing has no opportunity to save registers and will be unaware on return that it was interrupted. For this reason we must save all of the general purpose registers (r0 to r12) as well as the SYS mode link register (lr). We do not save the stack pointer (r13) because we use it to store the other registers and will return it to the correct value before we return from the IRQ handler. The program counter (r15) does not need to be saved as it now points to this code. | ||
+ | <br /> | ||
+ | <br />To process the interrupt request the handler calls the DispatchIRQ function which will dispatch the interrupt to a registered handler for processing. The handler must clear the interrupt source before it returns or the interrupt will simply occur again immediately once reenabled. | ||
+ | <br /> | ||
+ | <br />To return from the interrupt request the handler uses the rfeia (Return From Exception Increment After) instruction which will load the pc and cpsr from the SYS mode stack. | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7FIQHandler; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Handle a fast interrupt request FIQ from an interrupt source</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | This routine is registered as the vector for FIQ requests in the vector table loaded during startup. | ||
+ | <br />At the end of each instruction the processor checks the FIQ line and if triggered it will lookup the vector in the vector table and jump to the routine listed. | ||
+ | <br /> | ||
+ | <br />When the processor receives an FIQ it switches to FIQ mode, stores the address of the next instruction in the FIQ mode link register (lr_fiq) and saves the current program status register into the FIQ mode saved program status register (spsr_fiq). | ||
+ | <br /> | ||
+ | <br />The FIQ handler first checks the spsr to determine if the task being interrupted is a normal thread or an exception or interrupt handler. | ||
+ | <br /> | ||
+ | <br />The FIQ handler then saves the FIQ mode lr and spsr (which represent the location and state to return to) onto eihter the SYS mode or SVC mode stack using the srsdb (Store Return State Decrement Before) instruction depending on the value of spsr. | ||
+ | <br /> | ||
+ | <br />The FIQ handler switches to SYS or SVC mode and saves all the neccessary registers for the return to the interrupted task before switching back to FIQ mode in order to process the interrupt request. Because we arrive here from an interrupt the task that was executing has no opportunity to save registers and will be unaware on return that it was interrupted. For this reason we must save all of the general purpose registers (r0 to r12) as well as the SYS mode link register (lr). We do not save the stack pointer (r13) because we use it to store the other registers and will return it to the correct value before we return from the FIQ handler. The program counter (r15) does not need to be saved as it now points to this code. | ||
+ | <br /> | ||
+ | <br />To process the fast interrupt request the handler calls the DispatchFIQ function which will dispatch the interrupt to a registered handler for processing. The handler must clear the interrupt source before it returns or the fast interrupt will simply occur again immediately once reenabled. | ||
+ | <br /> | ||
+ | <br />To return from the fast interrupt request the handler uses the rfeia (Return From Exception Increment After) instruction which will load the pc and cpsr from the stack of the current mode (SYS or SVC). | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | |||
+ | '''ARMv7 helper functions''' | ||
+ | |||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetFPEXC:LongWord; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetFPSCR:LongWord; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7StartMMU; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetTimerState(Timer:LongWord):LongWord; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMv7SetTimerState(Timer,State:LongWord); assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetTimerCount(Timer:LongWord):Int64; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetTimerValue(Timer:LongWord):LongWord; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMV7SetTimerValue(Timer,Value:LongWord); assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetTimerCompare(Timer:LongWord):Int64; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">procedure ARMV7SetTimerCompare(Timer,High,Low:LongWord);</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetTimerFrequency:LongWord; assembler; nostackframe;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' To be documented</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | None documented | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetPageTableCoarse(Address:PtrUInt):LongWord;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Get the descriptor for a Coarse Page Table entry (1MB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | See page ??? | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7SetPageTableCoarse(Address,CoarseAddress:PtrUInt; Flags:Word):Boolean;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Set the descriptor for a Coarse Page Table entry (1MB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | See page ??? | ||
+ | Caller must call ARMv7InvalidateTLB after changes if MMU is enabled | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetPageTableLarge(Address:PtrUInt):LongWord;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Get the descriptor for a Large Page Table entry (64KB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | See page ??? | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7SetPageTableLarge(Address,PhysicalAddress:PtrUInt; Flags:Word):Boolean;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Set the descriptor for a Large Page Table entry (64KB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | Large Page Table descriptors must begin on a 16 longword (64 byte) boundary and be repeated for 16 consecutive longwords | ||
+ | See page ??? | ||
+ | <br />Caller must call ARMv7InvalidateTLB after changes if MMU is enabled | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetPageTableSmall(Address:PtrUInt):LongWord;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Get the descriptor for a Small Page Table entry (4KB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | See page ??? | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7SetPageTableSmall(Address,PhysicalAddress:PtrUInt; Flags:Word):Boolean;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Set the descriptor for a Small Page Table entry (4KB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | See page ??? | ||
+ | Caller must call ARMv7InvalidateTLB after changes if MMU is enabled | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7GetPageTableSection(Address:PtrUInt):LongWord;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Get the descriptor for a Page Table Section (1MB) or Supersection (16MB)/div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | See page ??? | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7SetPageTableSection(Address,PhysicalAddress:PtrUInt; Flags:LongWord):Boolean;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Set the descriptor for a Page Table Section (1MB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | See page ??? | ||
+ | Caller must call ARMv7InvalidateTLB after changes if MMU is enabled | ||
+ | |- | ||
+ | |} | ||
+ | </div></div> | ||
+ | <br /> | ||
+ | <div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;"> | ||
+ | <pre style="border: 0; padding-bottom:0px;">function ARMv7SetPageTableSupersection(Address,PhysicalAddress:PtrUInt; Flags:LongWord):Boolean;</pre> | ||
+ | <div style="font-size: 14px; padding-left: 12px;">'''Description:''' Set the descriptor for a Page Table Supersection (16MB)</div> | ||
+ | <div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;"> | ||
+ | {| class="wikitable" style="font-size: 14px; background: white;" | ||
+ | |- | ||
+ | ! '''Note''' | ||
+ | | Supersection Page Table descriptors must begin on a 16 longword (64 byte) boundary and be repeated for 16 consecutive longwords | ||
+ | See page ??? | ||
+ | <br />Caller must call ARMv7InvalidateTLB after changes if MMU is enabled | ||
|- | |- | ||
|} | |} |
Revision as of 05:49, 21 October 2016
Return to Unit Reference
Description
The ARMv7 does not support the SWP/SWPB instructions for syncronisation (Lock/Mutex/Semaphore etc) unless enabled.
On ARMv7 Unaligned memory access is always enabled.
On ARMv7 the Extended Page Table format is always enabled.
For usage of barriers (DMB/DSB/ISB) after cache maintenance operations see: ARM.Reference_Manual_1.pdf - Appendix G Barrier Litmus Tests
Constants
To be documented
Type definitions
To be documented
Public variables
To be documented
Function declarations
Initialization functions
procedure ARMv7Init;
Note | None documented |
---|
ARMv7 platform functions
procedure ARMv7CPUInit; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7FPUInit; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7MMUInit;
Note | None documented |
---|
procedure ARMv7CacheInit; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7TimerInit(Frequency:LongWord); assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7PageTableInit;
Note | See page ??? |
---|
procedure ARMv7SystemCall(Number:LongWord; Param1,Param2,Param3:LongWord); assembler; nostackframe;
Note | None documented |
---|
function ARMv7CPUGetMode:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7CPUGetState:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7CPUGetCurrent:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7CPUGetMainID:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7CPUGetMultiprocessorID:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7CPUGetModel:LongWord;
Note | None documented |
---|
function ARMv7CPUGetRevision:LongWord;
Note | None documented |
---|
function ARMv7CPUGetDescription:String;
Note | None documented |
---|
function ARMv7FPUGetState:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L1CacheGetType:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L1DataCacheGetSize:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L1DataCacheGetLineSize:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L1InstructionCacheGetSize:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L1InstructionCacheGetLineSize:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L2CacheGetType:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L2CacheGetSize:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7L2CacheGetLineSize:LongWord; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7Halt; assembler; nostackframe; public name'_haltproc';
Note | See Standby mode on page A8-810 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7Pause; assembler; nostackframe;
Note | See Standby mode on page A8-810 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7SendEvent; assembler; nostackframe;
Note | See Page A8-316 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7WaitForEvent; assembler; nostackframe;
Note | See Page A8-808 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7WaitForInterrupt; assembler; nostackframe;
Note | See Standby mode on page A8-810 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7DataMemoryBarrier; assembler; nostackframe;
Note | See page A8-90 of the ARMv7 Architecture Reference Manual
Note that this is also available in the FPC RTL as ReadBarrier/WriteBarrier See: \source\rtl\arm\arm.inc
|
---|
procedure ARMv7DataSynchronizationBarrier; assembler; nostackframe;
Note | See page A8-92 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InstructionMemoryBarrier; assembler; nostackframe;
Note | See page A8-102 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateTLB; assembler; nostackframe;
Note | See page B3-138 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateDataTLB; assembler; nostackframe;
Note | See page B3-138 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateInstructionTLB; assembler; nostackframe;
Note | See page B3-138 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateCache; assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7CleanDataCache; assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateDataCache; assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateL1DataCache; assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7CleanAndInvalidateDataCache; assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateInstructionCache; assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7CleanDataCacheRange(Address,Size:LongWord); assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateDataCacheRange(Address,Size:LongWord); assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7CleanAndInvalidateDataCacheRange(Address,Size:LongWord); assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7InvalidateInstructionCacheRange(Address,Size:LongWord); assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7CleanDataCacheSetWay(SetWay:LongWord); assembler; nostackframe;
SetWay | Set/Way/Level will be passed in r0 |
---|---|
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
procedure ARMv7InvalidateDataCacheSetWay(SetWay:LongWord); assembler; nostackframe;
SetWay | Set/Way/Level will be passed in r0 |
---|---|
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
procedure ARMv7CleanAndInvalidateDataCacheSetWay(SetWay:LongWord); assembler; nostackframe;
SetWay | Set/Way/Level will be passed in r0 |
---|---|
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
procedure ARMv7FlushPrefetchBuffer; assembler; nostackframe;
Note | See page A8-102 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7FlushBranchTargetCache; assembler; nostackframe;
Note | See page B3-127 of the ARMv7 Architecture Reference Manual |
---|
procedure ARMv7ContextSwitch(OldStack,NewStack:Pointer; NewThread:TThreadHandle); assembler; nostackframe;
OldStack | The address to save the stack pointer to for the current thread (Passed in r0) |
---|---|
NewStack | The address to restore the stack pointer from for the new thread (Passed in r1) |
NewThread | The handle of the new thread to switch to (Passed in r2) |
Note | At the point of the actual context switch (str sp / ldr sp) the thread stacks will look like this:
|
procedure ARMv7ContextSwitchIRQ(OldStack,NewStack:Pointer; NewThread:TThreadHandle); assembler; nostackframe;
OldStack | The address to save the stack pointer to for the current thread (Passed in r0) |
---|---|
NewStack | The address to restore the stack pointer from for the new thread (Passed in r1) |
NewThread | The handle of the new thread to switch to (Passed in r2) |
Note | At the point of the actual context switch (str sp / ldr sp) the thread stacks will look like this:
|
procedure ARMv7ContextSwitchFIQ(OldStack,NewStack:Pointer; NewThread:TThreadHandle); assembler; nostackframe;
OldStack | The address to save the stack pointer to for the current thread (Passed in r0) |
---|---|
NewStack | The address to restore the stack pointer from for the new thread (Passed in r1) |
NewThread | The handle of the new thread to switch to (Passed in r2) |
Note | At the point of the actual context switch (str sp / ldr sp) the thread stacks will look like this:
|
procedure ARMv7ContextSwitchSWI(OldStack,NewStack:Pointer; NewThread:TThreadHandle); assembler; nostackframe;
OldStack | The address to save the stack pointer to for the current thread (Passed in r0) |
---|---|
NewStack | The address to restore the stack pointer from for the new thread (Passed in r1) |
NewThread | The handle of the new thread to switch to (Passed in r2) |
Note | At the point of the actual context switch (str sp / ldr sp) the thread stacks will look like this:
|
function ARMv7InterlockedOr(var Target:LongInt; Value:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7InterlockedXor(var Target:LongInt; Value:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7InterlockedAnd(var Target:LongInt; Value:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7InterlockedDecrement(var Target:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7InterlockedIncrement(var Target:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7InterlockedExchange(var Target:LongInt; Source:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7InterlockedAddExchange(var Target:LongInt; Source:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7InterlockedCompareExchange(var Target:LongInt; Source,Compare:LongInt):LongInt; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7PageTableGetEntry(Address:PtrUInt):TPageTableEntry;
Note | None documented |
---|
function ARMv7PageTableSetEntry(const Entry:TPageTableEntry):LongWord;
Note | None documented |
---|
function ARMv7VectorTableGetEntry(Number:LongWord):PtrUInt;
Note | None documented |
---|
function ARMv7VectorTableSetEntry(Number:LongWord; Address:PtrUInt):LongWord;
Note | None documented |
---|
function ARMv7FirstBitSet(Value:LongWord):LongWord; assembler; nostackframe;
Note | ARM arm states that CLZ is supported for ARMv5 and above |
---|
function ARMv7CountLeadingZeros(Value:LongWord):LongWord; assembler; nostackframe;
Note | ARM arm states that CLZ is supported for ARMv5 and above |
---|
ARMv7 thread functions
procedure ARMv7PrimaryInit; assembler; nostackframe;
Note | None documented |
---|
function ARMv7SpinLock(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinUnlock(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinLockIRQ(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinUnlockIRQ(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinLockFIQ(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinUnlockFIQ(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinLockIRQFIQ(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinUnlockIRQFIQ(Spin:PSpinEntry):LongWord; assembler; nostackframe;
Spin | Pointer to the Spin entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7SpinCheckIRQ(Spin:PSpinEntry):Boolean;
Return | True if the mask would enable IRQ on restore, False if it would not |
---|
function ARMv7SpinCheckFIQ(Spin:PSpinEntry):Boolean;
Return | True if the mask would enable FIQ on restore, False if it would not |
---|
function ARMv7SpinExchangeIRQ(Spin1,Spin2:PSpinEntry):LongWord;
Note | None documented |
---|
function ARMv7SpinExchangeFIQ(Spin1,Spin2:PSpinEntry):LongWord;
Note | None documented |
---|
function ARMv7MutexLock(Mutex:PMutexEntry):LongWord; assembler; nostackframe;
Mutex | Pointer to the Mutex entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7MutexUnlock(Mutex:PMutexEntry):LongWord; assembler; nostackframe;
Mutex | Pointer to the Mutex entry to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed or another error code on failure (Returned in R0) |
function ARMv7MutexTryLock(Mutex:PMutexEntry):LongWord; assembler; nostackframe;
Mutex | Pointer to the Mutex entry to try to lock (Passed in R0) |
---|---|
Return | ERROR_SUCCESS if completed, ERROR_LOCKED if already locked or another error code on failure (Returned in R0) |
function ARMv7ThreadGetCurrent:TThreadHandle; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7ThreadSetCurrent(Thread:TThreadHandle):LongWord; assembler; nostackframe;
Note | See page ??? |
---|
function ARMv7ThreadSetupStack(StackBase:Pointer; StartProc:TThreadStart; ReturnProc:TThreadEnd; Parameter:Pointer):Pointer;
StackBase | Pointer to the base (highest address) of the allocated stack (as returned by ThreadAllocateStack |
---|---|
StartProc | The procedure the thread will start executing when resumed |
ReturnProc | The procedure the thread will return to on exit |
Return | Pointer to the starting address of the stack, which will be the Stack Pointer on the first context switch |
Note | At the point of a context switch the thread stack will look like this:
|
ARMv7 IRQ functions
function ARMv7DispatchIRQ(CPUID:LongWord; Thread:TThreadHandle):TThreadHandle; inline;
Note | None documented |
---|
ARMv7 FIQ functions
function ARMv7DispatchFIQ(CPUID:LongWord; Thread:TThreadHandle):TThreadHandle; inline;
Note | None documented |
---|
ARMv7 SWI functions
function ARMv7DispatchSWI(CPUID:LongWord; Thread:TThreadHandle; Request:PSystemCallRequest):TThreadHandle; inline;
Note | None documented |
---|
ARMv7 interrupt functions
procedure ARMv7ResetHandler; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7UndefinedInstructionHandler; assembler; nostackframe;
Note | This routine is registered as the vector for undefined instruction exception in the vector table loaded during startup |
---|
procedure ARMv7SoftwareInterruptHandler; assembler; nostackframe;
Note | This routine is registered as the vector for SWI requests in the vector table loaded during startup. When the processor executes an SVC it switches to SWI mode, stores the address of the next instruction in the SWI mode link register (lr_svc) and saves the current program status register into the SWI mode saved program status register (spsr_svc).
|
---|
procedure ARMv7PrefetchAbortHandler; assembler; nostackframe;
Note | This routine is registered as the vector for prefetch abort exception in the vector table loaded during startup |
---|
procedure ARMv7DataAbortHandler; assembler; nostackframe;
Note | This routine is registered as the vector for data abort exception in the vector table loaded during startup |
---|
procedure ARMv7ReservedHandler; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7IRQHandler; assembler; nostackframe;
Note | This routine is registered as the vector for IRQ requests in the vector table loaded during startup.
|
---|
procedure ARMv7FIQHandler; assembler; nostackframe;
Note | This routine is registered as the vector for FIQ requests in the vector table loaded during startup.
|
---|
ARMv7 helper functions
function ARMv7GetFPEXC:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7GetFPSCR:LongWord; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7StartMMU; assembler; nostackframe;
Note | None documented |
---|
function ARMv7GetTimerState(Timer:LongWord):LongWord; assembler; nostackframe;
Note | None documented |
---|
procedure ARMv7SetTimerState(Timer,State:LongWord); assembler; nostackframe;
Note | None documented |
---|
function ARMv7GetTimerCount(Timer:LongWord):Int64; assembler; nostackframe;
Note | None documented |
---|
function ARMv7GetTimerValue(Timer:LongWord):LongWord; assembler; nostackframe;
Note | None documented |
---|
procedure ARMV7SetTimerValue(Timer,Value:LongWord); assembler; nostackframe;
Note | None documented |
---|
function ARMv7GetTimerCompare(Timer:LongWord):Int64; assembler; nostackframe;
Note | None documented |
---|
procedure ARMV7SetTimerCompare(Timer,High,Low:LongWord);
Note | None documented |
---|
function ARMv7GetTimerFrequency:LongWord; assembler; nostackframe;
Note | None documented |
---|
function ARMv7GetPageTableCoarse(Address:PtrUInt):LongWord;
Note | See page ??? |
---|
function ARMv7SetPageTableCoarse(Address,CoarseAddress:PtrUInt; Flags:Word):Boolean;
Note | See page ???
Caller must call ARMv7InvalidateTLB after changes if MMU is enabled |
---|
function ARMv7GetPageTableLarge(Address:PtrUInt):LongWord;
Note | See page ??? |
---|
function ARMv7SetPageTableLarge(Address,PhysicalAddress:PtrUInt; Flags:Word):Boolean;
Note | Large Page Table descriptors must begin on a 16 longword (64 byte) boundary and be repeated for 16 consecutive longwords
See page ???
|
---|
function ARMv7GetPageTableSmall(Address:PtrUInt):LongWord;
Note | See page ??? |
---|
function ARMv7SetPageTableSmall(Address,PhysicalAddress:PtrUInt; Flags:Word):Boolean;
Note | See page ???
Caller must call ARMv7InvalidateTLB after changes if MMU is enabled |
---|
function ARMv7GetPageTableSection(Address:PtrUInt):LongWord;
Note | See page ??? |
---|
function ARMv7SetPageTableSection(Address,PhysicalAddress:PtrUInt; Flags:LongWord):Boolean;
Note | See page ???
Caller must call ARMv7InvalidateTLB after changes if MMU is enabled |
---|
function ARMv7SetPageTableSupersection(Address,PhysicalAddress:PtrUInt; Flags:LongWord):Boolean;
Note | Supersection Page Table descriptors must begin on a 16 longword (64 byte) boundary and be repeated for 16 consecutive longwords
See page ???
|
---|