diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2013-02-04 10:27:44 +0100 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2013-02-04 10:27:44 +0100 |
commit | ba1b3afd50913473f3036a63b4a82d7ba5c42009 (patch) | |
tree | 9dff0ddec4bf8b927a025b4bf9882cb1731170f3 /ipc/ipc_table.c | |
parent | bfdb3be16e5a20eebc97b3ca613d9a4da4465533 (diff) | |
parent | 51e87d005139a435cd846ac5c224eed5042c4fa0 (diff) |
Merge branch 'master' into master-gdb_stubs
Diffstat (limited to 'ipc/ipc_table.c')
-rw-r--r-- | ipc/ipc_table.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/ipc/ipc_table.c b/ipc/ipc_table.c index e5723586..cbb6a894 100644 --- a/ipc/ipc_table.c +++ b/ipc/ipc_table.c @@ -39,6 +39,7 @@ #include <ipc/ipc_port.h> #include <ipc/ipc_entry.h> #include <kern/kalloc.h> +#include <kern/slab.h> #include <vm/vm_kern.h> /* @@ -50,13 +51,6 @@ void ipc_table_fill( unsigned int min, vm_size_t elemsize); -/* - * We borrow the kalloc map, rather than creating - * yet another submap of the kernel map. - */ - -extern vm_map_t kalloc_map; - ipc_table_size_t ipc_table_entries; unsigned int ipc_table_entries_size = 512; @@ -151,7 +145,7 @@ ipc_table_alloc( if (size < PAGE_SIZE) table = kalloc(size); else - if (kmem_alloc(kalloc_map, &table, size) != KERN_SUCCESS) + if (kmem_alloc(kmem_map, &table, size) != KERN_SUCCESS) table = 0; return table; @@ -177,7 +171,7 @@ ipc_table_realloc( { vm_offset_t new_table; - if (kmem_realloc(kalloc_map, old_table, old_size, + if (kmem_realloc(kmem_map, old_table, old_size, &new_table, new_size) != KERN_SUCCESS) new_table = 0; @@ -201,5 +195,5 @@ ipc_table_free( if (size < PAGE_SIZE) kfree(table, size); else - kmem_free(kalloc_map, table, size); + kmem_free(kmem_map, table, size); } |