/*
- * Copyright (c) 2000-2005 Apple Computer, Inc. All rights reserved.
+ * Copyright (c) 2000-2008 Apple Computer, Inc. All rights reserved.
*
* @APPLE_OSREFERENCE_LICENSE_HEADER_START@
*
#ifdef KERNEL
#include <sys/queue.h>
#include <sys/kernel_types.h>
+#include <sys/uio.h>
#endif
+#ifndef _KAUTH_CRED_T
+#define _KAUTH_CRED_T
+struct ucred;
+typedef struct ucred *kauth_cred_t;
+#endif /* !_KAUTH_CRED_T */
+
#pragma pack(4)
/* for the compat sake; */
short f_type; /* descriptor type */
short f_count; /* reference count */
short f_msgcount; /* references from message queue */
- struct ucred *f_cred; /* credentials associated with descriptor */
+ kauth_cred_t f_cred; /* credentials associated with descriptor */
void * f_ops;
off_t f_offset;
caddr_t f_data; /* vnode or socket or SHM or semaphore */
#pragma pack()
-#ifdef KERNEL
__BEGIN_DECLS
+#ifdef KERNEL
int file_socket(int, socket_t *);
int file_vnode(int, vnode_t *);
+int file_vnode_withvid(int, vnode_t *, uint32_t *);
int file_flags(int, int *);
int file_drop(int);
-__END_DECLS
-
#endif /* KERNEL */
+#ifdef KERNEL_PRIVATE
+int fd_rdwr(int fd, enum uio_rw, uint64_t base, int64_t len, enum uio_seg,
+ off_t offset, int io_flg, int64_t *aresid);
+#endif /* KERNEL_PRIVATE */
+__END_DECLS
#endif /* !_SYS_FILE_H_ */