1 typedef struct Ref Ref
;
2 typedef struct Urestart Urestart
;
3 typedef struct Uproc Uproc
;
4 typedef struct Uproctab Uproctab
;
5 typedef struct Uwaitq Uwaitq
;
6 typedef struct Uwait Uwait
;
8 typedef struct Udev Udev
;
9 typedef struct Ufile Ufile
;
10 typedef struct Ustat Ustat
;
11 typedef struct Udirent Udirent
;
13 typedef struct Ureg Ureg
;
14 typedef struct Usiginfo Usiginfo
;
89 void (*sysret
)(int errno
);
94 void (*traceproc
)(void *arg
);
153 int (*open
)(char *path
, int mode
, int perm
, Ufile
**pf
);
154 int (*access
)(char *path
, int perm
);
155 int (*stat
)(char *path
, int link
, Ustat
*ps
);
157 int (*link
)(char *old
, char *new, int sym
);
158 int (*unlink
)(char *path
, int rmdir
);
159 int (*readlink
)(char *path
, char *buf
, int len
);
160 int (*rename
)(char *old
, char *new);
161 int (*mkdir
)(char *path
, int mode
);
162 int (*utime
)(char *path
, long atime
, long mtime
);
163 int (*chmod
)(char *path
, int mode
);
164 int (*chown
)(char *path
, int uid
, int gid
, int link
);
165 int (*truncate
)(char *path
, vlong size
);
167 int (*read
)(Ufile
*file
, void *buf
, int len
, vlong off
);
168 int (*write
)(Ufile
*file
, void *buf
, int len
, vlong off
);
170 vlong (*size
)(Ufile
*file
);
171 int (*poll
)(Ufile
*file
, void *tab
);
172 int (*ioctl
)(Ufile
*file
, int cmd
, void *arg
);
173 int (*close
)(Ufile
*file
);
175 int (*fstat
)(Ufile
*file
, Ustat
*ps
);
176 int (*readdir
)(Ufile
*file
, Udirent
**pd
);
178 int (*fchmod
)(Ufile
*file
, int mode
);
179 int (*fchown
)(Ufile
*file
, int uid
, int gid
);
180 int (*ftruncate
)(Ufile
*file
, vlong size
);
193 Udirent
*rdaux
; /* aux pointer to hold Udirent* chains */
228 int pid
; /* sender's pid */
229 int uid
; /* sender's uid */
232 /* POSIX.1b timers */
234 int tid
; /* timer id */
235 int overrun
; /* overrun count */
236 int val
; /* same as below */
237 int sys_private
; /* not to be passed to user */
240 /* POSIX.1b signals */
242 int pid
; /* sender's pid */
243 int uid
; /* sender's uid */
249 int pid
; /* which child */
250 int uid
; /* sender's uid */
251 int status
; /* exit code */
256 /* SIGILL, SIGFPE, SIGSEGV, SIGBUS */
258 void *addr
; /* faulting insn/memory ref. */
259 int trapno
; /* TRAP # which caused the signal */
264 long band
; /* POLL_IN, POLL_OUT, POLL_MSG */
277 #define current (*pcurrent)
280 Udev
*devtab
[MAXDEV
];