The Pedigree Project
0.1
|
#include <VirtualAddressSpace.h>
Public Member Functions | |
virtual bool | isMapped (void *virtualAddress) |
virtual bool | map (physical_uintptr_t physicalAddress, void *virtualAddress, size_t flags) |
virtual void | getMapping (void *virtualAddress, physical_uintptr_t &physicalAddress, size_t &flags) |
virtual void | setFlags (void *virtualAddress, size_t newFlags) |
virtual void | unmap (void *virtualAddress) |
virtual bool | initialiseKernelAddressSpace () |
Public Member Functions inherited from ArmV7VirtualAddressSpace | |
virtual bool | isAddressValid (void *virtualAddress) |
virtual void * | allocateStack () |
virtual void * | allocateStack (size_t stackSz) |
virtual void | freeStack (void *pStack) |
virtual bool | memIsInHeap (void *pMem) |
virtual void * | getEndOfHeap () |
bool | mapPageStructures (physical_uintptr_t physicalAddress, void *virtualAddress, size_t flags) |
virtual VirtualAddressSpace * | clone () |
virtual void | revertToKernelAddressSpace () |
virtual uintptr_t | getKernelStart () const |
virtual uintptr_t | getUserStart () const |
virtual uintptr_t | getUserReservedStart () const |
virtual uintptr_t | getDynamicLinkerAddress () const |
virtual uintptr_t | getKernelHeapStart () const |
virtual uintptr_t | getKernelHeapEnd () const |
virtual uintptr_t | getKernelCacheStart () const |
virtual uintptr_t | getKernelCacheEnd () const |
virtual uintptr_t | getKernelEventBlockStart () const |
virtual uintptr_t | getKernelModulesStart () const |
virtual uintptr_t | getKernelModulesEnd () const |
Public Member Functions inherited from VirtualAddressSpace | |
virtual void * | expandHeap (ssize_t incr, size_t flags) |
virtual bool | mapHuge (physical_uintptr_t physAddress, void *virtualAddress, size_t count, size_t flags) |
virtual void | freeStack (Stack *pStack)=0 |
virtual VirtualAddressSpace * | clone (bool copyOnWrite=true)=0 |
virtual | ~VirtualAddressSpace () |
void | setHeap (void *heap, void *heapEnd) |
virtual bool | memIsInKernelHeap (void *pMem)=0 |
virtual uintptr_t | getDynamicStart () const |
virtual uintptr_t | getDynamicEnd () const |
virtual uintptr_t | getGlobalInfoBlock () const |
Private Member Functions | |
ArmV7KernelVirtualAddressSpace () | |
~ArmV7KernelVirtualAddressSpace () | |
ArmV7KernelVirtualAddressSpace (const ArmV7KernelVirtualAddressSpace &) | |
ArmV7KernelVirtualAddressSpace & | operator= (const ArmV7KernelVirtualAddressSpace &) |
Static Private Attributes | |
static ArmV7KernelVirtualAddressSpace | m_Instance |
Friends | |
class | Processor |
class | ArmV7VirtualAddressSpace |
VirtualAddressSpace & | VirtualAddressSpace::getKernelAddressSpace () |
Additional Inherited Members | |
Static Public Member Functions inherited from VirtualAddressSpace | |
static EXPORTED_PUBLIC VirtualAddressSpace & | getKernelAddressSpace () |
static VirtualAddressSpace * | create () |
Public Attributes inherited from VirtualAddressSpace | |
void * | m_Heap |
void * | m_HeapEnd |
Static Public Attributes inherited from VirtualAddressSpace | |
static const size_t | KernelMode = 0x01 |
static const size_t | Write = 0x02 |
static const size_t | Execute = 0x04 |
static const size_t | WriteThrough = 0x08 |
static const size_t | CacheDisable = 0x10 |
static const size_t | CopyOnWrite = 0x20 |
static const size_t | Swapped = 0x40 |
static const size_t | MemoryCoherent = 0x80 |
static const size_t | Guarded = 0x100 |
static const size_t | Shared = 0x200 |
static const size_t | WriteCombine = 0x400 |
static const size_t | Accessed = 0x800 |
static const size_t | Dirty = 0x1000 |
static const size_t | ClearDirty = 0x2000 |
static physical_uintptr_t | m_ZeroPage = 0 |
Protected Member Functions inherited from ArmV7VirtualAddressSpace | |
virtual | ~ArmV7VirtualAddressSpace () |
ArmV7VirtualAddressSpace (void *Heap, physical_uintptr_t PhysicalPageDirectory, void *VirtualPageDirectory, void *VirtualPageTables, void *VirtualStack) | |
bool | doIsMapped (void *virtualAddress) |
bool | doMap (physical_uintptr_t physicalAddress, void *virtualAddress, size_t flags) |
void | doGetMapping (void *virtualAddress, physical_uintptr_t &physicalAddress, size_t &flags) |
void | doSetFlags (void *virtualAddress, size_t newFlags) |
void | doUnmap (void *virtualAddress) |
void * | doAllocateStack (size_t sSize) |
Protected Member Functions inherited from VirtualAddressSpace | |
VirtualAddressSpace (void *Heap) | |
The kernel's VirtualAddressSpace on ArmV7
Definition at line 375 of file kernel/core/processor/armv7/VirtualAddressSpace.h.
|
private |
The constructor
Definition at line 652 of file armv7/VirtualAddressSpace.cc.
References initialiseKernelAddressSpace().
|
private |
The destructor
Definition at line 663 of file armv7/VirtualAddressSpace.cc.
|
private |
The copy-constructor
|
virtual |
Get the physical address and the flags associated with the specific virtual address.
[in] | virtualAddress | the address in the virtual address space |
[out] | flags | the flags |
[out] | physicalAddress | the physical address |
Reimplemented from ArmV7VirtualAddressSpace.
Definition at line 676 of file armv7/VirtualAddressSpace.cc.
References VirtualAddressSpace::KernelMode.
|
virtual |
Definition at line 495 of file armv7/VirtualAddressSpace.cc.
References ArmV7VirtualAddressSpace::FirstLevelDescriptor::descriptor, ArmV7VirtualAddressSpace::SecondLevelDescriptor::descriptor, ArmV7VirtualAddressSpace::m_PhysicalPageDirectory, and ArmV7VirtualAddressSpace::m_VirtualPageDirectory.
Referenced by ArmV7KernelVirtualAddressSpace().
|
virtual |
Checks whether a mapping the the specific virtual address exists. Pages marked as swapped out are not considered mapped.
[in] | virtualAddress | the virtual address |
Reimplemented from ArmV7VirtualAddressSpace.
Definition at line 667 of file armv7/VirtualAddressSpace.cc.
|
virtual |
Map a specific physical page (of size PhysicalMemoryManager::getPageSize()) at a specific location into the virtual address space.
[in] | physicalAddress | the address of the physical page that should be mapped into the virtual address space. |
[in] | virtualAddress | the virtual address at which the page apears within the virtual address space. |
[in] | flags | flags that describe which accesses should be allowed on the page. |
Reimplemented from ArmV7VirtualAddressSpace.
Definition at line 671 of file armv7/VirtualAddressSpace.cc.
References ArmV7VirtualAddressSpace::doMap().
|
private |
The assignment operator
|
virtual |
Set the flags of the page at a specific virtual address.
[in] | virtualAddress | the virtual address |
[in] | newFlags | the flags |
Reimplemented from ArmV7VirtualAddressSpace.
Definition at line 683 of file armv7/VirtualAddressSpace.cc.
|
virtual |
Remove the page at the specific virtual address from the virtual address space.
[in] | virtualAddress | the virtual address |
Reimplemented from ArmV7VirtualAddressSpace.
Definition at line 688 of file armv7/VirtualAddressSpace.cc.
|
friend |
ArmV7VirtualAddressSpace needs access to m_Instance
Definition at line 380 of file kernel/core/processor/armv7/VirtualAddressSpace.h.
|
friend |
Give Processor access to m_Instance
Definition at line 378 of file kernel/core/processor/armv7/VirtualAddressSpace.h.
VirtualAddressSpace::getKernelAddressSpace() needs access to m_Instance
|
staticprivate |
The kernel virtual address space
Definition at line 414 of file kernel/core/processor/armv7/VirtualAddressSpace.h.