/[hurd]/hurd-l4/libhurd-cap/cap.h
ViewVC logotype

Diff of /hurd-l4/libhurd-cap/cap.h

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

revision 1.5 by marcus, Wed Aug 27 22:51:59 2003 UTC revision 1.6 by marcus, Mon Sep 15 18:09:45 2003 UTC
# Line 25  Line 25 
25  #include <hurd/slab.h>  #include <hurd/slab.h>
26  #include <l4/types.h>  #include <l4/types.h>
27    
28    typedef l4_word_t hurd_task_info_t;
29    
30  /* Initialize the capability system.  */  /* Initialize the capability system.  */
31  error_t hurd_cap_init (void);  error_t hurd_cap_init (void);
# Line 38  struct hurd_cap_sconn Line 39  struct hurd_cap_sconn
39    
40    /* A reference for the servers task ID to prevent reuse.  This is 0    /* A reference for the servers task ID to prevent reuse.  This is 0
41       if this is the connection to the task server itself.  */       if this is the connection to the task server itself.  */
42    task_id_t server_task_id;    hurd_task_info_t server_task_info;
43    
44    /* The lock protecting the variable members of the server connection    /* The lock protecting the variable members of the server connection
45       object.  */       object.  */
# Line 50  struct hurd_cap_sconn Line 51  struct hurd_cap_sconn
51    /* A hash mapping the capability IDs to capability objects.  */    /* A hash mapping the capability IDs to capability objects.  */
52    struct hurd_ihash id_to_cap;    struct hurd_ihash id_to_cap;
53  };  };
54    typedef struct hurd_cap_sconn *hurd_cap_sconn_t;
55    
56    
57  /* User capabilities.  */  /* User capabilities.  */
# Line 57  struct hurd_cap_sconn Line 59  struct hurd_cap_sconn
59  /* The task-specific ID for this capability.  */  /* The task-specific ID for this capability.  */
60  typedef l4_word_t hurd_cap_scid_t;  typedef l4_word_t hurd_cap_scid_t;
61    
62    
63  /* Remove the entry for the capability CAP from the user list ULIST.  /* Forward reference.  */
64     ULIST (and the capability CAP) are locked.  */  struct hurd_cap_ulist;
65  void _hurd_cap_ulist_remove (ulist, cap);  typedef struct hurd_cap_ulist *hurd_cap_ulist_t;
66    
67    
68  /* The capability structure.  */  /* The capability structure.  */
# Line 88  struct hurd_cap Line 90  struct hurd_cap
90    
91    /* A callback for the user of the capability, invoked when the    /* A callback for the user of the capability, invoked when the
92       capability is destroyed.  */       capability is destroyed.  */
93    #if 0
94    hurd_cap_dead_t dead_cb;    hurd_cap_dead_t dead_cb;
95    #endif
96    
97    /* Information for local capabilities.  */    /* Information for local capabilities.  */
98    
# Line 104  struct hurd_cap Line 107  struct hurd_cap
107    hurd_cap_ulist_t ouser;    hurd_cap_ulist_t ouser;
108    
109    /* A callback invoked when the capability is destroyed.  */    /* A callback invoked when the capability is destroyed.  */
110    #if 0
111    hurd_cap_odead_cb_t odead_cb;    hurd_cap_odead_cb_t odead_cb;
112    #endif
113    
114    /* A callback to be invoked when the capability has no more    /* A callback to be invoked when the capability has no more
115       senders.  */       senders.  */
116    #if 0
117    hurd_cap_no_sender_cb_t no_sender_cb;    hurd_cap_no_sender_cb_t no_sender_cb;
118    #endif
119    };
120    typedef struct hurd_cap *hurd_cap_t;
121    
122    
123    struct hurd_cap_ulist
124    {
125      /* The lock protecting the variable members of the object.  */
126      pthread_mutex_t lock;
127  };  };
128  typedef struct hurd_cap hurd_cap_t;  
129    
130    /* Remove the entry for the capability CAP from the user list ULIST.
131       ULIST (and the capability CAP) are locked.  */
132    void _hurd_cap_ulist_remove (hurd_cap_ulist_t ulist, hurd_cap_t cap);

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

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