diff options
author | Miles Bader <miles@gnu.org> | 1995-07-14 20:49:23 +0000 |
---|---|---|
committer | Miles Bader <miles@gnu.org> | 1995-07-14 20:49:23 +0000 |
commit | 0f0cc39414e41c55cce540ffd93f4da26ea1833d (patch) | |
tree | 8e551675e1bf462b58e1d347d0519c4016938e9d | |
parent | 0da2c1510d08d144b031ae0d11ddd80c4cec132f (diff) |
Formerly mig-decls.h.~2~
-rw-r--r-- | pflocal/mig-decls.h | 31 |
1 files changed, 22 insertions, 9 deletions
diff --git a/pflocal/mig-decls.h b/pflocal/mig-decls.h index 0d051e9c..ee8b1955 100644 --- a/pflocal/mig-decls.h +++ b/pflocal/mig-decls.h @@ -20,22 +20,35 @@ along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -#include "treefs.h" +#include "sock.h" /* For mig */ -typedef struct treefs_handle *treefs_handle_t; + +typedef struct sock_user *sock_user_t; +typedef struct addr *addr_t; + +extern inline +sock_user_t begin_using_sock_user_port(mach_port_t port) +{ + return (sock_user_t)ports_lookup_port (0, port, fsys_port_class); +} + +extern inline void +end_using_sock_user_port (sock_user_t sock_user) +{ + if (sock_user != NULL) + ports_port_deref (sock_user); +} extern inline -treefs_handle_t treefs_begin_using_handle_port(mach_port_t port) +addr_t begin_using_addr_port(mach_port_t port) { - return - (struct treefs_handle *) - ports_lookup_port (0, port, treefs_fsys_port_class); + return (addr_t)ports_lookup_port (0, port, fsys_port_class); } extern inline void -treefs_end_using_handle_port (treefs_handle_t handle) +end_using_addr_port (addr_t addr) { - if (handle != NULL) - ports_port_deref (&handle->pi); + if (addr != NULL) + ports_port_deref (addr); } |