2 * Copyright 2006-2010, Ingo Weinhold <ingo_weinhold@gmx.de>.
3 * All rights reserved. Distributed under the terms of the MIT License.
5 #ifndef _KERNEL_GENERIC_VM_PHYSICAL_PAGE_MAPPER_H
6 #define _KERNEL_GENERIC_VM_PHYSICAL_PAGE_MAPPER_H
9 #include <boot/kernel_args.h>
12 // flags for generic_get_physical_page()
14 PHYSICAL_PAGE_DONT_WAIT
= 0x01
21 typedef status_t (*generic_map_iospace_chunk_func
)(addr_t virtualAddress
,
22 phys_addr_t physicalAddress
, uint32 flags
);
24 status_t
generic_get_physical_page(phys_addr_t pa
, addr_t
*va
, uint32 flags
);
25 status_t
generic_put_physical_page(addr_t va
);
26 status_t
generic_vm_physical_page_mapper_init(kernel_args
*args
,
27 generic_map_iospace_chunk_func mapIOSpaceChunk
, addr_t
*ioSpaceBase
,
28 size_t ioSpaceSize
, size_t ioSpaceChunkSize
);
29 status_t
generic_vm_physical_page_mapper_init_post_area(kernel_args
*args
);
30 status_t
generic_vm_physical_page_mapper_init_post_sem(kernel_args
*args
);
37 #endif // _KERNEL_GENERIC_VM_PHYSICAL_PAGE_MAPPER_H