base: Tell a mapping wether it maps IO memory.

This commit is contained in:
Martin Stein 2012-11-05 16:26:36 +01:00 committed by Norman Feske
parent cfa0a40d5e
commit 91c27f3f72
12 changed files with 23 additions and 12 deletions

View File

@ -37,7 +37,8 @@ namespace Genode {
* Constructor * Constructor
*/ */
Mapping(addr_t dst_addr, addr_t src_addr, Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, unsigned l2size = PAGE_SIZE_LOG2, bool write_combined, bool io_mem,
unsigned l2size = PAGE_SIZE_LOG2,
bool rw = true) bool rw = true)
: :
_from_phys_addr(src_addr), _from_phys_addr(src_addr),

View File

@ -41,7 +41,8 @@ namespace Genode {
* Constructor * Constructor
*/ */
Mapping(addr_t dst_addr, addr_t src_addr, Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, unsigned l2size = L4_LOG2_PAGESIZE, bool write_combined, bool io_mem,
unsigned l2size = L4_LOG2_PAGESIZE,
bool rw = true, bool grant = false) bool rw = true, bool grant = false)
: :
_dst_addr(dst_addr), _dst_addr(dst_addr),

View File

@ -46,7 +46,8 @@ namespace Genode {
* Constructor * Constructor
*/ */
Mapping(addr_t dst_addr, addr_t src_addr, Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, unsigned l2size = L4_LOG2_PAGESIZE, bool write_combined, bool io_mem,
unsigned l2size = L4_LOG2_PAGESIZE,
bool rw = true, bool grant = false) bool rw = true, bool grant = false)
: _dst_addr(dst_addr), _src_addr(src_addr), : _dst_addr(dst_addr), _src_addr(src_addr),
_write_combined(write_combined), _log2size(l2size), _write_combined(write_combined), _log2size(l2size),

View File

@ -28,7 +28,8 @@ namespace Genode {
* Constructor * Constructor
*/ */
Mapping(addr_t dst_addr, addr_t src_addr, Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, unsigned l2size = 12, bool rw = true) { } bool write_combined, bool io_mem,
unsigned l2size = 12, bool rw = true) { }
/** /**
* Construct invalid mapping * Construct invalid mapping

View File

@ -32,6 +32,7 @@ namespace Genode
addr_t virt_address; addr_t virt_address;
addr_t phys_address; addr_t phys_address;
bool write_combined; bool write_combined;
bool io_mem;
unsigned size_log2; unsigned size_log2;
bool writable; bool writable;
@ -39,10 +40,11 @@ namespace Genode
* Construct valid mapping * Construct valid mapping
*/ */
Mapping(addr_t const va, addr_t const pa, bool const wc, Mapping(addr_t const va, addr_t const pa, bool const wc,
unsigned const sl2 = MIN_MAPPING_SIZE_LOG2, bool w = 1) bool io, unsigned const sl2 = MIN_MAPPING_SIZE_LOG2,
bool const w = 1)
: :
virt_address(va), phys_address(pa), write_combined(wc), virt_address(va), phys_address(pa), write_combined(wc),
size_log2(sl2), writable(w) io_mem(io), size_log2(sl2), writable(w)
{ } { }
/** /**

View File

@ -81,7 +81,7 @@ namespace Genode {
Resolution(addr_t virtual_page_address, Resolution(addr_t virtual_page_address,
addr_t physical_page_address, addr_t physical_page_address,
bool write_combined, bool write_combined, bool io_mem,
unsigned size_log2 = DEFAULT_SIZE_LOG2, unsigned size_log2 = DEFAULT_SIZE_LOG2,
bool writeable = DEFAULT_WRITEABLE) bool writeable = DEFAULT_WRITEABLE)
: _valid(true) : _valid(true)

View File

@ -43,7 +43,8 @@ namespace Genode {
* Constructor * Constructor
*/ */
Mapping(addr_t dst_addr, addr_t map_addr, Mapping(addr_t dst_addr, addr_t map_addr,
bool write_combined, unsigned size_log2 = PAGE_SIZE_LOG2, bool write_combined, bool io_mem,
unsigned size_log2 = PAGE_SIZE_LOG2,
bool rw = true) bool rw = true)
: :
_dst_addr(dst_addr), _core_local_addr(map_addr), _dst_addr(dst_addr), _core_local_addr(map_addr),

View File

@ -40,7 +40,8 @@ namespace Genode {
* Constructor * Constructor
*/ */
Mapping(addr_t dst_addr, addr_t src_addr, Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, unsigned l2size = 12, bool rw = true); bool write_combined, bool io_mem,
unsigned l2size = 12, bool rw = true);
/** /**
* Construct invalid mapping * Construct invalid mapping

View File

@ -62,7 +62,8 @@ static inline Okl4::L4_ThreadId_t thread_get_my_global_id()
*************/ *************/
Mapping::Mapping(addr_t dst_addr, addr_t src_addr, Mapping::Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, unsigned l2size, bool rw) bool write_combined, bool io_mem,
unsigned l2size, bool rw)
: :
_fpage(L4_FpageLog2(dst_addr, l2size)), _fpage(L4_FpageLog2(dst_addr, l2size)),
/* /*

View File

@ -50,7 +50,7 @@ namespace Genode {
* Constructor * Constructor
*/ */
Mapping(addr_t dst_addr, addr_t src_addr, Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, bool write_combined, bool io_mem,
unsigned l2size = Pistachio::get_page_size_log2(), unsigned l2size = Pistachio::get_page_size_log2(),
bool rw = true, bool grant = false); bool rw = true, bool grant = false);

View File

@ -32,7 +32,8 @@ using namespace Pistachio;
*************/ *************/
Mapping::Mapping(addr_t dst_addr, addr_t src_addr, Mapping::Mapping(addr_t dst_addr, addr_t src_addr,
bool write_combined, unsigned l2size, bool rw, bool grant) bool write_combined, bool io_mem, unsigned l2size,
bool rw, bool grant)
: :
_write_combined(write_combined) _write_combined(write_combined)
{ {

View File

@ -256,6 +256,7 @@ int Rm_client::pager(Ipc_pager &pager)
Mapping mapping(dst_fault_area.base(), Mapping mapping(dst_fault_area.base(),
src_fault_area.base(), src_fault_area.base(),
src_dataspace->write_combined(), src_dataspace->write_combined(),
src_dataspace->is_io_mem(),
map_size_log2, map_size_log2,
src_dataspace->writable()); src_dataspace->writable());