The Pedigree Project
0.1
|
#include <VirtualAddressSpace.h>
Classes | |
class | Stack |
Public Member Functions | |
virtual void * | expandHeap (ssize_t incr, size_t flags) |
virtual bool | isAddressValid (void *virtualAddress)=0 |
virtual bool | isMapped (void *virtualAddress)=0 |
virtual bool | map (physical_uintptr_t physicalAddress, void *virtualAddress, size_t flags)=0 |
virtual bool | mapHuge (physical_uintptr_t physAddress, void *virtualAddress, size_t count, size_t flags) |
virtual void | getMapping (void *virtualAddress, physical_uintptr_t &physicalAddress, size_t &flags)=0 |
virtual void | setFlags (void *virtualAddress, size_t newFlags)=0 |
virtual void | unmap (void *virtualAddress)=0 |
virtual Stack * | allocateStack ()=0 |
virtual Stack * | allocateStack (size_t stackSz) |
virtual void | freeStack (Stack *pStack)=0 |
virtual VirtualAddressSpace * | clone (bool copyOnWrite=true)=0 |
virtual void | revertToKernelAddressSpace ()=0 |
virtual | ~VirtualAddressSpace () |
void | setHeap (void *heap, void *heapEnd) |
virtual bool | memIsInKernelHeap (void *pMem)=0 |
virtual bool | memIsInHeap (void *pMem)=0 |
virtual void * | getEndOfHeap ()=0 |
virtual uintptr_t | getKernelStart () const =0 |
virtual uintptr_t | getUserStart () const =0 |
virtual uintptr_t | getUserReservedStart () const =0 |
virtual uintptr_t | getDynamicLinkerAddress () const =0 |
virtual uintptr_t | getKernelHeapStart () const =0 |
virtual uintptr_t | getKernelHeapEnd () const =0 |
virtual uintptr_t | getKernelCacheStart () const =0 |
virtual uintptr_t | getKernelCacheEnd () const =0 |
virtual uintptr_t | getKernelEventBlockStart () const =0 |
virtual uintptr_t | getKernelModulesStart () const =0 |
virtual uintptr_t | getKernelModulesEnd () const =0 |
virtual uintptr_t | getDynamicStart () const |
virtual uintptr_t | getDynamicEnd () const |
virtual uintptr_t | getGlobalInfoBlock () const |
Static Public Member Functions | |
static EXPORTED_PUBLIC VirtualAddressSpace & | getKernelAddressSpace () |
static VirtualAddressSpace * | create () |
Public Attributes | |
void * | m_Heap |
void * | m_HeapEnd |
Static Public Attributes | |
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 | |
VirtualAddressSpace (void *Heap) | |
Private Member Functions | |
VirtualAddressSpace () | |
VirtualAddressSpace (const VirtualAddressSpace &) | |
VirtualAddressSpace & | operator= (const VirtualAddressSpace &) |
void | rollbackHeapExpansion (void *virtualAddress, size_t pageCount) |
Friends | |
class | Debugger |
The VirtualAddressSpace encapsulates all the functionality of a virtual memory- management. This includes management of the mapping between physical and virtual memory, management of allocated physical memory pages and management of free/allocated virtual memory.
Definition at line 37 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
|
inlinevirtual |
The destructor does nothing
Definition at line 171 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
|
inlineprotected |
The constructor does nothing
Definition at line 286 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
References operator=(), rollbackHeapExpansion(), and VirtualAddressSpace().
|
private |
The default constructor
Referenced by VirtualAddressSpace().
|
private |
The copy-constructor
|
pure virtual |
Allocates a single stack for a thread. Will use the default kernel thread size.
Implemented in X86KernelVirtualAddressSpace, X64VirtualAddressSpace, MIPS32VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, PPC32VirtualAddressSpace, and Arm926EVirtualAddressSpace.
Referenced by HostedVirtualAddressSpace::allocateStack(), X64VirtualAddressSpace::allocateStack(), allocateStack(), Thread::allocateStackAtLevel(), and PerProcessorScheduler::checkEventState().
|
inlinevirtual |
Allocates a single stack of the given size for a thread.
Reimplemented in X64VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, and X86VirtualAddressSpace.
Definition at line 145 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
References allocateStack(), clone(), create(), freeStack(), and revertToKernelAddressSpace().
|
pure virtual |
Clone this VirtualAddressSpace. That means that we copy-on-write-map the application * image. *
[in] | copyOnWrite | whether the new address space copies pages on write, or shares them with the parent address space. |
Implemented in X64VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by allocateStack(), X86GdtManager::initialiseDoubleFaultTss(), and Process::Process().
|
static |
Create a new VirtualAddressSpace. Only the kernel is mapped into that virtual address space
Definition at line 35 of file arm_926e/VirtualAddressSpace.cc.
Referenced by allocateStack(), PPC32VirtualAddressSpace::clone(), HostedVirtualAddressSpace::clone(), X64VirtualAddressSpace::clone(), and X86VirtualAddressSpace::fromFlags().
|
virtual |
Expand the heap
[in] | pageCount | the number of pages that should be allocated and mapped to the heap end |
[in] | flags | flags that describe which accesses should be allowed on the page |
Definition at line 27 of file VirtualAddressSpace.cc.
References PhysicalMemoryManager::allocatePage(), CopyOnWrite, ERROR, FATAL, PhysicalMemoryManager::freePage(), getDynamicStart(), getKernelHeapStart(), getKernelStart(), getMapping(), PhysicalMemoryManager::getPageSize(), PhysicalMemoryManager::instance(), isMapped(), m_HeapEnd, m_ZeroPage, map(), PhysicalMemoryManager::pin(), unmap(), WARNING, and Write.
|
pure virtual |
Frees a stack allocated with allocateStack.
Implemented in X64VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by allocateStack(), and Thread::cleanStateLevel().
|
inlinevirtual |
Gets address of the end of the dynamic memory mapping area.
Reimplemented in X64VirtualAddressSpace, and HostedVirtualAddressSpace.
Definition at line 238 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by PosixSubsystem::invoke().
|
pure virtual |
Gets address of the dynamic linker in the address space.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by setHeap().
|
inlinevirtual |
Gets address of the start of the dynamic memory mapping area. This is an area in which memory mappings can be created for userspace applications. Systems that do not have room in the address space for this may return zero.
Reimplemented in X64VirtualAddressSpace, and HostedVirtualAddressSpace.
Definition at line 233 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by expandHeap(), Thread::getTlsBase(), PosixSubsystem::invoke(), and Thread::~Thread().
|
pure virtual |
Gets a pointer to the byte after the end of the heap.
Implemented in X64VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, and X86VirtualAddressSpace.
Referenced by X86VirtualAddressSpace::memIsInHeap(), HostedVirtualAddressSpace::memIsInHeap(), X64VirtualAddressSpace::memIsInHeap(), and setHeap().
|
inlinevirtual |
Gets address of the global info block location.
Reimplemented in X64VirtualAddressSpace.
Definition at line 244 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by PosixSyscallManager::syscall().
|
static |
Get the kernel virtual address space
Definition at line 30 of file arm_926e/VirtualAddressSpace.cc.
References Arm926EVirtualAddressSpace::m_KernelSpace.
Referenced by ArmV7PhysicalMemoryManager::allocateRegion(), PpcCommonPhysicalMemoryManager::allocateRegion(), ArmV7VirtualAddressSpace::allocateStack(), HostedVirtualAddressSpace::allocateStack(), Thread::allocateStackAtLevel(), Thread::cleanStateLevel(), MappingCommand::execute(), Bios::executeInterrupt(), CacheManager::executeRequest(), ArmV7PhysicalMemoryManager::PageStack::free(), HostedPhysicalMemoryManager::PageStack::free(), HostedVirtualAddressSpace::getMapping(), Event::getTrampoline(), ArmCommonProcessorInformation::getVirtualAddressSpace(), HostedProcessorInformation::getVirtualAddressSpace(), X86CommonProcessorInformation::getVirtualAddressSpace(), X86CommonPhysicalMemoryManager::initialisationDone(), X86CommonPhysicalMemoryManager::initialise64(), X86GdtManager::initialiseDoubleFaultTss(), ARMV7InterruptManager::initialiseProcessor(), MIPS32TlbManager::interrupt(), HostedVirtualAddressSpace::isMapped(), KernelElf::loadModule(), HostedVirtualAddressSpace::map(), X86CommonPhysicalMemoryManager::PageStack::maybeMap(), SlamCache::recovery(), HostedVirtualAddressSpace::revertToKernelAddressSpace(), HostedVirtualAddressSpace::setFlags(), Debugger::start(), HostedVirtualAddressSpace::switchAddressSpace(), PosixSyscallManager::syscall(), HostedVirtualAddressSpace::unmap(), PpcCommonPhysicalMemoryManager::unmapRegion(), HostedPhysicalMemoryManager::unmapRegion(), X86CommonPhysicalMemoryManager::unmapRegion(), SlamAllocator::wipe(), and X86VirtualAddressSpace::X86VirtualAddressSpace().
|
pure virtual |
Gets address of the end of the kernel's cache region.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by CacheManager::executeRequest(), and setHeap().
|
pure virtual |
Gets address of the start of the kernel's cache region.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by CacheManager::executeRequest(), and setHeap().
|
pure virtual |
Gets address of the start of the kernel's event handling block.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by Event::getTrampoline(), and setHeap().
|
pure virtual |
Gets address of the end of the kernel's heap region.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by setHeap().
|
pure virtual |
Gets address of the start of the kernel's heap region.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by expandHeap(), and setHeap().
|
pure virtual |
Gets address of the end of the kernel's module region.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by KernelElf::loadModule(), and setHeap().
|
pure virtual |
Gets address of the start of the kernel's module region.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by KernelElf::loadModule(), and setHeap().
|
pure virtual |
Gets start address of the kernel in the address space.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by PosixSubsystem::checkAddress(), expandHeap(), and setHeap().
|
pure 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 |
Implemented in ArmV7KernelVirtualAddressSpace, X86KernelVirtualAddressSpace, X64VirtualAddressSpace, MIPS32VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, PPC32VirtualAddressSpace, and Arm926EVirtualAddressSpace.
Referenced by BusMasterIde::add(), Uhci::addTransferToTransaction(), Ohci::addTransferToTransaction(), PosixSubsystem::checkAddress(), PerProcessorScheduler::checkEventState(), MemoryMappedFile::compact(), Cache::evict(), MappingCommand::execute(), expandHeap(), HostedVirtualAddressSpace::freeStack(), X64VirtualAddressSpace::freeStack(), HostedVirtualAddressSpace::getMapping(), File::getPhysicalPage(), X86CommonPhysicalMemoryManager::initialisationDone(), Ipc::IpcMessage::IpcMessage(), AnonymousMemoryMap::remove(), MemoryMappedFile::remove(), rollbackHeapExpansion(), AnonymousMemoryMap::setPermissions(), MemoryMappedFile::setPermissions(), MemoryMappedFile::sync(), AnonymousMemoryMap::trap(), KernelElf::unloadModule(), HostedPhysicalMemoryManager::unmapRegion(), X86CommonPhysicalMemoryManager::unmapRegion(), and Thread::~Thread().
|
pure virtual |
Gets start address of reserved areas of the userpace address space.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by PosixSubsystem::invoke(), and setHeap().
|
pure virtual |
Gets start address of the region usable and cloneable for userspace.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, and HostedVirtualAddressSpace.
Referenced by PosixSubsystem::checkAddress(), PosixSubsystem::invoke(), and setHeap().
|
pure virtual |
Is a particular virtual address valid?
[in] | virtualAddress | the virtual address to check |
Implemented in MIPS32VirtualAddressSpace, X64VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, PPC32VirtualAddressSpace, and Arm926EVirtualAddressSpace.
|
pure 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 |
Implemented in ArmV7KernelVirtualAddressSpace, X86KernelVirtualAddressSpace, MIPS32VirtualAddressSpace, X64VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, PPC32VirtualAddressSpace, and Arm926EVirtualAddressSpace.
Referenced by BusMasterIde::add(), Uhci::addTransferToTransaction(), Ohci::addTransferToTransaction(), PosixSubsystem::checkAddress(), PerProcessorScheduler::checkEventState(), MemoryMappedFile::compact(), MappingCommand::execute(), Bios::executeInterrupt(), expandHeap(), HostedVirtualAddressSpace::freeStack(), X64VirtualAddressSpace::freeStack(), HostedVirtualAddressSpace::getMapping(), File::getPhysicalPage(), MemoryMappedFile::invalidate(), Ipc::IpcMessage::IpcMessage(), HostedVirtualAddressSpace::isMapped(), Elf::loadModule(), HostedVirtualAddressSpace::map(), Backtrace::performBpBacktrace(), AnonymousMemoryMap::remove(), MemoryMappedFile::remove(), HostedVirtualAddressSpace::revertToKernelAddressSpace(), HostedVirtualAddressSpace::setFlags(), AnonymousMemoryMap::setPermissions(), MemoryMappedFile::setPermissions(), HostedVirtualAddressSpace::switchAddressSpace(), MemoryMappedFile::sync(), AnonymousMemoryMap::trap(), MemoryMappedFile::trap(), KernelElf::unloadModule(), HostedVirtualAddressSpace::unmap(), HostedPhysicalMemoryManager::unmapRegion(), X86CommonPhysicalMemoryManager::unmapRegion(), and Thread::~Thread().
|
pure 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. |
Implemented in ArmV7KernelVirtualAddressSpace, X86KernelVirtualAddressSpace, MIPS32VirtualAddressSpace, X64VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, PPC32VirtualAddressSpace, and Arm926EVirtualAddressSpace.
Referenced by ArmV7PhysicalMemoryManager::allocateRegion(), HostedPhysicalMemoryManager::allocateRegion(), PpcCommonPhysicalMemoryManager::allocateRegion(), X86CommonPhysicalMemoryManager::allocateRegion(), PerProcessorScheduler::checkEventState(), HostedVirtualAddressSpace::doAllocateStack(), X64VirtualAddressSpace::doAllocateStack(), Bios::executeInterrupt(), expandHeap(), Thread::getTlsBase(), MemoryMappedFile::invalidate(), Elf::loadModule(), HostedVirtualAddressSpace::map(), mapHuge(), DynamicLinker::trap(), AnonymousMemoryMap::trap(), MemoryMappedFile::trap(), and X86VirtualAddressSpace::X86VirtualAddressSpace().
|
virtual |
Map a region of memory using the largest possible frame size. Where possible the largest page size should be used, degrading into smaller page sizes as needed (e.g. 1 GB, 2 MB, 4K) to reduce the overhead of the mapping on the system. Default implementation calls map() in a loop.
Reimplemented in X64VirtualAddressSpace.
Definition at line 170 of file VirtualAddressSpace.cc.
References PhysicalMemoryManager::getPageSize(), and map().
Referenced by X86CommonPhysicalMemoryManager::initialise64(), and X64VirtualAddressSpace::mapHuge().
|
pure virtual |
Determines if a given point is within the virtual address space region dedicated to the kernel heap.
Implemented in X64VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, and X86VirtualAddressSpace.
Referenced by setHeap().
|
pure virtual |
Determines whether a given address is within the kernel's heap region.
Implemented in X64VirtualAddressSpace.
Referenced by setHeap().
|
private |
The copy-constructor
Referenced by VirtualAddressSpace().
|
pure virtual |
Undo a clone() - this happens when an application is Exec()'d - we destroy all mappings not in the kernel address space so the space is 'clean'.
Implemented in X64VirtualAddressSpace, ArmV7VirtualAddressSpace, HostedVirtualAddressSpace, X86VirtualAddressSpace, Arm926EVirtualAddressSpace, and PPC32VirtualAddressSpace.
Referenced by allocateStack(), PosixSubsystem::invoke(), Process::~Process(), and X64VirtualAddressSpace::~X64VirtualAddressSpace().
|
private |
Reverts the heap expansion, that was begun with expandHeap
[in] | virtualAddress | current heap address |
[in] | pageCount | number of mapped pages to unmap and free |
Definition at line 148 of file VirtualAddressSpace.cc.
References PhysicalMemoryManager::freePage(), getMapping(), PhysicalMemoryManager::getPageSize(), PhysicalMemoryManager::instance(), physicalAddress(), and unmap().
Referenced by VirtualAddressSpace().
|
pure virtual |
Set the flags of the page at a specific virtual address.
[in] | virtualAddress | the virtual address |
[in] | newFlags | the flags |
Implemented in ArmV7KernelVirtualAddressSpace, X86KernelVirtualAddressSpace, X64VirtualAddressSpace, MIPS32VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, PPC32VirtualAddressSpace, and Arm926EVirtualAddressSpace.
Referenced by Elf::finaliseModule(), HostedVirtualAddressSpace::setFlags(), AnonymousMemoryMap::setPermissions(), and MemoryMappedFile::setPermissions().
|
inline |
Setter for the internal Heap and HeapEnd variables
Definition at line 176 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
References getDynamicLinkerAddress(), getEndOfHeap(), getKernelCacheEnd(), getKernelCacheStart(), getKernelEventBlockStart(), getKernelHeapEnd(), getKernelHeapStart(), getKernelModulesEnd(), getKernelModulesStart(), getKernelStart(), getUserReservedStart(), getUserStart(), m_Heap, m_HeapEnd, memIsInHeap(), and memIsInKernelHeap().
|
pure virtual |
Remove the page at the specific virtual address from the virtual address space.
[in] | virtualAddress | the virtual address |
Implemented in ArmV7KernelVirtualAddressSpace, X86KernelVirtualAddressSpace, X64VirtualAddressSpace, MIPS32VirtualAddressSpace, HostedVirtualAddressSpace, ArmV7VirtualAddressSpace, X86VirtualAddressSpace, PPC32VirtualAddressSpace, and Arm926EVirtualAddressSpace.
Referenced by MemoryMappedFile::compact(), Cache::evict(), expandHeap(), HostedVirtualAddressSpace::freeStack(), X64VirtualAddressSpace::freeStack(), X86CommonPhysicalMemoryManager::initialisationDone(), MemoryMappedFile::invalidate(), AnonymousMemoryMap::remove(), MemoryMappedFile::remove(), rollbackHeapExpansion(), AnonymousMemoryMap::trap(), MemoryMappedFile::trap(), KernelElf::unloadModule(), HostedVirtualAddressSpace::unmap(), PpcCommonPhysicalMemoryManager::unmapRegion(), HostedPhysicalMemoryManager::unmapRegion(), X86CommonPhysicalMemoryManager::unmapRegion(), X86VirtualAddressSpace::X86VirtualAddressSpace(), and Thread::~Thread().
|
friend |
Debugger can access our private members for statistics reporting.
Definition at line 41 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
|
static |
Whether the page has been accessed.
Definition at line 71 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), X86VirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().
|
static |
If this flag is set, the cache is disabled.
Definition at line 56 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HashedPageTable::addMapping(), X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), HashedPageTable::initialise(), PPC32VirtualAddressSpace::initialRoster(), Device::Address::map(), MIPS32VirtualAddressSpace::map(), X86VirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().
|
static |
Clear the dirty flag set by the above.
Definition at line 75 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by X86VirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().
|
static |
If this flag is set, the page is copy-on-write
Definition at line 58 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HashedPageTable::addMapping(), PosixSubsystem::checkAddress(), HostedVirtualAddressSpace::clone(), HostedVirtualAddressSpace::doAllocateStack(), X64VirtualAddressSpace::doAllocateStack(), expandHeap(), X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), X86VirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().
|
static |
Whether the page has been dirtied.
Definition at line 73 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), X86VirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().
|
static |
The page is executable. If this flag is not set the page is not executable.
Definition at line 52 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by Elf::allocate(), Elf::finaliseModule(), X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), DynamicLinker::initPlt(), MemoryMappedFile::invalidate(), PosixSubsystem::invoke(), AnonymousMemoryMap::setPermissions(), MemoryMappedFile::setPermissions(), HostedVirtualAddressSpace::toFlags(), X64VirtualAddressSpace::toFlags(), DynamicLinker::trap(), AnonymousMemoryMap::trap(), and MemoryMappedFile::trap().
|
static |
If this flag is set, the page is guarded - only applicable to PPC
Definition at line 65 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HashedPageTable::addMapping(), and HashedPageTable::initialise().
|
static |
The page is only accessible from kernel-mode. If this flag is not set the page is also accessible from user-mode.
Definition at line 47 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HashedPageTable::addMapping(), ArmV7VirtualAddressSpace::allocateStack(), Archive::Archive(), X86VirtualAddressSpace::beginCrossSpace(), PerProcessorScheduler::checkEventState(), PPC32VirtualAddressSpace::clone(), HostedVirtualAddressSpace::doAllocateStack(), X64VirtualAddressSpace::doAllocateStack(), Bios::executeInterrupt(), Elf::finaliseModule(), ArmV7PhysicalMemoryManager::PageStack::free(), X86VirtualAddressSpace::fromFlags(), ArmV7VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), ArmV7KernelVirtualAddressSpace::getMapping(), UsbUlpi::initialise(), PPCVga::initialise(), MemoryPool::initialise(), GPTimer::initialise(), Prcm::initialise(), KernelElf::initialise(), X86CommonPhysicalMemoryManager::initialise64(), Ehci::initialiseController(), ARMV7InterruptManager::initialiseProcessor(), Elf::loadModule(), Device::Address::map(), HostedVirtualAddressSpace::map(), Cache::map(), X86VirtualAddressSpace::mapCrossSpace(), X86CommonPhysicalMemoryManager::PageStack::maybeMap(), X86Vga::moveCursor(), ArmBeagleSerial::setBase(), HashedPageTable::setDBAT(), HostedVirtualAddressSpace::setFlags(), HashedPageTable::setIBAT(), HostedVirtualAddressSpace::switchAddressSpace(), X86VirtualAddressSpace::toFlags(), ArmV7VirtualAddressSpace::toFlags(), X64VirtualAddressSpace::toFlags(), and X86VirtualAddressSpace::X86VirtualAddressSpace().
void* VirtualAddressSpace::m_Heap |
Pointer to the beginning of the heap
Definition at line 250 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HostedVirtualAddressSpace::clone(), X64VirtualAddressSpace::clone(), X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::getEndOfHeap(), X64VirtualAddressSpace::memIsInHeap(), X64VirtualAddressSpace::revertToKernelAddressSpace(), and setHeap().
void* VirtualAddressSpace::m_HeapEnd |
Pointer to the current heap end
Definition at line 252 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HostedVirtualAddressSpace::clone(), X64VirtualAddressSpace::clone(), expandHeap(), X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::getEndOfHeap(), X64VirtualAddressSpace::revertToKernelAddressSpace(), and setHeap().
|
static |
Physical address of a zero page, always page-aligned.
Definition at line 254 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by expandHeap().
|
static |
If this flag is set, the page is memory coherent - only applicable to PPC
Definition at line 63 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HashedPageTable::addMapping(), and HashedPageTable::initialise().
|
static |
If this flag is set, the mapped physical page is shared.
Definition at line 67 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HostedVirtualAddressSpace::clone(), X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), MemoryMappedFile::invalidate(), HostedVirtualAddressSpace::revertToKernelAddressSpace(), AnonymousMemoryMap::setPermissions(), MemoryMappedFile::setPermissions(), X86VirtualAddressSpace::toFlags(), X64VirtualAddressSpace::toFlags(), AnonymousMemoryMap::trap(), and MemoryMappedFile::trap().
|
static |
If this flag is set, the page is swapped out
Definition at line 60 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), HostedVirtualAddressSpace::revertToKernelAddressSpace(), X86VirtualAddressSpace::toFlags(), HostedVirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().
|
static |
The page is writeable. If this flag is not set the page is read-only.
Definition at line 49 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HashedPageTable::addMapping(), Elf::allocate(), ArmV7VirtualAddressSpace::allocateStack(), X86VirtualAddressSpace::beginCrossSpace(), PosixSubsystem::checkAddress(), PerProcessorScheduler::checkEventState(), PPC32VirtualAddressSpace::clone(), HostedVirtualAddressSpace::clone(), MemoryMappedFile::compact(), HostedVirtualAddressSpace::doAllocateStack(), X64VirtualAddressSpace::doAllocateStack(), Bios::executeInterrupt(), expandHeap(), Elf::finaliseModule(), ArmV7PhysicalMemoryManager::PageStack::free(), HostedPhysicalMemoryManager::PageStack::free(), X86VirtualAddressSpace::fromFlags(), ArmV7VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), Thread::getTlsBase(), VbeFramebuffer::hwRedraw(), UsbUlpi::initialise(), HashedPageTable::initialise(), PPCVga::initialise(), MemoryPool::initialise(), GPTimer::initialise(), Prcm::initialise(), BusMasterIde::initialise(), KernelElf::initialise(), X86CommonPhysicalMemoryManager::initialise64(), Ehci::initialiseController(), ARMV7InterruptManager::initialiseProcessor(), PPC32VirtualAddressSpace::initialRoster(), DynamicLinker::initPlt(), Ipc::IpcMessage::IpcMessage(), CdiIrqHandler::irq(), Elf::loadModule(), Device::Address::map(), MIPS32VirtualAddressSpace::map(), Cache::map(), X86VirtualAddressSpace::mapCrossSpace(), X86CommonPhysicalMemoryManager::PageStack::maybeMap(), X86Vga::moveCursor(), VbeDisplay::newBuffer(), Nic3C90x::Nic3C90x(), MemoryMappedFile::remove(), ArmBeagleSerial::setBase(), AnonymousMemoryMap::setPermissions(), MemoryMappedFile::setPermissions(), Framebuffer::swCreateBuffer(), MemoryMappedFile::sync(), X86VirtualAddressSpace::toFlags(), HostedVirtualAddressSpace::toFlags(), ArmV7VirtualAddressSpace::toFlags(), X64VirtualAddressSpace::toFlags(), DynamicLinker::trap(), AnonymousMemoryMap::trap(), MemoryMappedFile::trap(), and X86VirtualAddressSpace::X86VirtualAddressSpace().
|
static |
If this flag is set, the cache strategy is write-combine.
Definition at line 69 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), Device::Address::map(), X86VirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().
|
static |
If this flag is set, the cache strategy is write-through.
Definition at line 54 of file include/pedigree/kernel/processor/VirtualAddressSpace.h.
Referenced by HashedPageTable::addMapping(), X86VirtualAddressSpace::fromFlags(), X64VirtualAddressSpace::fromFlags(), HashedPageTable::initialise(), PPCVga::initialise(), PPC32VirtualAddressSpace::initialRoster(), Device::Address::map(), X86Vga::moveCursor(), X86VirtualAddressSpace::toFlags(), and X64VirtualAddressSpace::toFlags().