Lines Matching defs:vspace

3  * \brief vspace management
5 * A vspace consists of a set of vregions and one pmap.
6 * The current vspace is setup by the (domain/dispatcher?) spawning it.
29 * \brief Initialize the current vspace structure
36 struct vspace *vspace = get_current_vspace();
39 vspace->pmap = pmap;
40 vspace->head = NULL;
43 err = vspace_layout_init(&vspace->layout);
53 err = pmap_init(pmap, vspace, cap, NULL);
72 * \brief Add a new region into the vspace
74 * \param point The vspace struct
77 * pmap implementation rely on vspace maintaining an ordered list of vregions
79 errval_t vspace_add_vregion(struct vspace *vspace, struct vregion *region)
85 if (vspace->head == NULL) {
86 vspace->head = region;
92 struct vregion *walk = vspace->head;
104 region->next = vspace->head;
105 vspace->head = region;
128 * \brief remove a region from the vspace
130 * \param point The vspace struct
135 errval_t vspace_remove_vregion(struct vspace *vspace, struct vregion* region)
137 assert(vspace != NULL);
138 struct vregion *walk = vspace->head;
147 assert(walk == vspace->head);
148 vspace->head = walk->next;
160 * \brief Initialize a vspace
162 * \param vspace The vspace to initialize
163 * \param pmap The pmap to associate with the vspace
165 * Initializes a vspace, associating it with a pmap
167 errval_t vspace_init(struct vspace *vspace, struct pmap *pmap)
171 vspace->pmap = pmap;
172 vspace->head = NULL;
175 err = vspace_layout_init(&vspace->layout);
184 * \brief Destroy a vspace
186 errval_t vspace_destroy(struct vspace *vspace)
196 struct vregion* vspace_get_region(struct vspace *vspace, const void *addr)
201 struct vregion *walk = vspace->head;
216 * \param point The vspace page fault occured in
222 errval_t vspace_pagefault_handler(struct vspace *vspace, lvaddr_t lvaddr,
228 vspace_layout_lvaddr_to_genvaddr(&vspace->layout, lvaddr);
230 struct vregion *walk = vspace->head;