/[rtmk]/rtmk/ipc-table.c
ViewVC logotype

Diff of /rtmk/ipc-table.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by jrydberg, Tue Jan 29 18:31:45 2002 UTC revision 1.3 by jrydberg, Wed Mar 27 00:13:45 2002 UTC
# Line 1  Line 1 
1  /* IPC rights table.  /* IPC rights table.
2     Copyright 1999, 2000, 2001 Johan Rydberg, jrydberg@opencores.org.     Copyright 1999, 2000, 2001, 2002 Johan Rydberg, jrydberg@opencores.org.
3    
4  This program is free software; you can redistribute it and/or modify  This program is free software; you can redistribute it and/or modify
5  it under the terms of the GNU General Public License as published by  it under the terms of the GNU General Public License as published by
# Line 19  Foundation, Inc., 59 Temple Place - Suit Line 19  Foundation, Inc., 59 Temple Place - Suit
19  #include "ipc-port.h"  #include "ipc-port.h"
20  #include "ipc-object.h"  #include "ipc-object.h"
21  #include "trace.h"  #include "trace.h"
22    #include "vm-kmem.h"
23    
24  /* Intialize IPC table object TBL.  Marks all slots as unused.  */  /* Intialize IPC table object TBL.  Marks all slots as unused.  */
25    
26  void  void
27  ipc_table_object_init (struct ipc_table *tbl)  ipc_table_object_init (struct ipc_table *tbl)
28  {  {
29    int cnt;    tbl->it_tbl = (struct ipc_entry **)
30          kmem_alloc_wired (VM_MAP_KERNEL (),
31    for (cnt = 0; cnt < MTABLERIGHTS; cnt++)                        MTABLERIGHTS * sizeof (struct ipc_entry *));
32      tbl->it_tbl [cnt] = 0;    assert (tbl->it_tbl);
33      memset (tbl->it_tbl, 0, MTABLERIGHTS * sizeof (struct ipc_entry *));
34  }  }
35    
36  /* Try to reserve entry named by NAME in TBL.  Return true if we succeed  /* Try to reserve entry named by NAME in TBL.  Return true if we succeed

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26