1 #include <l4/re/protocols.h> /* L4RE_PROTO_RM */ 2 #include <systypes/base.h> /* address_t */ 3 4 /* A region mapper/manager interface. */ 5 6 [protocol(L4RE_PROTO_RM)] 7 interface RegionMapper 8 { 9 /* Attach the memory associated with a dataspace, employing the given start 10 address to search for a suitable address for the region. */ 11 12 [opcode(0)] void attach(inout address_t start, in address_t size, 13 in map_flags_t flags, in cap ds, 14 in address_t offset, in unsigned char align); 15 16 /* Detach memory from the task, searching from the given address for a region 17 of the given size. Return the start address, region size and dataspace. */ 18 19 [opcode(1)] void detach(in address_t addr, in address_t size, 20 in map_flags_t flags, out address_t start, 21 out address_t rsize, out cap ds); 22 23 /* Find a region starting from the given address and having the given size. 24 Return the start address, region size and dataspace. */ 25 26 [opcode(2)] void find(inout address_t addr, inout address_t size, 27 out map_flags_t flags, out address_t offset, 28 out cap ds); 29 30 /* Reserve an area in the region map. */ 31 32 [opcode(3)] void reserve_area(inout address_t start, in address_t size, 33 in map_flags_t flags, in unsigned char align); 34 35 /* Free (or unreserve) an area in the region map. */ 36 37 [opcode(4)] void free_area(in address_t addr); 38 39 /* Currently not fully supported by the interface generator... 40 41 [opcode(5)] void get_regions(in address_t start, out Region[] regions); 42 43 [opcode(6)] void get_areas(in address_t start, out Area[] areas); 44 45 See pkg/l4re-core/l4re/include/rm for the Region and Area structures. */ 46 };