2 * Copyright 2010, Ingo Weinhold, ingo_weinhold@gmx.de.
3 * Distributed under the terms of the MIT License.
5 #ifndef KERNEL_ARCH_X86_PAGING_PAE_X86_VM_TRANSLATION_MAP_PAE_H
6 #define KERNEL_ARCH_X86_PAGING_PAE_X86_VM_TRANSLATION_MAP_PAE_H
9 #include "paging/X86VMTranslationMap.h"
12 #if B_HAIKU_PHYSICAL_BITS == 64
15 struct X86PagingStructuresPAE
;
18 struct X86VMTranslationMapPAE
: X86VMTranslationMap
{
19 X86VMTranslationMapPAE();
20 virtual ~X86VMTranslationMapPAE();
22 status_t
Init(bool kernel
);
24 virtual size_t MaxPagesNeededToMap(addr_t start
,
27 virtual status_t
Map(addr_t virtualAddress
,
28 phys_addr_t physicalAddress
,
29 uint32 attributes
, uint32 memoryType
,
30 vm_page_reservation
* reservation
);
31 virtual status_t
Unmap(addr_t start
, addr_t end
);
33 virtual status_t
DebugMarkRangePresent(addr_t start
, addr_t end
,
36 virtual status_t
UnmapPage(VMArea
* area
, addr_t address
,
37 bool updatePageQueue
);
38 virtual void UnmapPages(VMArea
* area
, addr_t base
,
39 size_t size
, bool updatePageQueue
);
40 virtual void UnmapArea(VMArea
* area
,
41 bool deletingAddressSpace
,
42 bool ignoreTopCachePageFlags
);
44 virtual status_t
Query(addr_t virtualAddress
,
45 phys_addr_t
* _physicalAddress
,
47 virtual status_t
QueryInterrupt(addr_t virtualAddress
,
48 phys_addr_t
* _physicalAddress
,
51 virtual status_t
Protect(addr_t base
, addr_t top
,
52 uint32 attributes
, uint32 memoryType
);
54 virtual status_t
ClearFlags(addr_t virtualAddress
,
57 virtual bool ClearAccessedAndModified(
58 VMArea
* area
, addr_t address
,
59 bool unmapIfUnaccessed
,
62 virtual void DebugPrintMappingInfo(addr_t virtualAddress
);
63 virtual bool DebugGetReverseMappingInfo(
64 phys_addr_t physicalAddress
,
65 ReverseMappingInfoCallback
& callback
);
67 virtual X86PagingStructures
* PagingStructures() const;
68 inline X86PagingStructuresPAE
* PagingStructuresPAE() const
69 { return fPagingStructures
; }
72 X86PagingStructuresPAE
* fPagingStructures
;
76 #endif // B_HAIKU_PHYSICAL_BITS == 64
79 #endif // KERNEL_ARCH_X86_PAGING_PAE_X86_VM_TRANSLATION_MAP_PAE_H