X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/5ba3f43ea354af8ad55bea84372a2bc834d8757c..bca245acd4c03fd752d1a45f011ad495e60fe53d:/bsd/sys/sysent.h diff --git a/bsd/sys/sysent.h b/bsd/sys/sysent.h index 6d529d6f5..b68b3cded 100644 --- a/bsd/sys/sysent.h +++ b/bsd/sys/sysent.h @@ -2,7 +2,7 @@ * Copyright (c) 2004-2014 Apple Inc. All rights reserved. * * @APPLE_OSREFERENCE_LICENSE_HEADER_START@ - * + * * This file contains Original Code and/or Modifications of Original Code * as defined in and that are subject to the Apple Public Source License * Version 2.0 (the 'License'). You may not use this file except in @@ -11,10 +11,10 @@ * unlawful or unlicensed copies of an Apple operating system, or to * circumvent, violate, or enable the circumvention or violation of, any * terms of an Apple operating system software license agreement. - * + * * Please obtain a copy of the License at * http://www.opensource.apple.com/apsl/ and read it before using this file. - * + * * The Original Code and all software distributed under the License are * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, @@ -22,12 +22,12 @@ * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. * Please see the License for the specific language governing rights and * limitations under the License. - * + * * @APPLE_OSREFERENCE_LICENSE_HEADER_END@ */ #ifndef _SYS_SYSENT_H_ -#define _SYS_SYSENT_H_ +#define _SYS_SYSENT_H_ #include #include @@ -35,49 +35,49 @@ #ifdef KERNEL_PRIVATE #ifdef __APPLE_API_PRIVATE -typedef int32_t sy_call_t(struct proc *, void *, int *); +typedef int32_t sy_call_t(struct proc *, void *, int *); #if CONFIG_REQUIRES_U32_MUNGING -typedef void sy_munge_t(void *); +typedef void sy_munge_t(void *); #elif __arm__ && (__BIGGEST_ALIGNMENT__ > 4) -typedef int sy_munge_t(const void *, void *); +typedef int sy_munge_t(const void *, void *); #endif -struct sysent { /* system call table */ - sy_call_t *sy_call; /* implementing function */ +struct sysent { /* system call table */ + sy_call_t *sy_call; /* implementing function */ #if CONFIG_REQUIRES_U32_MUNGING || (__arm__ && (__BIGGEST_ALIGNMENT__ > 4)) - sy_munge_t *sy_arg_munge32; /* system call arguments munger for 32-bit process */ + sy_munge_t *sy_arg_munge32; /* system call arguments munger for 32-bit process */ #endif - int32_t sy_return_type; /* system call return types */ - int16_t sy_narg; /* number of args */ - uint16_t sy_arg_bytes; /* Total size of arguments in bytes for - * 32-bit system calls - */ + int32_t sy_return_type; /* system call return types */ + int16_t sy_narg; /* number of args */ + uint16_t sy_arg_bytes; /* Total size of arguments in bytes for + * 32-bit system calls + */ }; #ifndef __INIT_SYSENT_C__ extern struct sysent sysent[]; -#endif /* __INIT_SYSENT_C__ */ +#endif /* __INIT_SYSENT_C__ */ -extern unsigned int nsysent; +extern const unsigned int nsysent; -/* +/* * Valid values for sy_cancel */ -#define _SYSCALL_CANCEL_NONE 0 /* Not a cancellation point */ -#define _SYSCALL_CANCEL_PRE 1 /* Canbe cancelled on entry itself */ -#define _SYSCALL_CANCEL_POST 2 /* Can only be cancelled after syscall is run */ +#define _SYSCALL_CANCEL_NONE 0 /* Not a cancellation point */ +#define _SYSCALL_CANCEL_PRE 1 /* Canbe cancelled on entry itself */ +#define _SYSCALL_CANCEL_POST 2 /* Can only be cancelled after syscall is run */ /* * Valid values for sy_return_type */ -#define _SYSCALL_RET_NONE 0 -#define _SYSCALL_RET_INT_T 1 -#define _SYSCALL_RET_UINT_T 2 -#define _SYSCALL_RET_OFF_T 3 -#define _SYSCALL_RET_ADDR_T 4 -#define _SYSCALL_RET_SIZE_T 5 -#define _SYSCALL_RET_SSIZE_T 6 -#define _SYSCALL_RET_UINT64_T 7 +#define _SYSCALL_RET_NONE 0 +#define _SYSCALL_RET_INT_T 1 +#define _SYSCALL_RET_UINT_T 2 +#define _SYSCALL_RET_OFF_T 3 +#define _SYSCALL_RET_ADDR_T 4 +#define _SYSCALL_RET_SIZE_T 5 +#define _SYSCALL_RET_SSIZE_T 6 +#define _SYSCALL_RET_UINT64_T 7 #endif /* __APPLE_API_PRIVATE */ #endif /* KERNEL_PRIVATE */