1 /* Copyright (C) 1991,92,1994-1999,2000,2001 Free Software Foundation, Inc.
2 This file is part of the GNU C Library.
4 The GNU C Library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Lesser General Public
6 License as published by the Free Software Foundation; either
7 version 2.1 of the License, or (at your option) any later version.
9 The GNU C Library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Lesser General Public License for more details.
14 You should have received a copy of the GNU Lesser General Public
15 License along with the GNU C Library; if not, write to the Free
16 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
20 * Never include this file directly; use <sys/types.h> instead.
24 #define _BITS_TYPES_H 1
31 /* Sigh. We need to carefully wrap this one... */
34 #include <asm/posix_types.h>
37 #include <asm/posix_types.h>
40 /* Convenience types. */
41 typedef unsigned char __u_char;
42 typedef unsigned short __u_short;
43 typedef unsigned int __u_int;
44 typedef unsigned long __u_long;
46 __extension__ typedef unsigned long long int __u_quad_t;
47 __extension__ typedef long long int __quad_t;
58 typedef signed char __int8_t;
59 typedef unsigned char __uint8_t;
60 typedef signed short int __int16_t;
61 typedef unsigned short int __uint16_t;
62 typedef signed int __int32_t;
63 typedef unsigned int __uint32_t;
65 __extension__ typedef signed long long int __int64_t;
66 __extension__ typedef unsigned long long int __uint64_t;
68 typedef __quad_t *__qaddr_t;
70 /* changed to be more compatible with kernel */
71 typedef __kernel_dev_t __dev_t; /* Type of device numbers. */
72 typedef __kernel_uid_t __uid_t; /* Type of user identifications. */
73 typedef __kernel_gid_t __gid_t; /* Type of group identifications. */
74 typedef __kernel_ino_t __ino_t; /* Type of file serial numbers. */
75 typedef __kernel_mode_t __mode_t; /* Type of file attribute bitmasks. */
76 typedef __kernel_nlink_t __nlink_t; /* Type of file link counts. */
77 typedef __kernel_off_t __off_t; /* Type of file sizes and offsets. */
78 typedef __kernel_loff_t __loff_t; /* Type of file sizes and offsets. */
79 typedef __kernel_pid_t __pid_t; /* Type of process identifications. */
80 typedef __kernel_ssize_t __ssize_t; /* Type of a byte count, or error. */
81 typedef __u_long __rlim_t; /* Type of resource counts. */
82 typedef __u_quad_t __rlim64_t; /* Type of resource counts (LFS). */
83 typedef __u_int __id_t; /* General type for ID. */
88 } __fsid_t; /* Type of file system IDs. */
90 /* Everythin' else. */
91 typedef int __daddr_t; /* The type of a disk address. */
92 typedef char *__caddr_t;
93 typedef long int __time_t;
94 typedef unsigned int __useconds_t;
95 typedef long int __suseconds_t;
96 typedef long int __swblk_t; /* Type of a swap block maybe? */
98 typedef long int __clock_t;
100 /* Clock ID used in clock and timer functions. */
101 typedef int __clockid_t;
103 /* Timer ID returned by `timer_create'. */
104 typedef int __timer_t;
107 /* Number of descriptors that can fit in an `fd_set'. */
108 #define __FD_SETSIZE 1024
113 /* Used in `struct shmid_ds'. */
114 typedef unsigned short int __ipc_pid_t;
117 /* Type to represent block size. */
118 typedef long int __blksize_t;
120 /* Types from the Large File Support interface. */
122 /* Type to count number os disk blocks. */
123 typedef long int __blkcnt_t;
124 typedef __quad_t __blkcnt64_t;
126 /* Type to count file system blocks. */
127 typedef __u_long __fsblkcnt_t;
128 typedef __u_quad_t __fsblkcnt64_t;
130 /* Type to count file system inodes. */
131 typedef __u_long __fsfilcnt_t;
132 typedef __u_quad_t __fsfilcnt64_t;
134 /* Type of file serial numbers. */
135 typedef __u_quad_t __ino64_t;
137 /* Type of file sizes and offsets. */
138 typedef __loff_t __off64_t;
141 typedef long int __t_scalar_t;
142 typedef unsigned long int __t_uscalar_t;
144 /* Duplicates info from stdint.h but this is used in unistd.h. */
145 typedef int __intptr_t;
147 /* Duplicate info from sys/socket.h. */
148 typedef unsigned int __socklen_t;
151 /* Now add the thread types. */
152 #if defined __UCLIBC_HAS_THREADS__ && (defined __USE_POSIX199506 || defined __USE_UNIX98)
153 # include <bits/pthreadtypes.h>
156 #endif /* bits/types.h */