]> git.saurik.com Git - apple/xnu.git/blob - osfmk/ppc/machlimits.h
15e0309476f02f90495e2ca497bef8352f8c1755
[apple/xnu.git] / osfmk / ppc / machlimits.h
1 /*
2 * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
3 *
4 * @APPLE_LICENSE_HEADER_START@
5 *
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. Please obtain a copy of the License at
10 * http://www.opensource.apple.com/apsl/ and read it before using this
11 * file.
12 *
13 * The Original Code and all software distributed under the License are
14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
18 * Please see the License for the specific language governing rights and
19 * limitations under the License.
20 *
21 * @APPLE_LICENSE_HEADER_END@
22 */
23 /*
24 * @OSF_COPYRIGHT@
25 */
26 /*
27 * HISTORY
28 *
29 * Revision 1.1.1.1 1998/09/22 21:05:41 wsanchez
30 * Import of Mac OS X kernel (~semeria)
31 *
32 * Revision 1.1.1.1 1998/03/07 02:26:02 wsanchez
33 * Import of OSF Mach kernel (~mburg)
34 *
35 * Revision 1.1.2.1 1996/12/09 16:55:05 stephen
36 * nmklinux_1.0b3_shared into pmk1.1
37 * New file based on hp_pa
38 * [1996/12/09 11:09:22 stephen]
39 *
40 * $EndLog$
41 */
42 /*
43 * Copyright (c) 1988 The Regents of the University of California.
44 * All rights reserved.
45 *
46 * Redistribution and use in source and binary forms are permitted
47 * provided that the above copyright notice and this paragraph are
48 * duplicated in all such forms and that any documentation,
49 * advertising materials, and other materials related to such
50 * distribution and use acknowledge that the software was developed
51 * by the University of California, Berkeley. The name of the
52 * University may not be used to endorse or promote products derived
53 * from this software without specific prior written permission.
54 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
55 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
56 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
57 *
58 * @(#)machlimits.h 7.1 (Berkeley) 2/15/89
59 */
60 #ifndef _MACH_MACHLIMITS_H_
61 #define _MACH_MACHLIMITS_H_
62
63 #define CHAR_BIT 8 /* number of bits in a char */
64
65 #define SCHAR_MAX 127 /* max value for a signed char */
66 #define SCHAR_MIN (-128) /* min value for a signed char */
67
68 #define UCHAR_MAX 255U /* max value for an unsigned char */
69 #define CHAR_MAX 127 /* max value for a char */
70 #define CHAR_MIN (-128) /* min value for a char */
71
72 #define USHRT_MAX 65535U /* max value for an unsigned short */
73 #define SHRT_MAX 32767 /* max value for a short */
74 #define SHRT_MIN (-32768) /* min value for a short */
75
76 #define UINT_MAX 0xFFFFFFFFU /* max value for an unsigned int */
77 #define INT_MAX 2147483647 /* max value for an int */
78 #define INT_MIN (-2147483647-1) /* min value for an int */
79
80 #define ULONG_MAX UINT_MAX /* max value for an unsigned long */
81 #define LONG_MAX INT_MAX /* max value for a long */
82 #define LONG_MIN INT_MIN /* min value for a long */
83
84 /* Must be at least two, for internationalization (NLS/KJI) */
85 #define MB_LEN_MAX 4 /* multibyte characters */
86
87 #endif /* _MACH_MACHLIMITS_H_ */