From 2ca216d03ead0249bf9e33cbea2c0328637943ad Mon Sep 17 00:00:00 2001 From: Justus Winter <4winter@informatik.uni-hamburg.de> Date: Fri, 22 May 2015 19:36:07 +0200 Subject: ipc: drop remnants of the IPC tables * ipc/ipc_table.c (ipc_table_entries): Remove. (ipc_table_entries_size): Likewise. (ipc_table_init): Remove initialization of `ipc_table_entries'. (ipc_table_realloc): Remove function. * ipc/ipc_table.h: Adjust comments. (ipc_table_entries): Remove declaration. (ipc_table_realloc): Likewise. (it_entries_{alloc,reallocable,realloc,free}): Remove macros. --- ipc/ipc_table.c | 44 -------------------------------------------- 1 file changed, 44 deletions(-) (limited to 'ipc/ipc_table.c') diff --git a/ipc/ipc_table.c b/ipc/ipc_table.c index 90960a8f..1a89d812 100644 --- a/ipc/ipc_table.c +++ b/ipc/ipc_table.c @@ -42,9 +42,6 @@ #include #include -ipc_table_size_t ipc_table_entries; -const unsigned int ipc_table_entries_size = 512; - ipc_table_size_t ipc_table_dnrequests; const unsigned int ipc_table_dnrequests_size = 64; @@ -92,20 +89,6 @@ ipc_table_fill( void ipc_table_init(void) { - ipc_table_entries = (ipc_table_size_t) - kalloc(sizeof(struct ipc_table_size) * - ipc_table_entries_size); - assert(ipc_table_entries != ITS_NULL); - - ipc_table_fill(ipc_table_entries, ipc_table_entries_size - 1, - 4, sizeof(struct ipc_entry)); - - /* the last two elements should have the same size */ - - ipc_table_entries[ipc_table_entries_size - 1].its_size = - ipc_table_entries[ipc_table_entries_size - 2].its_size; - - ipc_table_dnrequests = (ipc_table_size_t) kalloc(sizeof(struct ipc_table_size) * ipc_table_dnrequests_size); @@ -142,33 +125,6 @@ ipc_table_alloc( return table; } -/* - * Routine: ipc_table_realloc - * Purpose: - * Reallocate a big table. - * - * The new table remaps the old table, - * so copying is not necessary. - * Conditions: - * Only works for page-size or bigger tables. - * May block. - */ - -vm_offset_t -ipc_table_realloc( - vm_size_t old_size, - vm_offset_t old_table, - vm_size_t new_size) -{ - vm_offset_t new_table; - - if (kmem_realloc(kmem_map, old_table, old_size, - &new_table, new_size) != KERN_SUCCESS) - new_table = 0; - - return new_table; -} - /* * Routine: ipc_table_free * Purpose: -- cgit v1.2.3