xref: /freebsd/sys/contrib/openzfs/lib/libspl/include/sys/stdtypes.h (revision 61145dc2b94f12f6a47344fb9aac702321880e43)
1 // SPDX-License-Identifier: CDDL-1.0
2 /*
3  * CDDL HEADER START
4  *
5  * The contents of this file are subject to the terms of the
6  * Common Development and Distribution License, Version 1.0 only
7  * (the "License").  You may not use this file except in compliance
8  * with the License.
9  *
10  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
11  * or https://opensource.org/licenses/CDDL-1.0.
12  * See the License for the specific language governing permissions
13  * and limitations under the License.
14  *
15  * When distributing Covered Code, include this CDDL HEADER in each
16  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
17  * If applicable, add the following below this CDDL HEADER, with the
18  * fields enclosed by brackets "[]" replaced with your own identifying
19  * information: Portions Copyright [yyyy] [name of copyright owner]
20  *
21  * CDDL HEADER END
22  */
23 
24 #ifndef	__SYS_STDTYPES_H
25 #define	__SYS_STDTYPES_H
26 
27 typedef enum {
28 	B_FALSE = 0,
29 	B_TRUE = 1
30 } boolean_t;
31 
32 typedef unsigned char		uchar_t;
33 typedef unsigned short		ushort_t;
34 typedef unsigned int		uint_t;
35 typedef unsigned long		ulong_t;
36 typedef unsigned long long	u_longlong_t;
37 typedef long long		longlong_t;
38 
39 typedef longlong_t		offset_t;
40 typedef u_longlong_t		u_offset_t;
41 typedef u_longlong_t		len_t;
42 typedef longlong_t		diskaddr_t;
43 
44 typedef ulong_t			pgcnt_t;	/* number of pages */
45 typedef long			spgcnt_t;	/* signed number of pages */
46 
47 typedef short			pri_t;
48 typedef ushort_t		o_mode_t;	/* old file attribute type */
49 
50 typedef int			major_t;
51 typedef int			minor_t;
52 
53 typedef short			index_t;
54 
55 #endif	/* __SYS_STDTYPES_H */
56