2 * Copyright 2010, Ingo Weinhold <ingo_weinhold@gmx.de>.
3 * Distributed under the terms of the MIT License.
5 #ifndef _KERNEL_GENERIC_VM_PHYSICAL_PAGE_MAPPER_CLASS_H
6 #define _KERNEL_GENERIC_VM_PHYSICAL_PAGE_MAPPER_CLASS_H
9 #include <vm/VMTranslationMap.h>
12 struct GenericVMPhysicalPageMapper
: VMPhysicalPageMapper
{
13 GenericVMPhysicalPageMapper();
14 virtual ~GenericVMPhysicalPageMapper();
16 virtual status_t
GetPage(phys_addr_t physicalAddress
,
17 addr_t
* _virtualAddress
,
19 virtual status_t
PutPage(addr_t virtualAddress
,
22 virtual status_t
GetPageCurrentCPU(
23 phys_addr_t physicalAddress
,
24 addr_t
* _virtualAddress
,
26 virtual status_t
PutPageCurrentCPU(addr_t virtualAddress
,
29 virtual status_t
GetPageDebug(phys_addr_t physicalAddress
,
30 addr_t
* _virtualAddress
,
32 virtual status_t
PutPageDebug(addr_t virtualAddress
,
35 virtual status_t
MemsetPhysical(phys_addr_t address
, int value
,
37 virtual status_t
MemcpyFromPhysical(void* to
, phys_addr_t from
,
38 size_t length
, bool user
);
39 virtual status_t
MemcpyToPhysical(phys_addr_t to
,
40 const void* from
, size_t length
, bool user
);
41 virtual void MemcpyPhysicalPage(phys_addr_t to
,
46 #endif // _KERNEL_GENERIC_VM_PHYSICAL_PAGE_MAPPER_CLASS_H