Pager struct allocated from boot memory and never referenced after boot.

We still have to have the pager structs because they possess intermediate
data during boot up such as for transferring of capability lists to
boot stack one-by-one, and then to newly generated ktcbs.
This commit is contained in:
Bahadir Balban
2009-11-03 15:09:28 +02:00
parent 6c69f181db
commit 9248328dd3
3 changed files with 10 additions and 2 deletions

View File

@@ -7,6 +7,7 @@
#include <l4/generic/resource.h>
#include <l4/generic/capability.h>
#include <l4/generic/cap-types.h>
#include <l4/generic/bootmem.h>
#include <l4/api/errno.h>
#include INC_GLUE(memory.h)
#include INC_SUBARCH(mm.h)
@@ -25,6 +26,8 @@ int container_init(struct container *c)
cap_list_init(&c->cap_list);
/* Init pager structs */
c->pager = alloc_bootmem(sizeof(c->pager[0]) *
CONFIG_MAX_PAGERS_USED, 0);
for (int i = 0; i < CONFIG_MAX_PAGERS_USED; i++)
cap_list_init(&c->pager[i].cap_list);