2 * Copyright 2010, Ingo Weinhold, ingo_weinhold@gmx.de.
3 * Distributed under the terms of the MIT License.
5 #ifndef KERNEL_ARCH_M68K_PAGING_040_M68K_VM_TRANSLATION_MAP_040_H
6 #define KERNEL_ARCH_M68K_PAGING_040_M68K_VM_TRANSLATION_MAP_040_H
9 #include "paging/M68KVMTranslationMap.h"
11 struct M68KPagingStructures040
;
14 struct M68KVMTranslationMap040
: M68KVMTranslationMap
{
15 M68KVMTranslationMap040();
16 virtual ~M68KVMTranslationMap040();
18 status_t
Init(bool kernel
);
20 virtual size_t MaxPagesNeededToMap(addr_t start
,
23 virtual status_t
Map(addr_t virtualAddress
,
24 phys_addr_t physicalAddress
,
25 uint32 attributes
, uint32 memoryType
,
26 vm_page_reservation
* reservation
);
27 virtual status_t
Unmap(addr_t start
, addr_t end
);
29 virtual status_t
UnmapPage(VMArea
* area
, addr_t address
,
30 bool updatePageQueue
);
31 virtual void UnmapPages(VMArea
* area
, addr_t base
,
32 size_t size
, bool updatePageQueue
);
33 virtual void UnmapArea(VMArea
* area
,
34 bool deletingAddressSpace
,
35 bool ignoreTopCachePageFlags
);
37 virtual status_t
Query(addr_t virtualAddress
,
38 phys_addr_t
* _physicalAddress
,
40 virtual status_t
QueryInterrupt(addr_t virtualAddress
,
41 phys_addr_t
* _physicalAddress
,
44 virtual status_t
Protect(addr_t base
, addr_t top
,
45 uint32 attributes
, uint32 memoryType
);
47 virtual status_t
ClearFlags(addr_t virtualAddress
,
50 virtual bool ClearAccessedAndModified(
51 VMArea
* area
, addr_t address
,
52 bool unmapIfUnaccessed
,
55 virtual M68KPagingStructures
* PagingStructures() const;
56 inline M68KPagingStructures040
* PagingStructures040() const
57 { return fPagingStructures
; }
59 void* MapperGetPageTableAt(
60 phys_addr_t physicalAddress
,
64 M68KPagingStructures040
* fPagingStructures
;
68 #endif // KERNEL_ARCH_M68K_PAGING_040_M68K_VM_TRANSLATION_MAP_040_H