Unit PlatformARMv7L

From Ultibo.org
Revision as of 06:09, 19 June 2021 by Ultibo (Talk | contribs)

Jump to: navigation, search

Return to Unit Reference


Description


Ultibo Platform interface unit for ARMv7 LPAE

This unit extends the Platform ARMv7 unit to provide support for implementations using the Large Physical Address Extensions (LPAE) to access greater than 4GB of memory in 32-bit environments.

The LPAE defines a new page table descriptor format along with new memory region attributes and memory attribute indirection registers (MAIR0/1) as well as extending the TTBR0, TTBR1 and TTBCR registers with additional information.

The LPAE extensions allow addressing of up to 40 bits of physical address space (1TB) by mapping it into the 32-bit virtual address space.

For 64-bit environments the Platform ARMv8 unit provides the equivalent functionality as LPAE is not required and the processor can address up to 48 bits of address space directly. All functionality not directly related to LPAE is provided from the Platform ARMv7 unit.

Constants


To be documented

Type definitions


To be documented

Public variables


To be documented

Function declarations



Initialization functions

procedure ARMv7LInit;
Description: To be documented
Note None documented


ARMv7L platform functions

procedure ARMv7LMMUInit;
Description: To be documented
Note None documented


procedure ARMv7LPageTableInit;
Description: Initialize the Hardware Page Tables before enabling the MMU
Note None documented


procedure ARMv7LPageTableGetEntry(Address:PtrUInt; var Entry:TPageTableEntry);
Description: Get and Decode the entry in the Page Table that corresponds to the supplied virtual address
Note None documented


function ARMv7LPageTableSetEntry(const Entry:TPageTableEntry):LongWord;
Description: Encode and Set an entry in the Page Table that corresponds to the supplied virtual address
Note None documented


ARMv7L helper functions

procedure ARMv7LStartMMU;
Description: To be documented
Note None documented


function ARMv7LGetPageTableLevel1(Address:PtrUInt):UInt64;
Description: Get the descriptor for a Level 1 Page Table (1GB)
Note None documented


function ARMv7LSetPageTableLevel1(Address,TableAddress:PtrUInt; Flags:UInt64):Boolean;
Description: Set the descriptor for a Level 1 Page Table (1GB)
Note Caller must call ARMv7InvalidateTLB after changes if MMU is enabled


function ARMv7LGetPageTableLevel2(Address:PtrUInt):UInt64;
Description: Get the descriptor for a Level 2 Page Table (2MB)
Note None documented


function ARMv7LSetPageTableLevel2(Address,TableAddress:PtrUInt; Flags:UInt64):Boolean;
Description: Set the descriptor for a Level 2 Page Table (2MB)
Note Caller must call ARMv7InvalidateTLB after changes if MMU is enabled


function ARMv7LGetPageTablePage(Address:PtrUInt):UInt64;
Description: Get the descriptor for a Page Table Page (4KB)
Note None documented


function ARMv7LSetPageTablePage(Address:PtrUInt; PhysicalRange:LongWord; PhysicalAddress:PtrUInt; Flags:UInt64):Boolean;
Description: Set the descriptor for a Page Table Page (4KB)
Note Caller must call ARMv7InvalidateTLB after changes if MMU is enabled


function ARMv7LGetPageTableSection(Address:PtrUInt):UInt64;
Description: Get the descriptor for a Page Table Section (2MB)
Note None documented


function ARMv7LSetPageTableSection(Address:PtrUInt; PhysicalRange:LongWord; PhysicalAddress:PtrUInt; Flags:UInt64):Boolean;
Description: Set the descriptor for a Page Table Section (2MB)
Note Caller must call ARMv7InvalidateTLB after changes if MMU is enabled


function ARMv7LGetPageTableLargeSection(Address:PtrUInt):UInt64;
Description: Get the descriptor for a Page Table Large Section (1GB)
Note None documented


function ARMv7LSetPageTableLargeSection(Address:PtrUInt; PhysicalRange:LongWord; PhysicalAddress:PtrUInt; Flags:UInt64):Boolean;
Description: Set the descriptor for a Page Table Large Section (1GB)
Note Caller must call ARMv7InvalidateTLB after changes if MMU is enabled


Return to Unit Reference