types.h revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* Copyright 1989 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Copyright (c) 1982, 1986 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef __sys_types_h
#define __sys_types_h
/*
* Basic system types.
*/
#ifndef _POSIX_SOURCE
#include <sys/sysmacros.h>
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
typedef unsigned long u_long;
typedef unsigned short ushort; /* System V compatibility */
typedef unsigned int uint; /* System V compatibility */
#endif !_POSIX_SOURCE
#ifdef vax
typedef struct label_t {
int val[14];
} label_t;
#endif
#ifdef mc68000
typedef struct label_t {
int val[13];
} label_t;
#endif
#ifdef sparc
typedef struct label_t {
int val[2];
} label_t;
#endif
#ifdef i386
typedef struct label_t {
int val[8];
} label_t;
#endif
typedef long daddr_t;
typedef char * caddr_t;
typedef unsigned long ino_t;
typedef short dev_t;
typedef long off_t;
typedef unsigned short uid_t;
typedef unsigned short gid_t;
typedef long key_t;
typedef char * addr_t;
#ifndef _POSIX_SOURCE
/*
* Select uses bit masks of file descriptors in longs.
* These macros manipulate such bit fields (the filesystem macros use chars).
* FD_SETSIZE may be defined by the user, but the default here
* should be >= NOFILE (param.h).
*/
#ifndef FD_SETSIZE
#define FD_SETSIZE 256
#endif
typedef long fd_mask;
#ifndef howmany
#ifdef sun386
#else
#define howmany(x, y) (((x)+((y)-1))/(y))
#endif
#endif
typedef struct fd_set {
} fd_set;
#ifdef KERNEL
#ifdef sparc
/*
* routines that call setjmp or on_fault have strange control flow graphs,
* return at the setjmp site, not the original call site. This
* utterly wrecks control flow analysis.
*/
extern int setjmp();
#pragma unknown_control_flow(setjmp)
extern int on_fault();
#pragma unknown_control_flow(on_fault)
#endif /* sparc */
#endif /* KERNEL */
#endif /* !_POSIX_SOURCE */
#endif /* !__sys_types_h */